Add logging of websocket send errors (#25280)

th-downstream
Emelia Smith 1 year ago committed by GitHub
parent c31e2b3267
commit 34c9ee4a66

@ -828,7 +828,11 @@ const startServer = async () => {
return; return;
} }
ws.send(JSON.stringify({ stream: streamName, event, payload })); ws.send(JSON.stringify({ stream: streamName, event, payload }), (err) => {
if (err) {
log.error(req.requestId, `Failed to send to websocket: ${err}`);
}
});
}; };
/** /**

Loading…
Cancel
Save