[zeromq-dev] Best way to loop over incoming messages & raw UDP support

Luca Boccassi luca.boccassi at gmail.com
Tue Jul 25 11:24:04 CEST 2017

On Sat, 2017-07-22 at 23:00 +0200, Andrew Linos wrote:
> Hi,
> I started recently using ZeroMQ (and CZMQ) and I have two questions
> -- any advice greatly appreciated.
> 1) I have a PUB/SUB pair -- what's the most efficient way to loop
> over the incoming messages
> if we want to achieve maximum efficiency? Right now I have created an
> actor for the PUB end, 
> an actor for the SUB, and a zpoller that polls the SUB socket in a
> loop, and receives one message
> at a time. Is that (ie, using one blocking call to the zpoller
> instance per incoming message) the
> correct way to do thing?
> 2) I've read about the STREAM socket type, to talk with non-0mq
> clients via TCP, and I was
> wondering if there's anything similar for UDP? ie, let's say a non-
> 0mq server sends out
> data via multicast UDP, can I receive it somehow via a 0mq socket?
> Thanks,
> Andrew.

Using a poller is the best way, and there is no UDP equivalent of

Kind regards,
Luca Boccassi
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 488 bytes
Desc: This is a digitally signed message part
URL: <https://lists.zeromq.org/pipermail/zeromq-dev/attachments/20170725/71f882f0/attachment.sig>

More information about the zeromq-dev mailing list