[zeromq-dev] Double connect problem in XREP to XREP

Antonio Delgado Peris antonio.delgado.peris at cern.ch
Thu Mar 17 09:41:34 CET 2011


Hi Martin,

Thanks. I tested the fix for my small use case: A connects to B, then B 
connects to A then any of them tries to send. No error found, so it 
works perfectly fine for me. It actually works fine even if A or B call 
connect several more times (just for the fun of trying).

Just to be complete, in your previous email, in reply to the problem 
description you wrote:
> This should not happen. Instead, the connection with duplicate 
> identity should be rejected by the peer.

I understood (possibly incorrectly) this meant the second connect would 
fail. This is not what I'm seeing, I see the second connect succeed 
silently. Actually, this is nicer for me but I mention it in case it is 
not what you wanted to happen.

One more thing, as I said, the second (and subsequent) connect call 
looks like a no-op for the caller (i.e., any 'send' works the same with 
one or more previous connects). I was wondering if there is hidden 
effect like duplicating internal connections (so more resources 
consumed), or one can assume that it is just the same to call connect 
once or more times.

Thanks again.

Cheers,
     Antonio


> Hi Anotonio,
>
>>>> Assertion failed: ok (xrep.cpp:61)
>>>
>>> This should not happen. Instead, the connection with duplicate
>>> identity should be rejected by the peer.
>
> Fix was made to master (revision 32ded2b). You can check whether it 
> works like expected.
>
> Martin




More information about the zeromq-dev mailing list