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

Should we close connection on RejectedExecutionException? #457

Open
kachayev opened this issue Dec 23, 2018 · 2 comments
Open

Should we close connection on RejectedExecutionException? #457

kachayev opened this issue Dec 23, 2018 · 2 comments

Comments

@kachayev
Copy link
Collaborator

When rejecting an invalid request, we close the underlying connection here. But when rejecting it because of RejectedExecutionException, we do not. We probably do not need to do this, when reject-handler is defined by the user, but in case we return 503 status code to the client by ourselves.... it might be the case that request body was not consumed and the client misbehaved ignoring our premature response. To make sure this would not break the next request decoding, we probably need to clean everything up by closing the connection. It may lead to increased load on the server when rejected clients will try to reconnect... so I'm wondering about what is the best option here. /cc @ztellman

@ztellman
Copy link
Collaborator

ztellman commented Dec 23, 2018 via email

@kachayev
Copy link
Collaborator Author

If you share this in a separate branch, I can take a look too. I'm working with connection cycle interruptions right now trying to figure out how to deal with them from the point of user's code (both for the server and the client) and how to keep channel's pipeline stable if anything goes wrong.

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

No branches or pull requests

2 participants