feat: eslint rule to prefer node protocols (#1187)
This commit is contained in:
parent
ec33e3f506
commit
cca6ba05b5
4 changed files with 195 additions and 21 deletions
|
|
@ -1,5 +1,5 @@
|
|||
import { createServer, ServerResponse, type IncomingMessage, type Server } from 'http';
|
||||
import { AddressInfo } from 'net';
|
||||
import { createServer, ServerResponse, type IncomingMessage, type Server } from 'node:http';
|
||||
import { AddressInfo } from 'node:net';
|
||||
import { JSONRPCMessage } from '../types.js';
|
||||
import { SSEClientTransport } from './sse.js';
|
||||
import { OAuthClientProvider, UnauthorizedError } from './auth.js';
|
||||
|
|
|
|||
|
|
@ -7,7 +7,7 @@
|
|||
|
||||
import { Task, Request, RequestId, Result } from '../../../types.js';
|
||||
import { TaskStore, isTerminal, TaskMessageQueue, QueuedMessage, CreateTaskOptions } from '../interfaces.js';
|
||||
import { randomBytes } from 'crypto';
|
||||
import { randomBytes } from 'node:crypto';
|
||||
|
||||
interface StoredTask {
|
||||
task: Task;
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
import http from 'http';
|
||||
import http from 'node:http';
|
||||
import { type Mocked } from 'vitest';
|
||||
|
||||
import { SSEServerTransport } from './sse.js';
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@ import { JSONRPCMessage, JSONRPCMessageSchema, MessageExtraInfo, RequestInfo } f
|
|||
import getRawBody from 'raw-body';
|
||||
import contentType from 'content-type';
|
||||
import { AuthInfo } from './auth/types.js';
|
||||
import { URL } from 'url';
|
||||
import { URL } from 'node:url';
|
||||
|
||||
const MAXIMUM_MESSAGE_SIZE = '4mb';
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue