Have you looked into Dagger.jl at all? In terms of automatic Distributed + multithreading, that’s baked in to Dagger.@spawn
- it’ll use any thread on any worker to run your task.
I’m not sure what you mean by “play/pause”, but if you can elaborate, maybe it’s something I can provide a solution for?
Additionally, in terms of streaming support, I have a branch that implements streaming support, which should automatically work across Distributed processes and multiple threads. It needs more work to be merge-ready, but the idea is solid and will probably get merged in the next 1-2 months. If this seems appealing to you, let me know and I can prioritize finishing it
For one thing, this isn’t thread-safe. For another, it doesn’t work across multiple processes, since bla
only exists on one process. Dagger’s streaming branch support early termination of streaming tasks from within the task or from the outside, so maybe it’s worth taking a look to see if this would work for you.