[zeromq-dev] Any way to get info on subscribers?

Martin Sustrik sustrik at 250bpm.com
Sat Jul 24 09:42:31 CEST 2010


> With PUB/SUB sockets, is there any way for the publisher to get 
> information about the address of the subscribers, or at the very least 
> how many subscribers there are?
> Would I have to switch to a different socket pattern if I needed this 
> information?

This info is in principle not available. 0MQ abstracts from the notion 
of individual connections. All you have is an opaque cloud of peers.

Think of PUB/SUB over IP multicast. There's no way to find out who's 
receiving the data you are sending.

All in all, if you need to handle individual connections manually, you 
should go for standard sockets rather than 0MQ.


More information about the zeromq-dev mailing list