[zeromq-dev] PUB/SUB question with IPC

Martin Townsend martin.townsend at xsilon.com
Wed Jul 2 18:11:56 CEST 2014


Hi,

I want to use the pub/sub pattern for interprocess communication. 
Basically I have one application reading measurements and then posts it 
to a number of other processes at a fixed rate of every 500 milliseconds.

One of the subscribing processes is only interested in reading every 2 
seconds.  As it queues you get a time lag.  I tried setting the 
ZMQ_RCVHWM socket option to 1 to just drop old messages but this doesn't 
work.  I suppose I could just create the socket, read the current 
message and tear it down but I was wondering if there is a better way or 
should I just be using some other IPC like shared memory?

Best Regards,
Martin.




More information about the zeromq-dev mailing list