Take a look at the lazy pirate example from the guide, it is exactly for that. Anyway, for that reason using REQ socket is not recommended, it is better to use dealer-router or even better, client-server.
On Thu, Jun 16, 2016 at 2:17 AM, Douglas Petican <[email protected]> wrote: > Just went through a sorta code review today and got asked the question: > what happens if Y module doesn't respond to X modules request? My answer > was: then I coded Y module wrong because the contract is that a request > always gets a reply. Then I started to think.... wait a sec what happens > if the modules are located on different hosts and the link between them > goes down after the request is made? Then surely the response would block > forever. > > I haven't tried it yet but I'm thinking that I need to use poll() with a > timeout and wait only so long for the POLLIN event. Then that means its > okay to actually receive the message. is that the way to do it? Thanks. > > -- > <-Douglas Petican-> > > _______________________________________________ > zeromq-dev mailing list > [email protected] > http://lists.zeromq.org/mailman/listinfo/zeromq-dev
_______________________________________________ zeromq-dev mailing list [email protected] http://lists.zeromq.org/mailman/listinfo/zeromq-dev
