Skip to content
Discussion options

You must be logged in to vote

I guess this is basically a question on "fast data exchange between multiple processes", because the receiver side could always be an extension using PyO3 that does what whatever works best to speak with the producer process.

As for the communication mechanism, I guess you could use either Unix domain sockets or shared memory. Shared memory has the potential to be much faster, but you will probably need to write more code to coordinate the data exchange. Sockets are most likely much simpler to get started with but will eventually be limited by the system call and data copying overhead.

A ready-to-use solution might be Servo's ipc-channel which uses bincode for serialization.

Alternatively…

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@sun-rs
Comment options

Answer selected by sun-rs
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
2 participants