Merge remote-tracking branch 'parent/main' into upstream-20240628
This commit is contained in:
commit
6955843321
178 changed files with 1924 additions and 1178 deletions
|
@ -110,4 +110,4 @@ USER mastodon
|
|||
# Expose default Streaming ports
|
||||
EXPOSE 4000
|
||||
# Run streaming when started
|
||||
CMD [ node ./streaming/index.js ]
|
||||
CMD [ "node", "./streaming/index.js" ]
|
||||
|
|
|
@ -12,7 +12,7 @@ import { Redis } from 'ioredis';
|
|||
import { JSDOM } from 'jsdom';
|
||||
import pg from 'pg';
|
||||
import pgConnectionString from 'pg-connection-string';
|
||||
import WebSocket from 'ws';
|
||||
import { WebSocketServer } from 'ws';
|
||||
|
||||
import { AuthenticationError, RequestError, extractStatusAndMessage as extractErrorStatusAndMessage } from './errors.js';
|
||||
import { logger, httpLogger, initializeLogLevel, attachWebsocketHttpLogger, createWebsocketLogger } from './logging.js';
|
||||
|
@ -289,7 +289,7 @@ const CHANNEL_NAMES = [
|
|||
const startServer = async () => {
|
||||
const pgPool = new pg.Pool(pgConfigFromEnv(process.env));
|
||||
const server = http.createServer();
|
||||
const wss = new WebSocket.Server({ noServer: true });
|
||||
const wss = new WebSocketServer({ noServer: true });
|
||||
|
||||
// Set the X-Request-Id header on WebSockets:
|
||||
wss.on("headers", function onHeaders(headers, req) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue