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
Akka-style message Scheduler #95
base: main
Are you sure you want to change the base?
Conversation
I believe, that's possibly a typo: Line 43 in 4c4c9a7
Neither of EventletEvent and eventlet.event.Eventlet has event attribute. So, probably, it should be self.wait() or super().wait() .Didn't try to "fix" it, because I'm not sure what exactly it should be. Meanwhile |
Codecov Report
@@ Coverage Diff @@
## develop #95 +/- ##
===========================================
+ Coverage 95.37% 95.88% +0.51%
===========================================
Files 13 14 +1
Lines 562 656 +94
===========================================
+ Hits 536 629 +93
- Misses 26 27 +1
Continue to review full report at Codecov.
|
The code in this PR that calls |
@jodal any plan on having this merged at some point? This is also a much needed feature. There are workarounds but would be nice to have something in Pykka directly. Still, it would be nice to have it playing nicely with proxies also. |
@lostcontrol I believe, this PR is extremely outdated, Pykka 3 is pretty different to the version that I had, when I was working this PR. It would need heavy refactoring. And there is a number of possible improvements, like the one, that @djmattyg007 mentioned. I'd be happy to refactor it, improve it and resolve all the conflicts, but I am not sure whether it makes any sense since there is no reaction from @jodal on any of opened PRs. |
First of all, thanks for Pykka, it's really nice!
There is this issue about auto-scheduling: #53
I needed this functionality for my project as well, because I believe, that an ability to use schedulers to retransmit messages, schedule job executions and so on, is quite a bit part of Akka, so I created it for myself and I hope, it could be useful for Pykka community as well.
Basically, I implemented the simplest versions of
Cancellable
,Scheduler.scheduleOnce
,Scheduler.scheduleWithFixedDelay
andScheduler.scheduleAtFixedRate
from Akka.There are 3 schedulers for 3 different kinds of Actors:
ThreadingScheduler
- based onthreading.Timer
.EventletScheduler
- based oneventlet.spawn_after
.GeventScheduler
- based ongevent.spawn_later
.