Skip to content

Socket.io multiple connection of same client #857

@ghost

Description

Hi,

I'm currently facing an issue with Socket.io:

  1. When a client connect to the server socket.address is 'undefined:undefined' because socket.handshake.address.address and socket.handshake.address.port don't exist (socket.address is like "127.0.0.1" with string directly not object
  2. If my client (my browser on the same machine - cause I'm in development phase) refresh the page a new connection is created and all api sockets are registered again with the conclusion that when an event is emitted it is emitted many times (depending on a many times the page has been refreshed).

How to avoid the same client to be connected many times and avoiding many registration of socket events for the same client ?

Thanks in advance.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions