How to use ZeroMQ for raw UDP?

udp, zeromq

Solution

UDP Support for ZMQ is now documented here: http://api.zeromq.org/master:zmq-udp

Pyzmq version 18 has it as well, stating: "Protocols supported include tcp, udp, pgm, epgm, inproc and ipc." That said, my experimentation with Python hasn't found a solution that works yet. I get "protocol is not compatible with socket type" errors.

Problem

I have a client, whose code I can't change -- but I'd like to (re)write using `ZeroMQ` sockets. The clients use both raw `TCP` and raw `UDP` sockets. I know I can use `ZMQ_ROUTER_RAW` for raw `TCP` sockets, but what about for raw `UDP` datastreams?

Original source