Hello everyone.
I'm having a problem getting a secure websocket connection (B4J client to B4J server) to connect consistently....
Based on the various examples in the forum, I've merged the Websocket Push framework with the SQLite version of jRDC2 created by @OliverA, and created a client B4J app to connect to it using Basic Authentication.
That works fine.
I'm now been trying to change it to use secure connections (https and wss) using a self-signed certificate based on the info in:
When not using SSL the connection from the client app to the RDC app via https & wss is established OK every time.
But when using SSL, the websocket connection errors on the first connection attempt with the following error in the logs, but then usually connects successfully when the ReconnectTimer kicks in. The https connection still connects OK every time.
I've created and attached simple example apps that demonstrate the problem:
jRDC-withWS.zip is the server app. I've put a copy of the self created keystore file in the .../Objects/ folder which is where the app looks for it when run through the IDE (File.DirApp)
SecureWStest.zip is the client app:
Commenting/uncommenting line 40/41 in Main will switch it between using http & https
Commenting/uncommenting line 47/48 in WSPushService will switch it between using ws & wss for the websocket.
I've also attached a blank SQLite database which the RDC app expects to find in C:\B4J\ (lines 33 & 34 in RDCConnector in jRDC-WS)
Can anyone tell me why the websocket connection fails with SSL on the first connection attempt every time?
I'm having a problem getting a secure websocket connection (B4J client to B4J server) to connect consistently....
Based on the various examples in the forum, I've merged the Websocket Push framework with the SQLite version of jRDC2 created by @OliverA, and created a client B4J app to connect to it using Basic Authentication.
That works fine.
I'm now been trying to change it to use secure connections (https and wss) using a self-signed certificate based on the info in:
[Server] SSL Connections
Starting from B4J v2.00 the server can listen to two ports, the standard insecure port (http) and a secure port (https). The default port for http is 80 and for https is 443. These ports are used when the url doesn't explicitly specify a port number. It is recommended to go over the Wikipedia...
www.b4x.com
How to create a WebSocketClient that accepts all certificates
Dear All, As requested by Erel in: https://www.b4x.com/android/forum/threads/retrieving-websocket-data-from-webview.88748/#post-562332 .. here´s a new thread on this topic. Issue: the WebSocketClient library in b4j does not have an option to bypass certificate security check as it´s the case...
www.b4x.com
[B4X] OkHttpUtils2 / iHttpUtils2 and accept all option
Note that OkHttpUtils2, jOkHttpUtils2 and iHttpUtils2 are actually the exact same b4x library. jOkHttpUtils2_NONUI was required as a special version for non-ui B4J apps. It is no longer required and shouldn't be used. Starting from v2.90 it is very simple to initialize the internal http client...
www.b4x.com
When not using SSL the connection from the client app to the RDC app via https & wss is established OK every time.
But when using SSL, the websocket connection errors on the first connection attempt with the following error in the logs, but then usually connects successfully when the ReconnectTimer kicks in. The https connection still connects OK every time.
Waiting for debugger to connect...
Program started.
(Http client initialized with accept all option.)
Create
2022-08-11 12:30:47.606:INFO::JavaFX Application Thread: Logging initialized @4102ms to org.eclipse.jetty.util.log.StdErrLog
UpdateStatus: false
org.eclipse.jetty.websocket.api.UpgradeException: 0 null
at org.eclipse.jetty.websocket.client.WebSocketUpgradeRequest.onComplete(WebSocketUpgradeRequest.java:515)
at org.eclipse.jetty.client.ResponseNotifier.notifyComplete(ResponseNotifier.java:193)
at org.eclipse.jetty.client.ResponseNotifier.notifyComplete(ResponseNotifier.java:185)
at org.eclipse.jetty.client.HttpReceiver.terminateResponse(HttpReceiver.java:464)
at org.eclipse.jetty.client.HttpReceiver.abort(HttpReceiver.java:545)
at org.eclipse.jetty.client.HttpReceiver.responseFailure(HttpReceiver.java:436)
at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.failAndClose(HttpReceiverOverHTTP.java:369)
at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.earlyEOF(HttpReceiverOverHTTP.java:338)
at org.eclipse.jetty.http.HttpParser.parseNext(HttpParser.java:1476)
at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.shutdown(HttpReceiverOverHTTP.java:209)
at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.process(HttpReceiverOverHTTP.java:147)
at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.receive(HttpReceiverOverHTTP.java:73)
at org.eclipse.jetty.client.http.HttpChannelOverHTTP.receive(HttpChannelOverHTTP.java:133)
at org.eclipse.jetty.client.http.HttpConnectionOverHTTP.onFillable(HttpConnectionOverHTTP.java:155)
at org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(AbstractConnection.java:281)
at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:102)
at org.eclipse.jetty.io.ssl.SslConnection.onFillable(SslConnection.java:291)
at org.eclipse.jetty.io.ssl.SslConnection$3.succeeded(SslConnection.java:151)
at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:102)
at org.eclipse.jetty.io.ChannelEndPoint$2.run(ChannelEndPoint.java:118)
at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.runTask(EatWhatYouKill.java:333)
at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.doProduce(EatWhatYouKill.java:310)
at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.tryProduce(EatWhatYouKill.java:168)
at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.run(EatWhatYouKill.java:126)
at org.eclipse.jetty.util.thread.ReservedThreadExecutor$ReservedThread.run(ReservedThreadExecutor.java:366)
at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:760)
at org.eclipse.jetty.util.thread.QueuedThreadPool$2.run(QueuedThreadPool.java:678)
at java.base/java.lang.Thread.run(Thread.java:834)
Caused by: java.io.EOFException: HttpConnectionOverHTTP@6d5ea1e5(l:/127.0.0.1:51238 <-> r:localhost/127.0.0.1:17179,closed=false)=>HttpChannelOverHTTP@35e689a7(exchange=HttpExchange@7d953507 req=TERMINATED/null@null res=PENDING/null@null)[send=HttpSenderOverHTTP@2d39e3c4(req=QUEUED,snd=COMPLETED,failure=null)[HttpGenerator@30825cf6{s=START}],recv=HttpReceiverOverHTTP@31a850f0(rsp=IDLE,failure=null)[HttpParser{s=CLOSED,0 of -1}]]<-DecryptedEndPoint@561ffc02{localhost/127.0.0.1:17179<->/127.0.0.1:51238,OPEN,fill=-,flush=-,to=11/0}->HttpConnectionOverHTTP@6d5ea1e5(l:/127.0.0.1:51238 <-> r:localhost/127.0.0.1:17179,closed=false)=>HttpChannelOverHTTP@35e689a7(exchange=HttpExchange@7d953507 req=TERMINATED/null@null res=PENDING/null@null)[send=HttpSenderOverHTTP@2d39e3c4(req=QUEUED,snd=COMPLETED,failure=null)[HttpGenerator@30825cf6{s=START}],recv=HttpReceiverOverHTTP@31a850f0(rsp=IDLE,failure=null)[HttpParser{s=CLOSED,0 of -1}]]->SocketChannelEndPoint@38868f10{localhost/127.0.0.1:17179<->/127.0.0.1:51238,ISHUT,fill=-,flush=-,to=10/0}{io=0/0,kio=0,kro=1}->SslConnection@1bd261fe{NEED_WRAP,eio=-1/-1,di=-1}=>HttpConnectionOverHTTP@6d5ea1e5(l:/127.0.0.1:51238 <-> r:localhost/127.0.0.1:17179,closed=false)=>HttpChannelOverHTTP@35e689a7(exchange=HttpExchange@7d953507 req=TERMINATED/null@null res=PENDING/null@null)[send=HttpSenderOverHTTP@2d39e3c4(req=QUEUED,snd=COMPLETED,failure=null)[HttpGenerator@30825cf6{s=START}],recv=HttpReceiverOverHTTP@31a850f0(rsp=IDLE,failure=null)[HttpParser{s=CLOSED,0 of -1}]]
... 21 more
org.eclipse.jetty.websocket.api.UpgradeException: 0 null
at org.eclipse.jetty.websocket.client.WebSocketUpgradeRequest.onComplete(WebSocketUpgradeRequest.java:522)
at org.eclipse.jetty.client.ResponseNotifier.notifyComplete(ResponseNotifier.java:193)
at org.eclipse.jetty.client.ResponseNotifier.notifyComplete(ResponseNotifier.java:185)
at org.eclipse.jetty.client.HttpReceiver.terminateResponse(HttpReceiver.java:464)
at org.eclipse.jetty.client.HttpReceiver.abort(HttpReceiver.java:545)
at org.eclipse.jetty.client.HttpReceiver.responseFailure(HttpReceiver.java:436)
at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.failAndClose(HttpReceiverOverHTTP.java:369)
at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.earlyEOF(HttpReceiverOverHTTP.java:338)
at org.eclipse.jetty.http.HttpParser.parseNext(HttpParser.java:1476)
at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.shutdown(HttpReceiverOverHTTP.java:209)
at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.process(HttpReceiverOverHTTP.java:147)
at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.receive(HttpReceiverOverHTTP.java:73)
at org.eclipse.jetty.client.http.HttpChannelOverHTTP.receive(HttpChannelOverHTTP.java:133)
at org.eclipse.jetty.client.http.HttpConnectionOverHTTP.onFillable(HttpConnectionOverHTTP.java:155)
at org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(AbstractConnection.java:281)
at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:102)
at org.eclipse.jetty.io.ssl.SslConnection.onFillable(SslConnection.java:291)
at org.eclipse.jetty.io.ssl.SslConnection$3.succeeded(SslConnection.java:151)
at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:102)
at org.eclipse.jetty.io.ChannelEndPoint$2.run(ChannelEndPoint.java:118)
at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.runTask(EatWhatYouKill.java:333)
at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.doProduce(EatWhatYouKill.java:310)
at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.tryProduce(EatWhatYouKill.java:168)
at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.run(EatWhatYouKill.java:126)
at org.eclipse.jetty.util.thread.ReservedThreadExecutor$ReservedThread.run(ReservedThreadExecutor.java:366)
at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:760)
at org.eclipse.jetty.util.thread.QueuedThreadPool$2.run(QueuedThreadPool.java:678)
at java.base/java.lang.Thread.run(Thread.java:834)
java.util.concurrent.ExecutionException: org.eclipse.jetty.websocket.api.UpgradeException: 0 null
at java.base/java.util.concurrent.CompletableFuture.reportGet(CompletableFuture.java:395)
at java.base/java.util.concurrent.CompletableFuture.get(CompletableFuture.java:1999)
at anywhersoftware.b4j.objects.WebSocketClientWrapper.Close(WebSocketClientWrapper.java:102)
at anywhersoftware.b4j.objects.WebSocketClientWrapper$WSHandler.onWebSocketError(WebSocketClientWrapper.java:151)
at org.eclipse.jetty.websocket.common.events.JettyListenerEventDriver.onError(JettyListenerEventDriver.java:112)
at org.eclipse.jetty.websocket.common.events.AbstractEventDriver.incomingError(AbstractEventDriver.java:96)
at org.eclipse.jetty.websocket.client.WebSocketUpgradeRequest.handleException(WebSocketUpgradeRequest.java:528)
at org.eclipse.jetty.websocket.client.WebSocketUpgradeRequest.onComplete(WebSocketUpgradeRequest.java:522)
at org.eclipse.jetty.client.ResponseNotifier.notifyComplete(ResponseNotifier.java:193)
at org.eclipse.jetty.client.ResponseNotifier.notifyComplete(ResponseNotifier.java:185)
at org.eclipse.jetty.client.HttpReceiver.terminateResponse(HttpReceiver.java:464)
at org.eclipse.jetty.client.HttpReceiver.abort(HttpReceiver.java:545)
at org.eclipse.jetty.client.HttpReceiver.responseFailure(HttpReceiver.java:436)
at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.failAndClose(HttpReceiverOverHTTP.java:369)
at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.earlyEOF(HttpReceiverOverHTTP.java:338)
at org.eclipse.jetty.http.HttpParser.parseNext(HttpParser.java:1476)
at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.shutdown(HttpReceiverOverHTTP.java:209)
at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.process(HttpReceiverOverHTTP.java:147)
at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.receive(HttpReceiverOverHTTP.java:73)
at org.eclipse.jetty.client.http.HttpChannelOverHTTP.receive(HttpChannelOverHTTP.java:133)
at org.eclipse.jetty.client.http.HttpConnectionOverHTTP.onFillable(HttpConnectionOverHTTP.java:155)
at org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(AbstractConnection.java:281)
at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:102)
at org.eclipse.jetty.io.ssl.SslConnection.onFillable(SslConnection.java:291)
at org.eclipse.jetty.io.ssl.SslConnection$3.succeeded(SslConnection.java:151)
at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:102)
at org.eclipse.jetty.io.ChannelEndPoint$2.run(ChannelEndPoint.java:118)
at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.runTask(EatWhatYouKill.java:333)
at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.doProduce(EatWhatYouKill.java:310)
at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.tryProduce(EatWhatYouKill.java:168)
at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.run(EatWhatYouKill.java:126)
at org.eclipse.jetty.util.thread.ReservedThreadExecutor$ReservedThread.run(ReservedThreadExecutor.java:366)
at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:760)
at org.eclipse.jetty.util.thread.QueuedThreadPool$2.run(QueuedThreadPool.java:678)
at java.base/java.lang.Thread.run(Thread.java:834)
Caused by: org.eclipse.jetty.websocket.api.UpgradeException: 0 null
at org.eclipse.jetty.websocket.client.WebSocketUpgradeRequest.onComplete(WebSocketUpgradeRequest.java:515)
... 27 more
Caused by: java.io.EOFException: HttpConnectionOverHTTP@6d5ea1e5(l:/127.0.0.1:51238 <-> r:localhost/127.0.0.1:17179,closed=false)=>HttpChannelOverHTTP@35e689a7(exchange=HttpExchange@7d953507 req=TERMINATED/null@null res=PENDING/null@null)[send=HttpSenderOverHTTP@2d39e3c4(req=QUEUED,snd=COMPLETED,failure=null)[HttpGenerator@30825cf6{s=START}],recv=HttpReceiverOverHTTP@31a850f0(rsp=IDLE,failure=null)[HttpParser{s=CLOSED,0 of -1}]]<-DecryptedEndPoint@561ffc02{localhost/127.0.0.1:17179<->/127.0.0.1:51238,OPEN,fill=-,flush=-,to=11/0}->HttpConnectionOverHTTP@6d5ea1e5(l:/127.0.0.1:51238 <-> r:localhost/127.0.0.1:17179,closed=false)=>HttpChannelOverHTTP@35e689a7(exchange=HttpExchange@7d953507 req=TERMINATED/null@null res=PENDING/null@null)[send=HttpSenderOverHTTP@2d39e3c4(req=QUEUED,snd=COMPLETED,failure=null)[HttpGenerator@30825cf6{s=START}],recv=HttpReceiverOverHTTP@31a850f0(rsp=IDLE,failure=null)[HttpParser{s=CLOSED,0 of -1}]]->SocketChannelEndPoint@38868f10{localhost/127.0.0.1:17179<->/127.0.0.1:51238,ISHUT,fill=-,flush=-,to=10/0}{io=0/0,kio=0,kro=1}->SslConnection@1bd261fe{NEED_WRAP,eio=-1/-1,di=-1}=>HttpConnectionOverHTTP@6d5ea1e5(l:/127.0.0.1:51238 <-> r:localhost/127.0.0.1:17179,closed=false)=>HttpChannelOverHTTP@35e689a7(exchange=HttpExchange@7d953507 req=TERMINATED/null@null res=PENDING/null@null)[send=HttpSenderOverHTTP@2d39e3c4(req=QUEUED,snd=COMPLETED,failure=null)[HttpGenerator@30825cf6{s=START}],recv=HttpReceiverOverHTTP@31a850f0(rsp=IDLE,failure=null)[HttpParser{s=CLOSED,0 of -1}]]
... 21 more
WebSocket Closed: 0 null
UpdateStatus: false
org.eclipse.jetty.websocket.api.UpgradeException: 0 null
at org.eclipse.jetty.websocket.client.WebSocketUpgradeRequest.onComplete(WebSocketUpgradeRequest.java:515)
at org.eclipse.jetty.client.ResponseNotifier.notifyComplete(ResponseNotifier.java:193)
at org.eclipse.jetty.client.ResponseNotifier.notifyComplete(ResponseNotifier.java:185)
at org.eclipse.jetty.client.HttpReceiver.terminateResponse(HttpReceiver.java:464)
at org.eclipse.jetty.client.HttpReceiver.abort(HttpReceiver.java:545)
at org.eclipse.jetty.client.HttpReceiver.responseFailure(HttpReceiver.java:436)
at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.failAndClose(HttpReceiverOverHTTP.java:369)
at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.earlyEOF(HttpReceiverOverHTTP.java:338)
at org.eclipse.jetty.http.HttpParser.parseNext(HttpParser.java:1476)
at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.shutdown(HttpReceiverOverHTTP.java:209)
at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.process(HttpReceiverOverHTTP.java:147)
at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.receive(HttpReceiverOverHTTP.java:73)
at org.eclipse.jetty.client.http.HttpChannelOverHTTP.receive(HttpChannelOverHTTP.java:133)
at org.eclipse.jetty.client.http.HttpConnectionOverHTTP.onFillable(HttpConnectionOverHTTP.java:155)
at org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(AbstractConnection.java:281)
at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:102)
at org.eclipse.jetty.io.ssl.SslConnection.onFillable(SslConnection.java:291)
at org.eclipse.jetty.io.ssl.SslConnection$3.succeeded(SslConnection.java:151)
at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:102)
at org.eclipse.jetty.io.ChannelEndPoint$2.run(ChannelEndPoint.java:118)
at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.runTask(EatWhatYouKill.java:333)
at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.doProduce(EatWhatYouKill.java:310)
at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.tryProduce(EatWhatYouKill.java:168)
at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.run(EatWhatYouKill.java:126)
at org.eclipse.jetty.util.thread.ReservedThreadExecutor$ReservedThread.run(ReservedThreadExecutor.java:366)
at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:760)
at org.eclipse.jetty.util.thread.QueuedThreadPool$2.run(QueuedThreadPool.java:678)
at java.base/java.lang.Thread.run(Thread.java:834)
Caused by: java.io.EOFException: HttpConnectionOverHTTP@7e070747(l:/127.0.0.1:51246 <-> r:localhost/127.0.0.1:17179,closed=false)=>HttpChannelOverHTTP@339ac900(exchange=HttpExchange@3d5d2103 req=TERMINATED/null@null res=PENDING/null@null)[send=HttpSenderOverHTTP@3962a270(req=QUEUED,snd=COMPLETED,failure=null)[HttpGenerator@7c602b38{s=START}],recv=HttpReceiverOverHTTP@19d73f7d(rsp=IDLE,failure=null)[HttpParser{s=CLOSED,0 of -1}]]<-DecryptedEndPoint@4d56507d{localhost/127.0.0.1:17179<->/127.0.0.1:51246,OPEN,fill=-,flush=-,to=8/0}->HttpConnectionOverHTTP@7e070747(l:/127.0.0.1:51246 <-> r:localhost/127.0.0.1:17179,closed=false)=>HttpChannelOverHTTP@339ac900(exchange=HttpExchange@3d5d2103 req=TERMINATED/null@null res=PENDING/null@null)[send=HttpSenderOverHTTP@3962a270(req=QUEUED,snd=COMPLETED,failure=null)[HttpGenerator@7c602b38{s=START}],recv=HttpReceiverOverHTTP@19d73f7d(rsp=IDLE,failure=null)[HttpParser{s=CLOSED,0 of -1}]]->SocketChannelEndPoint@610b1a85{localhost/127.0.0.1:17179<->/127.0.0.1:51246,ISHUT,fill=-,flush=-,to=6/0}{io=0/0,kio=0,kro=1}->SslConnection@1c4fd477{NEED_WRAP,eio=-1/-1,di=-1}=>HttpConnectionOverHTTP@7e070747(l:/127.0.0.1:51246 <-> r:localhost/127.0.0.1:17179,closed=false)=>HttpChannelOverHTTP@339ac900(exchange=HttpExchange@3d5d2103 req=TERMINATED/null@null res=PENDING/null@null)[send=HttpSenderOverHTTP@3962a270(req=QUEUED,snd=COMPLETED,failure=null)[HttpGenerator@7c602b38{s=START}],recv=HttpReceiverOverHTTP@19d73f7d(rsp=IDLE,failure=null)[HttpParser{s=CLOSED,0 of -1}]]
... 21 more
org.eclipse.jetty.websocket.api.UpgradeException: 0 null
at org.eclipse.jetty.websocket.client.WebSocketUpgradeRequest.onComplete(WebSocketUpgradeRequest.java:522)
at org.eclipse.jetty.client.ResponseNotifier.notifyComplete(ResponseNotifier.java:193)
at org.eclipse.jetty.client.ResponseNotifier.notifyComplete(ResponseNotifier.java:185)
at org.eclipse.jetty.client.HttpReceiver.terminateResponse(HttpReceiver.java:464)
at org.eclipse.jetty.client.HttpReceiver.abort(HttpReceiver.java:545)
at org.eclipse.jetty.client.HttpReceiver.responseFailure(HttpReceiver.java:436)
at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.failAndClose(HttpReceiverOverHTTP.java:369)
at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.earlyEOF(HttpReceiverOverHTTP.java:338)
at org.eclipse.jetty.http.HttpParser.parseNext(HttpParser.java:1476)
at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.shutdown(HttpReceiverOverHTTP.java:209)
at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.process(HttpReceiverOverHTTP.java:147)
at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.receive(HttpReceiverOverHTTP.java:73)
at org.eclipse.jetty.client.http.HttpChannelOverHTTP.receive(HttpChannelOverHTTP.java:133)
at org.eclipse.jetty.client.http.HttpConnectionOverHTTP.onFillable(HttpConnectionOverHTTP.java:155)
at org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(AbstractConnection.java:281)
at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:102)
at org.eclipse.jetty.io.ssl.SslConnection.onFillable(SslConnection.java:291)
at org.eclipse.jetty.io.ssl.SslConnection$3.succeeded(SslConnection.java:151)
at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:102)
at org.eclipse.jetty.io.ChannelEndPoint$2.run(ChannelEndPoint.java:118)
at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.runTask(EatWhatYouKill.java:333)
at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.doProduce(EatWhatYouKill.java:310)
at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.tryProduce(EatWhatYouKill.java:168)
at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.run(EatWhatYouKill.java:126)
at org.eclipse.jetty.util.thread.ReservedThreadExecutor$ReservedThread.run(ReservedThreadExecutor.java:366)
at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:760)
at org.eclipse.jetty.util.thread.QueuedThreadPool$2.run(QueuedThreadPool.java:678)
at java.base/java.lang.Thread.run(Thread.java:834)
java.util.concurrent.ExecutionException: org.eclipse.jetty.websocket.api.UpgradeException: 0 null
at java.base/java.util.concurrent.CompletableFuture.reportGet(CompletableFuture.java:395)
at java.base/java.util.concurrent.CompletableFuture.get(CompletableFuture.java:1999)
at anywhersoftware.b4j.objects.WebSocketClientWrapper.Close(WebSocketClientWrapper.java:102)
at anywhersoftware.b4j.objects.WebSocketClientWrapper$WSHandler.onWebSocketError(WebSocketClientWrapper.java:151)
at org.eclipse.jetty.websocket.common.events.JettyListenerEventDriver.onError(JettyListenerEventDriver.java:112)
at org.eclipse.jetty.websocket.common.events.AbstractEventDriver.incomingError(AbstractEventDriver.java:96)
at org.eclipse.jetty.websocket.client.WebSocketUpgradeRequest.handleException(WebSocketUpgradeRequest.java:528)
at org.eclipse.jetty.websocket.client.WebSocketUpgradeRequest.onComplete(WebSocketUpgradeRequest.java:522)
at org.eclipse.jetty.client.ResponseNotifier.notifyComplete(ResponseNotifier.java:193)
at org.eclipse.jetty.client.ResponseNotifier.notifyComplete(ResponseNotifier.java:185)
at org.eclipse.jetty.client.HttpReceiver.terminateResponse(HttpReceiver.java:464)
at org.eclipse.jetty.client.HttpReceiver.abort(HttpReceiver.java:545)
at org.eclipse.jetty.client.HttpReceiver.responseFailure(HttpReceiver.java:436)
at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.failAndClose(HttpReceiverOverHTTP.java:369)
at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.earlyEOF(HttpReceiverOverHTTP.java:338)
at org.eclipse.jetty.http.HttpParser.parseNext(HttpParser.java:1476)
at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.shutdown(HttpReceiverOverHTTP.java:209)
at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.process(HttpReceiverOverHTTP.java:147)
at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.receive(HttpReceiverOverHTTP.java:73)
at org.eclipse.jetty.client.http.HttpChannelOverHTTP.receive(HttpChannelOverHTTP.java:133)
at org.eclipse.jetty.client.http.HttpConnectionOverHTTP.onFillable(HttpConnectionOverHTTP.java:155)
at org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(AbstractConnection.java:281)
at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:102)
at org.eclipse.jetty.io.ssl.SslConnection.onFillable(SslConnection.java:291)
at org.eclipse.jetty.io.ssl.SslConnection$3.succeeded(SslConnection.java:151)
at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:102)
at org.eclipse.jetty.io.ChannelEndPoint$2.run(ChannelEndPoint.java:118)
at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.runTask(EatWhatYouKill.java:333)
at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.doProduce(EatWhatYouKill.java:310)
at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.tryProduce(EatWhatYouKill.java:168)
at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.run(EatWhatYouKill.java:126)
at org.eclipse.jetty.util.thread.ReservedThreadExecutor$ReservedThread.run(ReservedThreadExecutor.java:366)
at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:760)
at org.eclipse.jetty.util.thread.QueuedThreadPool$2.run(QueuedThreadPool.java:678)
at java.base/java.lang.Thread.run(Thread.java:834)
Caused by: org.eclipse.jetty.websocket.api.UpgradeException: 0 null
at org.eclipse.jetty.websocket.client.WebSocketUpgradeRequest.onComplete(WebSocketUpgradeRequest.java:515)
... 27 more
Caused by: java.io.EOFException: HttpConnectionOverHTTP@7e070747(l:/127.0.0.1:51246 <-> r:localhost/127.0.0.1:17179,closed=false)=>HttpChannelOverHTTP@339ac900(exchange=HttpExchange@3d5d2103 req=TERMINATED/null@null res=PENDING/null@null)[send=HttpSenderOverHTTP@3962a270(req=QUEUED,snd=COMPLETED,failure=null)[HttpGenerator@7c602b38{s=START}],recv=HttpReceiverOverHTTP@19d73f7d(rsp=IDLE,failure=null)[HttpParser{s=CLOSED,0 of -1}]]<-DecryptedEndPoint@4d56507d{localhost/127.0.0.1:17179<->/127.0.0.1:51246,OPEN,fill=-,flush=-,to=8/0}->HttpConnectionOverHTTP@7e070747(l:/127.0.0.1:51246 <-> r:localhost/127.0.0.1:17179,closed=false)=>HttpChannelOverHTTP@339ac900(exchange=HttpExchange@3d5d2103 req=TERMINATED/null@null res=PENDING/null@null)[send=HttpSenderOverHTTP@3962a270(req=QUEUED,snd=COMPLETED,failure=null)[HttpGenerator@7c602b38{s=START}],recv=HttpReceiverOverHTTP@19d73f7d(rsp=IDLE,failure=null)[HttpParser{s=CLOSED,0 of -1}]]->SocketChannelEndPoint@610b1a85{localhost/127.0.0.1:17179<->/127.0.0.1:51246,ISHUT,fill=-,flush=-,to=6/0}{io=0/0,kio=0,kro=1}->SslConnection@1c4fd477{NEED_WRAP,eio=-1/-1,di=-1}=>HttpConnectionOverHTTP@7e070747(l:/127.0.0.1:51246 <-> r:localhost/127.0.0.1:17179,closed=false)=>HttpChannelOverHTTP@339ac900(exchange=HttpExchange@3d5d2103 req=TERMINATED/null@null res=PENDING/null@null)[send=HttpSenderOverHTTP@3962a270(req=QUEUED,snd=COMPLETED,failure=null)[HttpGenerator@7c602b38{s=START}],recv=HttpReceiverOverHTTP@19d73f7d(rsp=IDLE,failure=null)[HttpParser{s=CLOSED,0 of -1}]]
... 21 more
WebSocket Closed: 0 null
UpdateStatus: false
WebSocket Connected <------- when the ReconnectTimer tries again to connect the websocket
wsh.ws.Connected=true
UpdateStatus: true
wsh_NewMessage
msgID= 14
msgText= connection is secure
Main.NewMessage
Program started.
(Http client initialized with accept all option.)
Create
2022-08-11 12:30:47.606:INFO::JavaFX Application Thread: Logging initialized @4102ms to org.eclipse.jetty.util.log.StdErrLog
UpdateStatus: false
org.eclipse.jetty.websocket.api.UpgradeException: 0 null
at org.eclipse.jetty.websocket.client.WebSocketUpgradeRequest.onComplete(WebSocketUpgradeRequest.java:515)
at org.eclipse.jetty.client.ResponseNotifier.notifyComplete(ResponseNotifier.java:193)
at org.eclipse.jetty.client.ResponseNotifier.notifyComplete(ResponseNotifier.java:185)
at org.eclipse.jetty.client.HttpReceiver.terminateResponse(HttpReceiver.java:464)
at org.eclipse.jetty.client.HttpReceiver.abort(HttpReceiver.java:545)
at org.eclipse.jetty.client.HttpReceiver.responseFailure(HttpReceiver.java:436)
at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.failAndClose(HttpReceiverOverHTTP.java:369)
at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.earlyEOF(HttpReceiverOverHTTP.java:338)
at org.eclipse.jetty.http.HttpParser.parseNext(HttpParser.java:1476)
at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.shutdown(HttpReceiverOverHTTP.java:209)
at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.process(HttpReceiverOverHTTP.java:147)
at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.receive(HttpReceiverOverHTTP.java:73)
at org.eclipse.jetty.client.http.HttpChannelOverHTTP.receive(HttpChannelOverHTTP.java:133)
at org.eclipse.jetty.client.http.HttpConnectionOverHTTP.onFillable(HttpConnectionOverHTTP.java:155)
at org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(AbstractConnection.java:281)
at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:102)
at org.eclipse.jetty.io.ssl.SslConnection.onFillable(SslConnection.java:291)
at org.eclipse.jetty.io.ssl.SslConnection$3.succeeded(SslConnection.java:151)
at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:102)
at org.eclipse.jetty.io.ChannelEndPoint$2.run(ChannelEndPoint.java:118)
at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.runTask(EatWhatYouKill.java:333)
at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.doProduce(EatWhatYouKill.java:310)
at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.tryProduce(EatWhatYouKill.java:168)
at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.run(EatWhatYouKill.java:126)
at org.eclipse.jetty.util.thread.ReservedThreadExecutor$ReservedThread.run(ReservedThreadExecutor.java:366)
at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:760)
at org.eclipse.jetty.util.thread.QueuedThreadPool$2.run(QueuedThreadPool.java:678)
at java.base/java.lang.Thread.run(Thread.java:834)
Caused by: java.io.EOFException: HttpConnectionOverHTTP@6d5ea1e5(l:/127.0.0.1:51238 <-> r:localhost/127.0.0.1:17179,closed=false)=>HttpChannelOverHTTP@35e689a7(exchange=HttpExchange@7d953507 req=TERMINATED/null@null res=PENDING/null@null)[send=HttpSenderOverHTTP@2d39e3c4(req=QUEUED,snd=COMPLETED,failure=null)[HttpGenerator@30825cf6{s=START}],recv=HttpReceiverOverHTTP@31a850f0(rsp=IDLE,failure=null)[HttpParser{s=CLOSED,0 of -1}]]<-DecryptedEndPoint@561ffc02{localhost/127.0.0.1:17179<->/127.0.0.1:51238,OPEN,fill=-,flush=-,to=11/0}->HttpConnectionOverHTTP@6d5ea1e5(l:/127.0.0.1:51238 <-> r:localhost/127.0.0.1:17179,closed=false)=>HttpChannelOverHTTP@35e689a7(exchange=HttpExchange@7d953507 req=TERMINATED/null@null res=PENDING/null@null)[send=HttpSenderOverHTTP@2d39e3c4(req=QUEUED,snd=COMPLETED,failure=null)[HttpGenerator@30825cf6{s=START}],recv=HttpReceiverOverHTTP@31a850f0(rsp=IDLE,failure=null)[HttpParser{s=CLOSED,0 of -1}]]->SocketChannelEndPoint@38868f10{localhost/127.0.0.1:17179<->/127.0.0.1:51238,ISHUT,fill=-,flush=-,to=10/0}{io=0/0,kio=0,kro=1}->SslConnection@1bd261fe{NEED_WRAP,eio=-1/-1,di=-1}=>HttpConnectionOverHTTP@6d5ea1e5(l:/127.0.0.1:51238 <-> r:localhost/127.0.0.1:17179,closed=false)=>HttpChannelOverHTTP@35e689a7(exchange=HttpExchange@7d953507 req=TERMINATED/null@null res=PENDING/null@null)[send=HttpSenderOverHTTP@2d39e3c4(req=QUEUED,snd=COMPLETED,failure=null)[HttpGenerator@30825cf6{s=START}],recv=HttpReceiverOverHTTP@31a850f0(rsp=IDLE,failure=null)[HttpParser{s=CLOSED,0 of -1}]]
... 21 more
org.eclipse.jetty.websocket.api.UpgradeException: 0 null
at org.eclipse.jetty.websocket.client.WebSocketUpgradeRequest.onComplete(WebSocketUpgradeRequest.java:522)
at org.eclipse.jetty.client.ResponseNotifier.notifyComplete(ResponseNotifier.java:193)
at org.eclipse.jetty.client.ResponseNotifier.notifyComplete(ResponseNotifier.java:185)
at org.eclipse.jetty.client.HttpReceiver.terminateResponse(HttpReceiver.java:464)
at org.eclipse.jetty.client.HttpReceiver.abort(HttpReceiver.java:545)
at org.eclipse.jetty.client.HttpReceiver.responseFailure(HttpReceiver.java:436)
at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.failAndClose(HttpReceiverOverHTTP.java:369)
at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.earlyEOF(HttpReceiverOverHTTP.java:338)
at org.eclipse.jetty.http.HttpParser.parseNext(HttpParser.java:1476)
at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.shutdown(HttpReceiverOverHTTP.java:209)
at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.process(HttpReceiverOverHTTP.java:147)
at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.receive(HttpReceiverOverHTTP.java:73)
at org.eclipse.jetty.client.http.HttpChannelOverHTTP.receive(HttpChannelOverHTTP.java:133)
at org.eclipse.jetty.client.http.HttpConnectionOverHTTP.onFillable(HttpConnectionOverHTTP.java:155)
at org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(AbstractConnection.java:281)
at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:102)
at org.eclipse.jetty.io.ssl.SslConnection.onFillable(SslConnection.java:291)
at org.eclipse.jetty.io.ssl.SslConnection$3.succeeded(SslConnection.java:151)
at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:102)
at org.eclipse.jetty.io.ChannelEndPoint$2.run(ChannelEndPoint.java:118)
at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.runTask(EatWhatYouKill.java:333)
at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.doProduce(EatWhatYouKill.java:310)
at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.tryProduce(EatWhatYouKill.java:168)
at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.run(EatWhatYouKill.java:126)
at org.eclipse.jetty.util.thread.ReservedThreadExecutor$ReservedThread.run(ReservedThreadExecutor.java:366)
at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:760)
at org.eclipse.jetty.util.thread.QueuedThreadPool$2.run(QueuedThreadPool.java:678)
at java.base/java.lang.Thread.run(Thread.java:834)
java.util.concurrent.ExecutionException: org.eclipse.jetty.websocket.api.UpgradeException: 0 null
at java.base/java.util.concurrent.CompletableFuture.reportGet(CompletableFuture.java:395)
at java.base/java.util.concurrent.CompletableFuture.get(CompletableFuture.java:1999)
at anywhersoftware.b4j.objects.WebSocketClientWrapper.Close(WebSocketClientWrapper.java:102)
at anywhersoftware.b4j.objects.WebSocketClientWrapper$WSHandler.onWebSocketError(WebSocketClientWrapper.java:151)
at org.eclipse.jetty.websocket.common.events.JettyListenerEventDriver.onError(JettyListenerEventDriver.java:112)
at org.eclipse.jetty.websocket.common.events.AbstractEventDriver.incomingError(AbstractEventDriver.java:96)
at org.eclipse.jetty.websocket.client.WebSocketUpgradeRequest.handleException(WebSocketUpgradeRequest.java:528)
at org.eclipse.jetty.websocket.client.WebSocketUpgradeRequest.onComplete(WebSocketUpgradeRequest.java:522)
at org.eclipse.jetty.client.ResponseNotifier.notifyComplete(ResponseNotifier.java:193)
at org.eclipse.jetty.client.ResponseNotifier.notifyComplete(ResponseNotifier.java:185)
at org.eclipse.jetty.client.HttpReceiver.terminateResponse(HttpReceiver.java:464)
at org.eclipse.jetty.client.HttpReceiver.abort(HttpReceiver.java:545)
at org.eclipse.jetty.client.HttpReceiver.responseFailure(HttpReceiver.java:436)
at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.failAndClose(HttpReceiverOverHTTP.java:369)
at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.earlyEOF(HttpReceiverOverHTTP.java:338)
at org.eclipse.jetty.http.HttpParser.parseNext(HttpParser.java:1476)
at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.shutdown(HttpReceiverOverHTTP.java:209)
at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.process(HttpReceiverOverHTTP.java:147)
at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.receive(HttpReceiverOverHTTP.java:73)
at org.eclipse.jetty.client.http.HttpChannelOverHTTP.receive(HttpChannelOverHTTP.java:133)
at org.eclipse.jetty.client.http.HttpConnectionOverHTTP.onFillable(HttpConnectionOverHTTP.java:155)
at org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(AbstractConnection.java:281)
at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:102)
at org.eclipse.jetty.io.ssl.SslConnection.onFillable(SslConnection.java:291)
at org.eclipse.jetty.io.ssl.SslConnection$3.succeeded(SslConnection.java:151)
at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:102)
at org.eclipse.jetty.io.ChannelEndPoint$2.run(ChannelEndPoint.java:118)
at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.runTask(EatWhatYouKill.java:333)
at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.doProduce(EatWhatYouKill.java:310)
at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.tryProduce(EatWhatYouKill.java:168)
at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.run(EatWhatYouKill.java:126)
at org.eclipse.jetty.util.thread.ReservedThreadExecutor$ReservedThread.run(ReservedThreadExecutor.java:366)
at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:760)
at org.eclipse.jetty.util.thread.QueuedThreadPool$2.run(QueuedThreadPool.java:678)
at java.base/java.lang.Thread.run(Thread.java:834)
Caused by: org.eclipse.jetty.websocket.api.UpgradeException: 0 null
at org.eclipse.jetty.websocket.client.WebSocketUpgradeRequest.onComplete(WebSocketUpgradeRequest.java:515)
... 27 more
Caused by: java.io.EOFException: HttpConnectionOverHTTP@6d5ea1e5(l:/127.0.0.1:51238 <-> r:localhost/127.0.0.1:17179,closed=false)=>HttpChannelOverHTTP@35e689a7(exchange=HttpExchange@7d953507 req=TERMINATED/null@null res=PENDING/null@null)[send=HttpSenderOverHTTP@2d39e3c4(req=QUEUED,snd=COMPLETED,failure=null)[HttpGenerator@30825cf6{s=START}],recv=HttpReceiverOverHTTP@31a850f0(rsp=IDLE,failure=null)[HttpParser{s=CLOSED,0 of -1}]]<-DecryptedEndPoint@561ffc02{localhost/127.0.0.1:17179<->/127.0.0.1:51238,OPEN,fill=-,flush=-,to=11/0}->HttpConnectionOverHTTP@6d5ea1e5(l:/127.0.0.1:51238 <-> r:localhost/127.0.0.1:17179,closed=false)=>HttpChannelOverHTTP@35e689a7(exchange=HttpExchange@7d953507 req=TERMINATED/null@null res=PENDING/null@null)[send=HttpSenderOverHTTP@2d39e3c4(req=QUEUED,snd=COMPLETED,failure=null)[HttpGenerator@30825cf6{s=START}],recv=HttpReceiverOverHTTP@31a850f0(rsp=IDLE,failure=null)[HttpParser{s=CLOSED,0 of -1}]]->SocketChannelEndPoint@38868f10{localhost/127.0.0.1:17179<->/127.0.0.1:51238,ISHUT,fill=-,flush=-,to=10/0}{io=0/0,kio=0,kro=1}->SslConnection@1bd261fe{NEED_WRAP,eio=-1/-1,di=-1}=>HttpConnectionOverHTTP@6d5ea1e5(l:/127.0.0.1:51238 <-> r:localhost/127.0.0.1:17179,closed=false)=>HttpChannelOverHTTP@35e689a7(exchange=HttpExchange@7d953507 req=TERMINATED/null@null res=PENDING/null@null)[send=HttpSenderOverHTTP@2d39e3c4(req=QUEUED,snd=COMPLETED,failure=null)[HttpGenerator@30825cf6{s=START}],recv=HttpReceiverOverHTTP@31a850f0(rsp=IDLE,failure=null)[HttpParser{s=CLOSED,0 of -1}]]
... 21 more
WebSocket Closed: 0 null
UpdateStatus: false
org.eclipse.jetty.websocket.api.UpgradeException: 0 null
at org.eclipse.jetty.websocket.client.WebSocketUpgradeRequest.onComplete(WebSocketUpgradeRequest.java:515)
at org.eclipse.jetty.client.ResponseNotifier.notifyComplete(ResponseNotifier.java:193)
at org.eclipse.jetty.client.ResponseNotifier.notifyComplete(ResponseNotifier.java:185)
at org.eclipse.jetty.client.HttpReceiver.terminateResponse(HttpReceiver.java:464)
at org.eclipse.jetty.client.HttpReceiver.abort(HttpReceiver.java:545)
at org.eclipse.jetty.client.HttpReceiver.responseFailure(HttpReceiver.java:436)
at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.failAndClose(HttpReceiverOverHTTP.java:369)
at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.earlyEOF(HttpReceiverOverHTTP.java:338)
at org.eclipse.jetty.http.HttpParser.parseNext(HttpParser.java:1476)
at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.shutdown(HttpReceiverOverHTTP.java:209)
at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.process(HttpReceiverOverHTTP.java:147)
at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.receive(HttpReceiverOverHTTP.java:73)
at org.eclipse.jetty.client.http.HttpChannelOverHTTP.receive(HttpChannelOverHTTP.java:133)
at org.eclipse.jetty.client.http.HttpConnectionOverHTTP.onFillable(HttpConnectionOverHTTP.java:155)
at org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(AbstractConnection.java:281)
at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:102)
at org.eclipse.jetty.io.ssl.SslConnection.onFillable(SslConnection.java:291)
at org.eclipse.jetty.io.ssl.SslConnection$3.succeeded(SslConnection.java:151)
at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:102)
at org.eclipse.jetty.io.ChannelEndPoint$2.run(ChannelEndPoint.java:118)
at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.runTask(EatWhatYouKill.java:333)
at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.doProduce(EatWhatYouKill.java:310)
at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.tryProduce(EatWhatYouKill.java:168)
at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.run(EatWhatYouKill.java:126)
at org.eclipse.jetty.util.thread.ReservedThreadExecutor$ReservedThread.run(ReservedThreadExecutor.java:366)
at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:760)
at org.eclipse.jetty.util.thread.QueuedThreadPool$2.run(QueuedThreadPool.java:678)
at java.base/java.lang.Thread.run(Thread.java:834)
Caused by: java.io.EOFException: HttpConnectionOverHTTP@7e070747(l:/127.0.0.1:51246 <-> r:localhost/127.0.0.1:17179,closed=false)=>HttpChannelOverHTTP@339ac900(exchange=HttpExchange@3d5d2103 req=TERMINATED/null@null res=PENDING/null@null)[send=HttpSenderOverHTTP@3962a270(req=QUEUED,snd=COMPLETED,failure=null)[HttpGenerator@7c602b38{s=START}],recv=HttpReceiverOverHTTP@19d73f7d(rsp=IDLE,failure=null)[HttpParser{s=CLOSED,0 of -1}]]<-DecryptedEndPoint@4d56507d{localhost/127.0.0.1:17179<->/127.0.0.1:51246,OPEN,fill=-,flush=-,to=8/0}->HttpConnectionOverHTTP@7e070747(l:/127.0.0.1:51246 <-> r:localhost/127.0.0.1:17179,closed=false)=>HttpChannelOverHTTP@339ac900(exchange=HttpExchange@3d5d2103 req=TERMINATED/null@null res=PENDING/null@null)[send=HttpSenderOverHTTP@3962a270(req=QUEUED,snd=COMPLETED,failure=null)[HttpGenerator@7c602b38{s=START}],recv=HttpReceiverOverHTTP@19d73f7d(rsp=IDLE,failure=null)[HttpParser{s=CLOSED,0 of -1}]]->SocketChannelEndPoint@610b1a85{localhost/127.0.0.1:17179<->/127.0.0.1:51246,ISHUT,fill=-,flush=-,to=6/0}{io=0/0,kio=0,kro=1}->SslConnection@1c4fd477{NEED_WRAP,eio=-1/-1,di=-1}=>HttpConnectionOverHTTP@7e070747(l:/127.0.0.1:51246 <-> r:localhost/127.0.0.1:17179,closed=false)=>HttpChannelOverHTTP@339ac900(exchange=HttpExchange@3d5d2103 req=TERMINATED/null@null res=PENDING/null@null)[send=HttpSenderOverHTTP@3962a270(req=QUEUED,snd=COMPLETED,failure=null)[HttpGenerator@7c602b38{s=START}],recv=HttpReceiverOverHTTP@19d73f7d(rsp=IDLE,failure=null)[HttpParser{s=CLOSED,0 of -1}]]
... 21 more
org.eclipse.jetty.websocket.api.UpgradeException: 0 null
at org.eclipse.jetty.websocket.client.WebSocketUpgradeRequest.onComplete(WebSocketUpgradeRequest.java:522)
at org.eclipse.jetty.client.ResponseNotifier.notifyComplete(ResponseNotifier.java:193)
at org.eclipse.jetty.client.ResponseNotifier.notifyComplete(ResponseNotifier.java:185)
at org.eclipse.jetty.client.HttpReceiver.terminateResponse(HttpReceiver.java:464)
at org.eclipse.jetty.client.HttpReceiver.abort(HttpReceiver.java:545)
at org.eclipse.jetty.client.HttpReceiver.responseFailure(HttpReceiver.java:436)
at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.failAndClose(HttpReceiverOverHTTP.java:369)
at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.earlyEOF(HttpReceiverOverHTTP.java:338)
at org.eclipse.jetty.http.HttpParser.parseNext(HttpParser.java:1476)
at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.shutdown(HttpReceiverOverHTTP.java:209)
at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.process(HttpReceiverOverHTTP.java:147)
at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.receive(HttpReceiverOverHTTP.java:73)
at org.eclipse.jetty.client.http.HttpChannelOverHTTP.receive(HttpChannelOverHTTP.java:133)
at org.eclipse.jetty.client.http.HttpConnectionOverHTTP.onFillable(HttpConnectionOverHTTP.java:155)
at org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(AbstractConnection.java:281)
at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:102)
at org.eclipse.jetty.io.ssl.SslConnection.onFillable(SslConnection.java:291)
at org.eclipse.jetty.io.ssl.SslConnection$3.succeeded(SslConnection.java:151)
at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:102)
at org.eclipse.jetty.io.ChannelEndPoint$2.run(ChannelEndPoint.java:118)
at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.runTask(EatWhatYouKill.java:333)
at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.doProduce(EatWhatYouKill.java:310)
at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.tryProduce(EatWhatYouKill.java:168)
at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.run(EatWhatYouKill.java:126)
at org.eclipse.jetty.util.thread.ReservedThreadExecutor$ReservedThread.run(ReservedThreadExecutor.java:366)
at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:760)
at org.eclipse.jetty.util.thread.QueuedThreadPool$2.run(QueuedThreadPool.java:678)
at java.base/java.lang.Thread.run(Thread.java:834)
java.util.concurrent.ExecutionException: org.eclipse.jetty.websocket.api.UpgradeException: 0 null
at java.base/java.util.concurrent.CompletableFuture.reportGet(CompletableFuture.java:395)
at java.base/java.util.concurrent.CompletableFuture.get(CompletableFuture.java:1999)
at anywhersoftware.b4j.objects.WebSocketClientWrapper.Close(WebSocketClientWrapper.java:102)
at anywhersoftware.b4j.objects.WebSocketClientWrapper$WSHandler.onWebSocketError(WebSocketClientWrapper.java:151)
at org.eclipse.jetty.websocket.common.events.JettyListenerEventDriver.onError(JettyListenerEventDriver.java:112)
at org.eclipse.jetty.websocket.common.events.AbstractEventDriver.incomingError(AbstractEventDriver.java:96)
at org.eclipse.jetty.websocket.client.WebSocketUpgradeRequest.handleException(WebSocketUpgradeRequest.java:528)
at org.eclipse.jetty.websocket.client.WebSocketUpgradeRequest.onComplete(WebSocketUpgradeRequest.java:522)
at org.eclipse.jetty.client.ResponseNotifier.notifyComplete(ResponseNotifier.java:193)
at org.eclipse.jetty.client.ResponseNotifier.notifyComplete(ResponseNotifier.java:185)
at org.eclipse.jetty.client.HttpReceiver.terminateResponse(HttpReceiver.java:464)
at org.eclipse.jetty.client.HttpReceiver.abort(HttpReceiver.java:545)
at org.eclipse.jetty.client.HttpReceiver.responseFailure(HttpReceiver.java:436)
at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.failAndClose(HttpReceiverOverHTTP.java:369)
at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.earlyEOF(HttpReceiverOverHTTP.java:338)
at org.eclipse.jetty.http.HttpParser.parseNext(HttpParser.java:1476)
at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.shutdown(HttpReceiverOverHTTP.java:209)
at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.process(HttpReceiverOverHTTP.java:147)
at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.receive(HttpReceiverOverHTTP.java:73)
at org.eclipse.jetty.client.http.HttpChannelOverHTTP.receive(HttpChannelOverHTTP.java:133)
at org.eclipse.jetty.client.http.HttpConnectionOverHTTP.onFillable(HttpConnectionOverHTTP.java:155)
at org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(AbstractConnection.java:281)
at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:102)
at org.eclipse.jetty.io.ssl.SslConnection.onFillable(SslConnection.java:291)
at org.eclipse.jetty.io.ssl.SslConnection$3.succeeded(SslConnection.java:151)
at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:102)
at org.eclipse.jetty.io.ChannelEndPoint$2.run(ChannelEndPoint.java:118)
at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.runTask(EatWhatYouKill.java:333)
at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.doProduce(EatWhatYouKill.java:310)
at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.tryProduce(EatWhatYouKill.java:168)
at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.run(EatWhatYouKill.java:126)
at org.eclipse.jetty.util.thread.ReservedThreadExecutor$ReservedThread.run(ReservedThreadExecutor.java:366)
at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:760)
at org.eclipse.jetty.util.thread.QueuedThreadPool$2.run(QueuedThreadPool.java:678)
at java.base/java.lang.Thread.run(Thread.java:834)
Caused by: org.eclipse.jetty.websocket.api.UpgradeException: 0 null
at org.eclipse.jetty.websocket.client.WebSocketUpgradeRequest.onComplete(WebSocketUpgradeRequest.java:515)
... 27 more
Caused by: java.io.EOFException: HttpConnectionOverHTTP@7e070747(l:/127.0.0.1:51246 <-> r:localhost/127.0.0.1:17179,closed=false)=>HttpChannelOverHTTP@339ac900(exchange=HttpExchange@3d5d2103 req=TERMINATED/null@null res=PENDING/null@null)[send=HttpSenderOverHTTP@3962a270(req=QUEUED,snd=COMPLETED,failure=null)[HttpGenerator@7c602b38{s=START}],recv=HttpReceiverOverHTTP@19d73f7d(rsp=IDLE,failure=null)[HttpParser{s=CLOSED,0 of -1}]]<-DecryptedEndPoint@4d56507d{localhost/127.0.0.1:17179<->/127.0.0.1:51246,OPEN,fill=-,flush=-,to=8/0}->HttpConnectionOverHTTP@7e070747(l:/127.0.0.1:51246 <-> r:localhost/127.0.0.1:17179,closed=false)=>HttpChannelOverHTTP@339ac900(exchange=HttpExchange@3d5d2103 req=TERMINATED/null@null res=PENDING/null@null)[send=HttpSenderOverHTTP@3962a270(req=QUEUED,snd=COMPLETED,failure=null)[HttpGenerator@7c602b38{s=START}],recv=HttpReceiverOverHTTP@19d73f7d(rsp=IDLE,failure=null)[HttpParser{s=CLOSED,0 of -1}]]->SocketChannelEndPoint@610b1a85{localhost/127.0.0.1:17179<->/127.0.0.1:51246,ISHUT,fill=-,flush=-,to=6/0}{io=0/0,kio=0,kro=1}->SslConnection@1c4fd477{NEED_WRAP,eio=-1/-1,di=-1}=>HttpConnectionOverHTTP@7e070747(l:/127.0.0.1:51246 <-> r:localhost/127.0.0.1:17179,closed=false)=>HttpChannelOverHTTP@339ac900(exchange=HttpExchange@3d5d2103 req=TERMINATED/null@null res=PENDING/null@null)[send=HttpSenderOverHTTP@3962a270(req=QUEUED,snd=COMPLETED,failure=null)[HttpGenerator@7c602b38{s=START}],recv=HttpReceiverOverHTTP@19d73f7d(rsp=IDLE,failure=null)[HttpParser{s=CLOSED,0 of -1}]]
... 21 more
WebSocket Closed: 0 null
UpdateStatus: false
WebSocket Connected <------- when the ReconnectTimer tries again to connect the websocket
wsh.ws.Connected=true
UpdateStatus: true
wsh_NewMessage
msgID= 14
msgText= connection is secure
Main.NewMessage
I've created and attached simple example apps that demonstrate the problem:
jRDC-withWS.zip is the server app. I've put a copy of the self created keystore file in the .../Objects/ folder which is where the app looks for it when run through the IDE (File.DirApp)
SecureWStest.zip is the client app:
Commenting/uncommenting line 40/41 in Main will switch it between using http & https
Commenting/uncommenting line 47/48 in WSPushService will switch it between using ws & wss for the websocket.
I've also attached a blank SQLite database which the RDC app expects to find in C:\B4J\ (lines 33 & 34 in RDCConnector in jRDC-WS)
Can anyone tell me why the websocket connection fails with SSL on the first connection attempt every time?
Attachments
Last edited: