This would solve...
The diagnostic channels for WebSocket connections have no request identities to chain up diagnostic information. Listeners of these channels can not associate each diagnostic events with a certain request with the limited information.
For example, undici:websocket:socket_error only provides an error object, without a hint of which websocket request caused the error. So do channels like undici:websocket:open, undici:websocket:ping, and undici:websocket:pong.
The implementation should look like...
The WebSocket diagnostic channel should also provide a consistent request identity (object), like the WebSocket instance.
Additional context
This would solve...
The diagnostic channels for WebSocket connections have no request identities to chain up diagnostic information. Listeners of these channels can not associate each diagnostic events with a certain request with the limited information.
For example,
undici:websocket:socket_erroronly provides anerrorobject, without a hint of which websocket request caused the error. So do channels likeundici:websocket:open,undici:websocket:ping, andundici:websocket:pong.The implementation should look like...
The WebSocket diagnostic channel should also provide a consistent request identity (object), like the
WebSocketinstance.Additional context