nanomsg Networking Library

nanomsg Networking Library

nanomsg.org

2

About this website

nanomsg is a free and open-source networking library that provides a high-performance, lightweight implementation of several common communication patterns (scalability protocols) for building distributed and concurrent applications. Originally created by Martin Sustrik in 2012 as a C rewrite and reimagining of ZeroMQ (which was created by iMatix in 2007 in C++), nanomsg addresses ZeroMQ's architectural limitations including its use of C++, complex threading model, and lack of a formal specification. Key features: scalability protocols: well-defined communication patterns as separate protocols: PAIR (bidirectional one-to-one between two sockets), PUB/SUB (publish-subscribe with topic filtering), REQ/REP (request-reply for RPC-style communication), SURVEY (surveyor-respondent where one node asks and collects responses from all peers), BUS (routing messages between all connected peers), and PIPELINE (push-pull for load balancing and task distribution). Transport: supports inproc (in-process via shared memory), ipc (inter-process via Unix domain sockets), and tcp. Device mechanism (nn_device) for forwarding messages between two sockets, enabling message brokers and forwarder proxies. Polling: integration with poll(), epoll(), select(), and kqueue() for event-driven I/O. Zero-copy: supports zero-copy message sending and receiving via scatter-gather buffers. nng (nanomsg next generation): the successor library by Garrett D'Amore in 2018, a complete rewrite with TLS support, WebSocket transport, and a cleaner API. MIT.

Tags & Categories

Statistics

2
Views
0
Clicks
0
Like
0
Dislike

Comments

Log In to post a comment

No comments yet. Be the first!