Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

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

Closed
1 of 2 tasks
mingc00 opened this issue May 10, 2017 · 4 comments · Fixed by #2948
Closed
1 of 2 tasks

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

mingc00 opened this issue May 10, 2017 · 4 comments · Fixed by #2948
Milestone

Comments

@mingc00
Copy link

mingc00 commented May 10, 2017

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)

@adrai
Copy link

adrai commented May 10, 2017

same issue even if directly emitting a message in the connect event handler

@darrachequesne
Copy link
Member

darrachequesne commented May 10, 2017

@mingc00 thanks for the fiddle, I could indeed reproduce.

It seems to be related to #2833, the CONNECT packet is sent too early.

@adrai
Copy link

adrai commented May 15, 2017

same issue as: #2866

@mxq19901028
Copy link

How to ignore the LTS certificate problem?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants