[zeromq-dev] Client request and no answer from the Server

2012-10-11 Thread Anna
Hi! I'm working on ZMQ, I have a class Client that should send 100 request to the server, you can see here both classes: public class Client { public static void main(String[] args){ // Prepare our context and socket ZMQ.Context context = ZMQ.context(1);

Re: [zeromq-dev] router-to-router pattern: how to ensure peer is ready

2012-10-11 Thread Pieter Hintjens
On Thu, Oct 11, 2012 at 1:12 AM, Kah-Chan Low kahchan...@yahoo.com wrote: I am a newbie to ZMQ and in my project I need to use a router-to-router (instead of router-to-dealer) pattern. Right there, you're doing it wrong. Don't try doing router-router, it is a non starter. Instead do

Re: [zeromq-dev] zmq_close() has no effect after fork()

2012-10-11 Thread Pieter Hintjens
On Wed, Oct 10, 2012 at 5:52 PM, John Khvatov iva...@gmail.com wrote: Yep. But ZMQ does not allow to call zmq_close()/zmq_term() in child process. It is wrong... Why not create the context in the forked process where you need it. I.e. after forking, not before. -Pieter

Re: [zeromq-dev] http://php.zero.mq not responding

2012-10-11 Thread Ian Barber
On Wed, Oct 10, 2012 at 3:03 PM, Tuomas Koski koski.tuo...@gmail.com wrote: However the http://php.zero.mq has not been responding for some time (at least in two weeks I think). Is this a known problem? Is there a alternative online documentation? Sorry about that, it is a known problem - the

Re: [zeromq-dev] router-to-router pattern: how to ensure peer is ready

2012-10-11 Thread Kah-Chan Low
Hi Pieter, Just to make sure I get it right, do you mean that each node should have two sockets: 1 router(server) and 1 dealer(client)? Thanks! KC From: Pieter Hintjens p...@imatix.com To: Kah-Chan Low kahchan...@yahoo.com; ZeroMQ development list

Re: [zeromq-dev] http://php.zero.mq not responding

2012-10-11 Thread Tuomas Koski
Hi, On 11 October 2012 12:12, Ian Barber ian.bar...@gmail.com wrote: Sorry about that, it is a known problem - the machine died and it is a pain to regenerate the docs - neither Mikko or myself have had a chance. I will try and take a look at it this weekend, in the meantime there are lots of

Re: [zeromq-dev] Client request and no answer from the Server

2012-10-11 Thread Min
Anna, Could you paste the full source ? Also, kill -3 server_pid might show what blocks the server. Thanks Min 2012/10/10 Anna a...@aphroditel.eu: Hi! I'm working on ZMQ, I have a class Client that should send 100 request to the server, you can see here both classes: public class Client {

Re: [zeromq-dev] Client request and no answer from the Server

2012-10-11 Thread Michel Pelletier
It looks to me like your server only calls recv() once, and the thread only runs once. You need to put that logic in a loop. -Michel On Wed, Oct 10, 2012 at 1:36 AM, Anna a...@aphroditel.eu wrote: Hi! I'm working on ZMQ, I have a class Client that should send 100 request to the server, you

Re: [zeromq-dev] IPC and free ports

2012-10-11 Thread Ian Barber
On Thu, Oct 11, 2012 at 5:14 PM, andrea crotti andrea.crott...@gmail.com wrote: So suppose I want to make sure that I'm not binding twice, what should I do? Check if the file already exists or? Yep try: sock.bind(addr) except zmq.Error: # loop over until find a free channel

[zeromq-dev] ZMQ socket connection -- auto clean-up?

2012-10-11 Thread Kah-Chan Low
In a ZMQ socket connection, if one end dies, does the surviving end perform auto clean-up? Thanks! KC ___ zeromq-dev mailing list zeromq-dev@lists.zeromq.org http://lists.zeromq.org/mailman/listinfo/zeromq-dev

Re: [zeromq-dev] ZMQ socket connection -- auto clean-up?

2012-10-11 Thread Chuck Remes
On Oct 11, 2012, at 8:09 PM, Kah-Chan Low wrote: In a ZMQ socket connection, if one end dies, does the surviving end perform auto clean-up? Yes. cr ___ zeromq-dev mailing list zeromq-dev@lists.zeromq.org

[zeromq-dev] ZeroMQ and hot server restarts

2012-10-11 Thread Merijn Verstraaten
Hey! I've recently started messing around with ZeroMQ and so far I'm happy, but I have one question. With TCP sockets I am enable to do hot server restarts (i.e. start a new binary without dropping connections) by doing fork/exec which keeps the sockets open, meaning that (with some

Re: [zeromq-dev] TOS/DSCP code produces error for epgm

2012-10-11 Thread Rohan Bedarkar
Created issue LIBZMQ-446. Thanks   -- Rohan Bedarkar MS, Computer Science  University of Chicago roh...@cs.uchicago.edu   From: Steven McCoy steven.mc...@miru.hk To: ZeroMQ development list zeromq-dev@lists.zeromq.org Sent: Wednesday, October 10, 2012

[zeromq-dev] ROUTER-to-REP (C++ ) error on Window

2012-10-11 Thread Hoàng Minh Hải
I run the code (http://zguide.zeromq.org/cpp:rtpapa) on Window (ZeroMQ version 3.2.0) and get a error (errno = EFSM and comment If we are in middle of sending a reply, we cannot receive next request.). Help me fix this! // http://zguide.zeromq.org/cpp:rtpapa // Custom routing Router to Papa

Re: [zeromq-dev] ZeroMQ and hot server restarts

2012-10-11 Thread Pieter Hintjens
On Thu, Oct 11, 2012 at 11:29 PM, Merijn Verstraaten mer...@inconsistent.nl wrote: I'm trying to achieve the same effect using ZeroMQ, but I'm not sure whether this is actually possible. As far as I can tell from the manual pages closing a socket will cause messages that are in-transit to be

Re: [zeromq-dev] ROUTER-to-REP (C++ ) error on Window

2012-10-11 Thread Pieter Hintjens
Hi, Can you please try the C versions? I'm not sure the C++ example code is correct any longer. -Pieter On Fri, Oct 12, 2012 at 10:40 AM, Hoàng Minh Hải haihm1...@gmail.com wrote: I run the code (http://zguide.zeromq.org/cpp:rtpapa) on Window (ZeroMQ version 3.2.0) and get a error (errno =