2012/1/12 Shamanin, Andrey <[email protected]>: > Hi! Whether socket_t::send() can report about delivery error? For example, > destination is 'down', but send() returns true. This question concerns to > ZMQ_PUSH/ZMQ_REQ sockets.
Sending is asynchronous, i.e. your app thread sends to an IO thread which does the work in the background. send() will return an error only if the IO thread refuses the message or there is another programming error. Network errors are handled according to the type of socket. For PUSH/DEALER/REQ sockets, the IO thread queues the message and delivers to a peer when it can. So app A can send a message, then app B can connect to A and recv the message. If you need A to detect that there is no B, or that B disappeared, you add this intelligence on top. The Guide has examples of how to do this, in the section on Reliable Request Reply. -Pieter _______________________________________________ zeromq-dev mailing list [email protected] http://lists.zeromq.org/mailman/listinfo/zeromq-dev
