[zeromq-dev] Sending via ROUTER socket to ROUTER socket fails initially with "No route to host"

Pieter Hintjens ph at imatix.com
Mon Apr 8 19:35:34 CEST 2013


OK, we found it. There is some internal handshaking before a message
can be routed, even if the ROUTER socket connects out. There's no way
for libzmq to know the identity of the peer until it receives the
identity from the peer.

ROUTER pipes are created only for known identities, i.e. for a peer
that has sent us its identity, no matter who connected to whom.

We could force pipe creation in some way but it would require changes.

Hope this helps.

-Pieter

On Fri, Apr 5, 2013 at 11:13 PM, Anoop Karollil
<anoop.karollil at gmail.com> wrote:
> Pieter Hintjens wrote:
>>
>> On Mon, Apr 1, 2013 at 6:23 PM, Anoop Karollil <anoop.karollil at gmail.com>
>> wrote:
>>
>>> Pieter, any clue as to why the send with the connected (not bound)
>>> ROUTER socket might be failing initially?
>>
>>
>> No clue, but if you can make a minimal test case in C, we can
>> investigate. Afaik it should work and this would be considered a bug.
>
>
> Attached are two C programs that reproduce the problem. The broker binds and
> receives. The client connects and then sends. The send fails initially and
> then succeeds.
>
> Anoop
>
> _______________________________________________
> zeromq-dev mailing list
> zeromq-dev at lists.zeromq.org
> http://lists.zeromq.org/mailman/listinfo/zeromq-dev
>



More information about the zeromq-dev mailing list