简体   繁体   English

GDAX WebSocket冻结

[英]GDAX websocket freezing

I'm trying to create a simple algorithmic trader using the node.js GDAX library. 我正在尝试使用node.js GDAX库创建一个简单的算法交易者。 I have an implementation that works fairly well however the websocket is randomly freezing with no close event emitted.i have searched the forums but cannot find a solution to this, my only guess is that the server is ceasing to emit messages as the close event is not transmitted. 我有一个运行良好的实现,但是websocket随机冻结,没有发出关闭事件。我已经搜索了论坛,但是找不到解决方案,我唯一的猜测是服务器由于关闭事件而不再发出消息没有传送。

I'm fairly new to node.js and websocket so I'm not even sure where to look. 我对node.js和websocket相当陌生,所以我什至不知道在哪里看。

FYI I have code that will automatically re-connect the socket on close but I'm not sure how to implement this if I don't have a trigger event. 仅供参考,我有代码可以在关闭时自动重新连接套接字,但是如果我没有触发事件,我不确定如何实现。

Have asked gdax/coinbase support about this in the past. 过去曾询问过gdax / coinbase支持。 My own theory was they issued some update, the server was updated and the connection broken. 我自己的理论是,他们发布了一些更新,更新了服务器并且断开了连接。 Therefore coinbase's solution was to also monitor the heartbeat channel. 因此,coinbase的解决方案是还监视心跳通道。 There really isn't a great alternative solution in place at the moment. 目前,确实没有一个很好的替代解决方案。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM