Fixed SUB method of viewer
This commit is contained in:
parent
a79ca128a5
commit
82af836113
@ -114,6 +114,7 @@ public class ZeroMQViewer implements PlugIn {
|
|||||||
}
|
}
|
||||||
else if(method.equals("SUB")){
|
else if(method.equals("SUB")){
|
||||||
socket = context.socket(ZMQ.SUB);
|
socket = context.socket(ZMQ.SUB);
|
||||||
|
socket.subscribe(""); // Subscribe to all topics
|
||||||
}
|
}
|
||||||
else{
|
else{
|
||||||
logger.severe("Method not supported");
|
logger.severe("Method not supported");
|
||||||
@ -139,8 +140,10 @@ public class ZeroMQViewer implements PlugIn {
|
|||||||
}
|
}
|
||||||
finally{
|
finally{
|
||||||
try{
|
try{
|
||||||
|
logger.info("Close connection");
|
||||||
socket.close();
|
socket.close();
|
||||||
context.term();
|
context.term();
|
||||||
|
logger.info("Connection closed");
|
||||||
}
|
}
|
||||||
catch(Exception e){
|
catch(Exception e){
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user