Inter-Process comunication

Cameron Laird claird at lairds.com
Sat Nov 8 21:06:10 EST 2003


In article <3fad015a$0$58714$e4fe514c at news.xs4all.nl>,
Irmen de Jong  <irmen at -NOSPAM-REMOVETHIS-xs4all.nl> wrote:
>Zunbeltz Izaola wrote:
>> I want something like to send a signal each time the data is changed
>> to execute DrawPlot(). I'm no proffesional programmer and i don't know
>> wich technique is the best, signals, theread, anothero one ...
>> Any sugestions?
>
>Have a look at Pyro, http://pyro.sourceforge.net
>You could stick your DrawPlot() method in a Pyro object
>and call it -remotely- from the process/thread that
>generated new data to plot.
			.
			.
			.
Maybe.

There are several things that are definite.  Mr. Izaola deserves
applause for his intent to define clean classes that don't mix
GUI handling (for example) with data communication.  I suspect
his use of append() will turn out to be a misstep; Measure should
probably just pass data through without even committing itself to
the sequence data structure he outlined.  Also, while Python does
indeed support a variety of inter-process communication (IPC)
mechanisms well, it's almost certain he's best off with some form
of sockets, and definitely not signals or thread management.

What socket abstraction will best suit him?  I'm not sure; the 
contestants, as I see them, are raw sockets, asyncore, Twisted,
and Pyro.  I think raw sockets are too low level.  asyncore is 
my first choice, but Twisted and Pyro have plenty to recommend
them.  'Anyone have the leisure to supply a working example in
any of these?
-- 

Cameron Laird <claird at phaseit.net>
Business:  http://www.Phaseit.net




More information about the Python-list mailing list