Skip to content

Server lost the message which is sent in client reconnect event handler #2935

Closed
@mingc00

Description

@mingc00

Note: for support questions, please use one of these channels: stackoverflow or slack

You want to:

  • report a bug
  • request a feature

Current behaviour

We register asynchronous middleware for authentication. After upgrading socket.io from 1.7.4 to 2.0.1, server cannot get the message if client sent it in reconnect event handler.

Steps to reproduce (if the current behaviour is a bug)

Please reference the code: https://github.com/mingc00/socket.io-fiddle

  1. Register a asynchronous middleware
  2. Startup server
  3. Turn off server after client is connected
  4. Restart the server
  5. Server cannot get the message which is sent in client reconnect event handler.

Note: the best way to get a quick answer is to provide a failing test case, by forking the following fiddle for example.

Expected behaviour

In previous version, server should get the message which is sent in client reconnect event handler.

Setup

  • OS: Ubuntu 16.04
  • browser: Chrome 58
  • socket.io version: 2.0.1

Other information (e.g. stacktraces, related issues, suggestions how to fix)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions