-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
Customize a server WebSocket's idle timeout #1985
Comments
would you mind to contribute such feature ? |
Sure, I'll take a look at it. |
@vietj if you share some pointers I may be able to contribute the patch. |
how does the code decide when the timeout should be changed ? |
@vietj I don't know if Netty has a way to differentiate a regular HTTP connection from a Websocket one but one way I can think of this could be done is based on HTTP headers, if the request has the upgrade request the "setWebSocketIdleTimeout" applies. |
I see now indeed it could be done after the upgrade |
@vietj thank you for adding to the roadmap! |
It would be useful if Vert.x permitted the idle timeout to be set on a per WebSocket basis.
Currently, the idle timeout for a server WebSocket can only be set via io.vertx.core.http.HttpServerOptions#setIdleTimeout, but because this is an HTTP server option it applies to all server WebSockets. This prevents someone from specifying different WebSocket idle timeouts based on things like the URI, path, or headers.
The text was updated successfully, but these errors were encountered: