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

socket.io does not wait for adapter to indicate that it is ready #3659

Closed
1 of 2 tasks
bytenik opened this issue Oct 5, 2020 · 0 comments
Closed
1 of 2 tasks

socket.io does not wait for adapter to indicate that it is ready #3659

bytenik opened this issue Oct 5, 2020 · 0 comments

Comments

@bytenik
Copy link
Contributor

bytenik commented Oct 5, 2020

You want to:

  • report a bug
  • request a feature

Current behaviour

socket.io instantiates the specified adapter, but does not wait for a callback that it is ready. This works fine for many scenarios, but not one where the adapter needs to spool up long-running processes where the adapter is not ready to do work until they are completed. Connections from clients are handled immediately, and if you use a simple pattern of emit-on-connect from client, an early client can easily connect prior to adapter readiness.

Expected behaviour

socket.io should pass a callback to the adapter constructor and wait for it to be called prior to continuing to stand up.

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

This is particularly critical for the adapter I am developing that works with AWS SQS/SNS -- https://github.com/thinkalpha/socket.io-sqs

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

No branches or pull requests

1 participant