Python to Python communication
Thomas Guettler
guettli at thomas-guettler.de
Mon Oct 11 09:58:44 EDT 2004
Am Mon, 11 Oct 2004 12:40:07 +0000 schrieb Harald Massa:
> Hello,
>
> I have a group of Python programms which I want to teach to "talk to each
> other".
>
> All run on Windows, on the same computer or in the same intranet.
> Security of communication is not an issue (encryption on lower level
> protocols / intra computer communication). Partially these programs are
> using wxPython.
Hi,
Before choosing a framework (pyro, socket or other) you should know
how you want to communicate.
The easiest is "client-server". There is one server and several
clients connect to it.
Peer to peer: There is no central server. All can talk to each other.
The problem is: How to find the other? If there are on one computer
this is easy: Just write files to a directory all processes know.
But if you want to talk to other computers, you need to know their
IP addresses.
For the communication UDP, TCP or HTTP can be used. I would not
use HTTP (XMLRPC or SOAP) if you don't need to. UDP is stateless,
and can be used for broadcasts.
I would use pyro or the socket module.
HTH,
Thomas
More information about the Python-list
mailing list