-
-
Notifications
You must be signed in to change notification settings - Fork 106
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Is it possible to work with multi-processing? #209
Comments
I haven't looked into multiprocessing in a long time, but Pykka had support for gevent and eventlet as alternatives to threading until recently, so the flexibility to build multiprocessing support is there. I should mention that with threading/gevent/eventlet there was no support for mixing and communicating across the different runtimes. I assume you don't want to run everything as its own process? |
I have a idea of gevent/eventlet but I did have a google search on how it works. I do not worry about IO intensive tasks but compute intensive ones. It will be great if actors in different processes can communicate to workaround Python GIL limitation and improve performance. |
I didn't intend for you to use gevent/eventlet, I just tried to point out that it should be fairly easy to make Pykka use processes instead of threads, just like it previously supported "green threads" instead of threads. However, Pykka has never had support for mixing runtimes, e.g. having a group of actors running as threads in one process communicating with an actor in another process. That would probably require large changes to Pykka's APIs. Thus, the realistic alternatives are to either:
|
Wouldn't disabling the GIL(python/cpython#116338) (I know it is still experimental) solve the issue, that is the actors would be able to run on different cores without any code changes ? |
Actor model is often used to build a MMO server. I just found Pykka easy to use. Is it possible to work with Python mutl-processing without much additional effort to take full advantage of multi-cores?
The text was updated successfully, but these errors were encountered: