[zeromq-dev] Question Regarding XREP

Dhammika Pathirana dhammika at gmail.com
Thu Dec 2 17:46:43 CET 2010

On Thu, Dec 2, 2010 at 1:22 AM, Praveen Baratam
<praveen.baratam+zmq at gmail.com> wrote:
> Dear Dhammika and Chuck,
> I am trying to use an XREP socket as a PUB socket with publisher side
> filtering. In our case we dont need multiple subscriptions from a single
> sub-socket, so we are trying to use  XREQ sockets as sinks and XREP socket
> as router as discussed in the guide - Advanced Stuff Chapter. Its working to
> our expectations but zmq fails with assertion at line 60 in xrep.cpp
> sometimes. I believe thats because of duplicate identitites.
> <CODE>
> //  TODO: What if new connection has same peer identity as the old one?
> outpipe_t outpipe = {outpipe_, true};
> bool ok = outpipes.insert (outpipes_t::value_type (
>             peer_identity_, outpipe)).second;
> zmq_assert (ok);   //-------------> Failing here
> </CODE>

oops, we've fixed it for other sockets, but not for XREQ/XREP.
Can you open tickets for this and identity deletion issue?
If possible, pls add code samples.



More information about the zeromq-dev mailing list