July 15th, 2024

ZeroMQ: High-Performance Concurrency Framework

ZeroMQ is a versatile open-source messaging library supporting various messaging patterns and multiple transports. It excels in high-speed asynchronous I/O and is utilized by companies like Microsoft and Facebook.

Read original articleLink Icon
ZeroMQ: High-Performance Concurrency Framework

ZeroMQ is an open-source messaging library offering sockets for transmitting atomic messages across various transports. It supports patterns like fan-out, pub-sub, and request-reply, making it suitable for clustered products with fast asynchronous I/O capabilities. ZeroMQ is versatile, running on multiple operating systems and offering language APIs. It enables universal connectivity in any language on any platform, with smart patterns like pub-sub and client-server. The library excels in high-speed asynchronous I/O engines and supports multiple transports including inproc, IPC, TCP, UDP, and WebSocket. ZeroMQ boasts a vibrant open-source community and provides a comprehensive guide with numerous examples in various languages. Notable companies like Microsoft, Samsung, and Facebook utilize ZeroMQ in their products.

Related

Link Icon 9 comments
By @thesuperbigfrog - 4 months
ZeroMQ was followed by nanomsg (https://nanomsg.org/) and nng (https://nng.nanomsg.org/)

Some of Martin's rationale here:

https://250bpm.com/blog:23/index.html

ZeroMQ is still widely used and popular, but I am not sure if it is still actively developed.

By @sigmonsays - 4 months
I would rather use sockets. Not getting errors when a client times out is a bad api design to me. I've used zeromq an only kept it around for IPC.

I may have been doing it wrong, but i personally want to know when clients disconnect/reconnect/etc. the API seems to hide all that from you and your send or recv just block.

By @aitchnyu - 4 months
As a new dev in 2011, I was unsuccessfully making a http worker thing in Python with Zeromq and I was distracted by their docs were encouraging replacing callback architecture with message passing with inproc queues.
By @1vuio0pswjnm7 - 4 months
Appreciate the rosettacode-like (chrestomathy) approach to documentation:

https://zguide.zeromq.org/

By @jobulanus - 4 months
NATS is the ZeroMQ of today.
By @sidcool - 4 months
Anything new with ZeroMQ? It's been around for a long time.
By @mafuy - 4 months
I've never used ZeroMQ. How does it compare to MPI? I assume it is easier to use?
By @mharig - 4 months
If an app needs a DB anyway, has ZeroMQ then advantages over a DB based MQ, like PostgreSQL LISTEN/NOTIFY or SQLite with update_hook?

Did anybody compare throughput/latency for these approaches? Edit: ... for the basic zmq patterns PUB/SUB, REQ/REP, Client/Server