Connect two daemons in python
Posted
by
Simon
on Stack Overflow
See other posts from Stack Overflow
or by Simon
Published on 2012-06-23T21:12:15Z
Indexed on
2012/06/23
21:16 UTC
Read the original article
Hit count: 231
What is the best way to connect two daemons in Python?
I have daemon A and B. I'd like to receive data generated by B in A's module (maybe bidirectional). Both daemons support plugins, so I'd like to shut communication in plugins. What's the best and cross-platform way to do that?
I know few mechanisms from low-level solutions - shared memory (C/C++), linux pipe, sockets (TCP/UDP), etc. and few high-level - queue (JMS, Rabbit), RPC.
Both daemons should run on the same host, but obviously better approach is to abstract from connection type.
What are typical solutions/libraries in python? I'm looking for an elegant and lightweight solution. I don't need external server, just two processes talking with each other.
What should I use in python to do that?
© Stack Overflow or respective owner