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

KucoinFuturesWebsocketListener : Error -> javax.net.ssl.SSLException: Connection reset #8

Open
SametKAYIRAN opened this issue May 29, 2021 · 0 comments
Assignees
Labels
enhancement New feature or request

Comments

@SametKAYIRAN
Copy link

Although I applied the solution, Kucoin/kucoin-java-sdk#41, while socket running gets the exception below. The socket can work for a maximum of 1 day without any errors. Are there any ways to solve this problem or auto reconnect again when the exception occurs?

2021-05-29 03:14:24.151 ERROR 13061 --- [.kucoin.com/...] k.f.c.w.l.KucoinFuturesWebsocketListener : Error on private socket

javax.net.ssl.SSLException: Connection reset
at java.base/sun.security.ssl.Alert.createSSLException(Alert.java:127) ~[na:na]
at java.base/sun.security.ssl.TransportContext.fatal(TransportContext.java:349) ~[na:na]
at java.base/sun.security.ssl.TransportContext.fatal(TransportContext.java:292) ~[na:na]
at java.base/sun.security.ssl.TransportContext.fatal(TransportContext.java:287) ~[na:na]
at java.base/sun.security.ssl.SSLTransport.decode(SSLTransport.java:144) ~[na:na]
at java.base/sun.security.ssl.SSLSocketImpl.decode(SSLSocketImpl.java:1421) ~[na:na]
at java.base/sun.security.ssl.SSLSocketImpl.readApplicationRecord(SSLSocketImpl.java:1386) ~[na:na]
at java.base/sun.security.ssl.SSLSocketImpl$AppInputStream.read(SSLSocketImpl.java:973) ~[na:na]
at okio.Okio$2.read(Okio.java:140) ~[okio-1.17.2.jar!/:na]
at okio.AsyncTimeout$2.read(AsyncTimeout.java:237) ~[okio-1.17.2.jar!/:na]
at okio.RealBufferedSource.request(RealBufferedSource.java:72) ~[okio-1.17.2.jar!/:na]
at okio.RealBufferedSource.require(RealBufferedSource.java:65) ~[okio-1.17.2.jar!/:na]
at okio.RealBufferedSource.readByte(RealBufferedSource.java:78) ~[okio-1.17.2.jar!/:na]
at okhttp3.internal.ws.WebSocketReader.readHeader(WebSocketReader.java:117) ~[okhttp-3.14.9.jar!/:na]
at okhttp3.internal.ws.WebSocketReader.processNextFrame(WebSocketReader.java:101) ~[okhttp-3.14.9.jar!/:na]
at okhttp3.internal.ws.RealWebSocket.loopReader(RealWebSocket.java:273) ~[okhttp-3.14.9.jar!/:na]
at okhttp3.internal.ws.RealWebSocket$1.onResponse(RealWebSocket.java:209) ~[okhttp-3.14.9.jar!/:na]
at okhttp3.RealCall$AsyncCall.execute(RealCall.java:174) ~[okhttp-3.14.9.jar!/:na]
at okhttp3.internal.NamedRunnable.run(NamedRunnable.java:32) ~[okhttp-3.14.9.jar!/:na]
at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128) ~[na:na]
at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628) ~[na:na]
at java.base/java.lang.Thread.run(Thread.java:829) ~[na:na]
Suppressed: java.net.SocketException: Broken pipe (Write failed)
at java.base/java.net.SocketOutputStream.socketWrite0(Native Method) ~[na:na]
at java.base/java.net.SocketOutputStream.socketWrite(SocketOutputStream.java:110) ~[na:na]
at java.base/java.net.SocketOutputStream.write(SocketOutputStream.java:150) ~[na:na]
at java.base/sun.security.ssl.SSLSocketOutputRecord.encodeAlert(SSLSocketOutputRecord.java:81) ~[na:na]
at java.base/sun.security.ssl.TransportContext.fatal(TransportContext.java:380) ~[na:na]
... 20 common frames omitted
Caused by: java.net.SocketException: Connection reset
at java.base/java.net.SocketInputStream.read(SocketInputStream.java:186) ~[na:na]
at java.base/java.net.SocketInputStream.read(SocketInputStream.java:140) ~[na:na]
at java.base/sun.security.ssl.SSLSocketInputRecord.read(SSLSocketInputRecord.java:478) ~[na:na]
at java.base/sun.security.ssl.SSLSocketInputRecord.readFully(SSLSocketInputRecord.java:461) ~[na:na]
at java.base/sun.security.ssl.SSLSocketInputRecord.decodeInputRecord(SSLSocketInputRecord.java:243) ~[na:na]
at java.base/sun.security.ssl.SSLSocketInputRecord.decode(SSLSocketInputRecord.java:181) ~[na:na]
at java.base/sun.security.ssl.SSLTransport.decode(SSLTransport.java:110) ~[na:na]
... 17 common frames omitted

@ISAAC-XXYYZZ ISAAC-XXYYZZ self-assigned this Aug 12, 2024
@ISAAC-XXYYZZ ISAAC-XXYYZZ added the enhancement New feature or request label Aug 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants