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

WebSocket DeploymentException is not thrown by client nor server #9466

Closed
lorban opened this issue Mar 6, 2023 · 5 comments
Closed

WebSocket DeploymentException is not thrown by client nor server #9466

lorban opened this issue Mar 6, 2023 · 5 comments
Assignees
Labels
Bug For general bugs on Jetty side

Comments

@lorban
Copy link
Contributor

lorban commented Mar 6, 2023

Jetty version(s)
verified:
11.0.x
12.0.x.beta0
still needs confirmation:
9.4.x
10.0.x

Description
In the client code, the multiple jakarta.websocket.WebSocketContainer.connectToServer() methods declare throwing DeploymentException in certain conditions, but only IOException is ever thrown.

In the server code, jakarta.websocket.server.ServerContainer.upgradeHttpToWebSocket() also declares throwing DeploymentException in certain conditions, while only IOException is ever thrown.

javax.websocket implementations should be checked too.

@lorban
Copy link
Contributor Author

lorban commented Mar 6, 2023

@lachlan-roberts your opinion & analysis are more than welcome.

@sbordet
Copy link
Contributor

sbordet commented Apr 12, 2023

@lorban can this be closed?

@lachlan-roberts
Copy link
Contributor

I was reviewing this a while ago and think I even had a branch for it with some small improvements which I seem to have lost.

But the connectToServer implementations can actually throw Deployment exception, and so can upgradeHttpToWebSocket. So I don't think the description in the issue is correct.

@lorban
Copy link
Contributor Author

lorban commented Apr 13, 2023

If @joakime is happy about how we interpreted the spec, then this can be closed.

lachlan-roberts added a commit that referenced this issue Apr 26, 2023
…Container.connectToServer

Signed-off-by: Lachlan Roberts <[email protected]>
lachlan-roberts added a commit that referenced this issue May 1, 2023
…eption

Issue #9466 - review where we throw DeploymentException for WebSocketContainer.connectToServer
@lachlan-roberts
Copy link
Contributor

closing as #9678 has been merged

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug For general bugs on Jetty side
Projects
None yet
Development

No branches or pull requests

4 participants