SocketCluster / SocketCluster/socketcluster

Socket Connect Error: Unknown request

Open
#502 3 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
JavaScript
Stars
6.2k
Forks
318
PR merge metrics
No merged PRs in 30d

Description

Hello, I've been trying to dockerize a really old socketcluster app that we have here and it keeps trying to connect to some other service... I can't find in the code where this is happening. Is there a way to show what endpoint it is trying to connect to? I think if I knew what it was trying to do then it would be a lot easier to diagnosis where this is failing. Thanks!

{ SocketProtocolError: Socket hung up
    at SCClientSocket._onSCClose (/app/node_modules/socketcluster-client/lib/scclientsocket.js:654:15)
    at SCTransport.<anonymous> (/app/node_modules/socketcluster-client/lib/scclientsocket.js:304:12)
    at SCTransport.Emitter.emit (/app/node_modules/component-emitter/index.js:133:20)
    at SCTransport._onClose (/app/node_modules/socketcluster-client/lib/sctransport.js:217:28)
    at WebSocket.SCTransport.wsSocket.onerror (/app/node_modules/socketcluster-client/lib/sctransport.js:81:12)
    at WebSocket.onError (/app/node_modules/socketcluster-client/node_modules/ws/lib/event-target.js:128:16)
    at emitOne (events.js:116:13)
    at WebSocket.emit (events.js:211:7)
    at ClientRequest.req.on (/app/node_modules/socketcluster-client/node_modules/ws/lib/websocket.js:535:10)
    at emitOne (events.js:116:13)
  name: 'SocketProtocolError',
  message: 'Socket hung up',
  code: 1006 }

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reading the close and error paths in socketcluster-client/lib/scclientsocket.js and socketcluster-client/lib/sctransport.js, using the reported stack trace as the entry point. Reproduce the Dockerized connection failure and clarify where diagnostic endpoint information should appear; done should make the attempted endpoint visible when this connection error occurs.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript, nodejs
Domain
backend, networking
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.