Connection declined and throws error #58
Comments
@ssk512 Can you give more context to when you are getting this error. Is this just from running this example project with no changes? This would happen if the client closed the connection before sending a WebSocket close frame. |
yes, I did not do any changes in Code , cloned and ran it. i am getting above error |
@lachlan-roberts how can i fix this issue? |
I went ahead and added unit testing for the Even tested the websocket server with the browser's own javascript client (using the javascript console). Can you provide detail on what you are doing? (there's not enough information provided by you to help you) |
Phone are the clients and hosting the server from my localmachine to join phones I tried with springboot- websocket, no issues but only in jetty facing the issue |
Be accurate, and detailed please.
what phones?
What version of windows 10? (what update? what architecture?) - I ask this as certain Microsoft updates are known to cause issues with various programs. and architectures like ARM are also problematic with java at the moment.
What vendor? What architecture?
What specific version of Maven 3.x? (be accurate, include the whole version, as certain version of Maven have problems)
How did you test with Eclipse IDE?
Which EventServer? (there are 2 of them in the code base)
What's postman? What are the endpoint URIs? What modifications have you made to the codebase to support connecting from different hosts / machines / devices? (you have to had changed something to support this scenario) |
This doesn't tell me anything I can work with. |
Request getting from Phone client GET //10.198.8.78:8888/socket/ HTTP/1.1 Logs from server: 13:13:12.147 [qtp2007331442-17] DEBUG org.eclipse.jetty.server.HttpChannel - HttpChannelOverHttp@31888b18{r=1,c=false,a=IDLE,uri=//10.198.8.78:8888/socket/,age=6} onContentComplete 13:13:12.214 [qtp2007331442-17] DEBUG org.eclipse.jetty.server.HttpConnection - org.eclipse.jetty.server.HttpConnection$SendCallback@19b9444[PROCESSING][i=HTTP/1.1{s=404,h=4,cl=-1},cb=org.eclipse.jetty.server.HttpChannel$CommitCallback@2535ffdc] generate: NEED_HEADER (null,[p=0,l=323,c=32768,r=323],true)@start |
How can i accept only Upgrade from client request ->Connection: close, Upgrade |
If the client is sending that, they are in violation of the WebSocket spec AND the HTTP spec at the same time.
Those 2 headers are not to be sent on a WebSocket Upgrade request.
The Using more than 1 token is effectively making only the first token looked at, all subsequent tokens are ignored. These must be fixed, otherwise you are subject to bad behaviors by any HTTP intermediary, fixing it solely on the server is only a half-measure. |
@joakime I think ABNF in the section of RFC 7230 you reference is wrong, because previous paragraphs of the same section explicitly mention that the For example (from the same section):
In jetty/jetty.project#6642 you actually suggest that we need to support multiple values, no? |
project moved to https://github.com/jetty/jetty-examples |
The text was updated successfully, but these errors were encountered: