Administrator
3 hours ago 1e792f025712da88d5f53e7ef22462301d6cf071
src/main/java/com/xcong/excoin/modules/okxApi/OkxKlineWebSocketClient.java
@@ -66,8 +66,14 @@
    private final List<OkxChannelHandler> channelHandlers = new ArrayList<>();
    private volatile Runnable onLoginSuccess;
    public WebSocketClient getWebSocketClient() {
        return webSocketClient;
    }
    public void setOnLoginSuccess(Runnable onLoginSuccess) {
        this.onLoginSuccess = onLoginSuccess;
    }
    private final ExecutorService sharedExecutor = Executors.newCachedThreadPool(r -> {
@@ -249,6 +255,9 @@
                        handler.subscribe(webSocketClient);
                    }
                    sendPing();
                    if (onLoginSuccess != null) {
                        onLoginSuccess.run();
                    }
                } else {
                    log.error("[WS] WebSocket登录失败, code:{}, msg:{}", code, response.getString("msg"));
                }