[nanomsg] Re: Nanomsg and ZMQ

  • From: Alan Wright <alan@xxxxxxxxxxx>
  • To: nanomsg@xxxxxxxxxxxxx
  • Date: Tue, 2 Apr 2013 14:35:40 +0200

Ok, that makes sense, thanks.

I understand the motivations behind nanomsg and it's desire to fix the
architectural problems of zmq (code internals) but I wasn't aware this
extended to the wire protocol itself.

Do you have any plans to introduce any kind of compatibility layer for zmq
in the future? Or do the protocols diverge so much that it's untenable?


On 2 April 2013 12:57, Martin Sustrik <sustrik@xxxxxxxxxx> wrote:

> On 02/04/13 12:24, Charles Remes wrote:
>
>> Nanomsg and ZMQ are not compatible. There is a ZMQ-compatibility API so
>> that you can share *code*, but you can not hook up a nanomsg socket to a
>> zmq socket.
>>
>
> Correct.
>
> To give you some background:
>
> One of the goals of nanomsg is to fix architectural problems in 0MQ. This
> mostly affects internals of the library (e.g. threading model) and is not
> visible from the outside.
>
> However, one problem that happens to be visible is conflation of
> individual layers in the wire protocol. There are 3 layers involved:
> transport (such as TCP of PGM), scalability pattern layer (such as REQ/REP
> or PUB/SUB) and presentation layer (multi-part messages). Lately, addition
> of end-to-end encryption -- which can be thought as yet another layer -- is
> being discussed.
>
> In ZeroMQ it's one monolithic protocol that handles all these layers. The
> result is that in the implementation is not modular. For example, there's
> no single piece of code to deal with multi-part messages. Instead, the code
> is scattered in TCP transport code, REQ/REP pattern code, PUB/SUB pattern
> code etc. Such code is a pain to implement and maintain and it is prone to
> subtle bugs.
>
> Martin
>
>

Other related posts: