On Fri, Jun 29, 2012 at 6:46 AM, cleanfield <[email protected]> wrote: > Dear, > > As the guide said, the workers really were running in parallel, if there are > more than one of them. In my example, the parent process acts as the > ventilator and sink, a number of its child processes act as worker. The fact > is that always only one child work in serial.
This is probably because your workers are processing messages faster than you can PUSH to them, and it appears serial to you. PUSH is asynchronous and messages get queued and dealt out round robin to the workers, who are working in parallel. There is no synchronization mechanism that forces them to run serially. If you push enough messages that the queue starts to load up, you will see your workers running in parallel. Same with the sink, the workers can all PUSH asynchronously in parallel to the sink, which will queue up the results "fairly" for the sink to collect. The only serial parts are the ventilator producing work and the sink collecting it, the workers all run in parallel. -Michel _______________________________________________ zeromq-dev mailing list [email protected] http://lists.zeromq.org/mailman/listinfo/zeromq-dev
