| Store | Cart

Re: [Tutor] When to use multiprocessing Managers?

From: David Palao <dpal...@gmail.com>
Wed, 26 Feb 2014 15:19:22 +0100
2014-02-25 11:52 GMT+01:00 James Chapman <jam...@uplinkzero.com>:
> Hello tutors>> I'm curious about managers and when to use them.> For example, I see they offer a Queue() for sharing a Q between> processes, but if I create a Q in the parent process and pass it down> to child processes, then they can put messages into that Q just fine,> and I presume the same thing for other objects available under the> managers package.>> So unless the other process is on a different machine, is there a> reason to use a manager?>> Does anyone have any use case examples or snippets I could look at even?>> Thanks in advance> James> _______________________________________________> Tutor maillist  -  Tut...@python.org> To unsubscribe or change subscription options:> https://mail.python.org/mailman/listinfo/tutor

Hello,
I asked myself the same question when I started using multiprocessing
time ago. So I was very happy when I saw the question by James.

From my limited knowledge, I would say that a Manager can be useful
when processes are distributed across different hosts, or if the
exchange of information between processes is more complex than just a
couple of synchronization primitives.

Best
_______________________________________________
Tutor maillist  -  Tut...@python.org
To unsubscribe or change subscription options:
https://mail.python.org/mailman/listinfo/tutor

Recent Messages in this Thread
James Chapman Feb 25, 2014 10:52 am
Steven DAprano Feb 25, 2014 10:45 pm
Danny Yoo Feb 25, 2014 10:55 pm
Steven DAprano Feb 25, 2014 11:05 pm
David Palao Feb 26, 2014 02:19 pm
James Chapman Feb 28, 2014 11:31 am
eryksun Mar 01, 2014 04:48 pm
James Chapman Mar 03, 2014 11:45 am
eryksun Mar 03, 2014 03:40 pm
Messages in this thread