On Tue, Jul 1, 2014 at 4:46 PM, Goswin von Brederlow <[email protected]> wrote:

> 1) with ROUTER/DEALER I don't get a message when a subscriber
> disconnects without unsubscribing.
>
> Eventualy the heartbeat will get it but that can take a long time and
> a lot of messages can queue up inbetween for no good reason.

There is no other way, in practice. Even if libzmq reports the TCP
disconnect, there are cases where the network connection will block
and die without reporting an error. You must eventually use
heartbeats. You can tune these to a few seconds.

> So I tried using a monitor socket. But that only gives me the FD and
> address of the receiving socket:

No use IMO.

> 2) with XPUB/XSUB the CURVE metadata seems to get lost
>
> zmq_msg_gets() always returns Null it seems. I think the problem is
> that zmq::xpub_t::xread_activated just appends the message data to its
> internal std::deque. A ROUTER socket on the other hand attaches the
> pipe to its fair queue.
>
> Should this be rewritten to use a fair queue too?

That would make sense, yes.

-Pieter
_______________________________________________
zeromq-dev mailing list
[email protected]
http://lists.zeromq.org/mailman/listinfo/zeromq-dev

Reply via email to