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

Question about websockets.c #250

Open
alanswx opened this issue May 24, 2019 · 1 comment
Open

Question about websockets.c #250

alanswx opened this issue May 24, 2019 · 1 comment

Comments

@alanswx
Copy link

alanswx commented May 24, 2019

It seems like the websockets code (when in single threaded mode) sits inside it's own loop and doesn't service any of the other HTTP requests. Is this correct, or did I miss something in how to call the code?

How hard would it be to change it so that it returns to the main poll loop between websocket messages?

@davidmoreno
Copy link
Owner

It is correct.

It should be possible, but the event loop has no support for write epoll, so would block writing. Which is much better than blocking reading and writing.

If you manage to get a patch working, I will be glad to merge it.

Regards,
David.

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

2 participants