![]() |
在Matlab中接收时,JeroMQ订户连接中断
在Matlab中使用JeroMQ,当我尝试recv消息时,我的订阅者连接断开。我已经用Wireshark验证了这一点。我还注意到,TCP连接的关闭是由我的订阅端口而不是发布端口启动的。
javaclasspath('jeromq-0.5.1.jar') import org.zeromq.*; ctx = zmq.Ctx(); socket = ctx.createSocket(ZMQ.SUB); socket.connect('tcp://127.0.0.1:5996') message = socket.recv(1) %this is when the connection gets dropped [URL="https://i.stack.imgur.com/QJ9ha.png"]Wireshark屏幕截图显示连接已关闭[/URL] 我不确定是否会有所帮助,但是我已经对此进行了调查, socket.setSocketOpt(ZMQ.ZMQ_TCP_KEEPALIVE,1) 但是Matlab报告ZMQ_TCP_KEEPALIVE是无法识别的函数或变量。 我很感谢[URL="https://stackoverflow.com/questions/38060320/how-to-use-jeromq-in-matlab/44865494#44865494"]这个[/URL]话题,让我从Matlab的JeroMQ入手。 [url=https://stackoverflow.com/q/59179878]更多&回答...[/url] |
所有时间均为北京时间。现在的时间是 23:17。 |
Powered by vBulletin
版权所有 ©2000 - 2025,Jelsoft Enterprises Ltd.