As someone familiar with asyncio, I don't understand what this is or what it's for. What's an activity, workflow, or worker? > See the asyncio.sleep in there? That’s no normal local-process sleep; that’s a durable timer backed by Temporal. That's the normal asyncio.sleep. What does backed by Temporal mean? Reading further, it appears that Temporal is replacing the default asyncio event loop. I don't understand why ev…
The thing with event loops in python is that they are not a single, all-governing scheduler (as e.g. in the BEAM). ev loops instead are a mid-layer concept that sits below other infrastructure such as threads and processes. And (perhaps somewhat frustratingly) it is not too uncommon to have multiple ev loops in parallel. See for example the proxy.py project, which offers to run one async loop per process for a speedu…
Temporal Python – A durable, distributed asyncio event loop (2023)
11–20 of 56 posts
Re: Temporal Python – A durable, distributed asyncio event loop (2023)
#12Isn't this just threads but with more surprise gotos?
workflows and activities are called remotely, and you can have an autoscaled worker pool handling these calls.
you can retry any unit easily on failure and specify the non retryable errors. What it requires in exchange is full determinism - the same input should produce the same activities in the same order, as a good starting point.
src: I'm a user since over a year ago.
Re: Temporal Python – A durable, distributed asyncio event loop (2023)
#13Isn't this just threads but with more surprise gotos?
Re: Temporal Python – A durable, distributed asyncio event loop (2023)
#14Relying on external APIs or databases within activities might lead to variability in workflow execution. Also, on handling HTTP errors in activities by raising an "ApplicationError" based on the status code, might simplifies error handling but might need to see how it accounts for more complex scenarios where errors are transient or where a retry could be successful even for some client errors like rate limiting or t…
This is why they are activities. Their results are stored in history, the workflow remains deterministic.
> might need to see how it accounts for more complex scenarios where errors are transient or where a retry could be successful even for some client errors like rate limiting or temporary unavailability etc.
Temporal allows you to specify whether an error is retryable or not.
Re: Temporal Python – A durable, distributed asyncio event loop (2023)
#15Re: Temporal Python – A durable, distributed asyncio event loop (2023)
#16Anyone migrated from celery, with / without regrets?
(disclaimer, I'm the author of the post)
Re: Temporal Python – A durable, distributed asyncio event loop (2023)
#17As someone familiar with asyncio, I don't understand what this is or what it's for. What's an activity, workflow, or worker? > See the asyncio.sleep in there? That’s no normal local-process sleep; that’s a durable timer backed by Temporal. That's the normal asyncio.sleep. What does backed by Temporal mean? Reading further, it appears that Temporal is replacing the default asyncio event loop. I don't understand why ev…
Re: Temporal Python – A durable, distributed asyncio event loop (2023)
#18As someone familiar with asyncio, I don't understand what this is or what it's for. What's an activity, workflow, or worker? > See the asyncio.sleep in there? That’s no normal local-process sleep; that’s a durable timer backed by Temporal. That's the normal asyncio.sleep. What does backed by Temporal mean? Reading further, it appears that Temporal is replacing the default asyncio event loop. I don't understand why ev…
> you only have to get one supergenius to write the hard code to run map and reduce on a global massively parallel array of computers, and all the old code that used to work fine when you just ran a loop still works only it’s a zillion times faster which means it can be used to tackle huge problems in an instant
If you can replace the thing that people use with a distributed version, then that can make it easy to write distributed code.
[0] https://www.joelonsoftware.com/2006/08/01/can-your-programmi...
Re: Temporal Python – A durable, distributed asyncio event loop (2023)
#19Earlier quoted context omitted.
The thing with event loops in python is that they are not a single, all-governing scheduler (as e.g. in the BEAM). ev loops instead are a mid-layer concept that sits below other infrastructure such as threads and processes. And (perhaps somewhat frustratingly) it is not too uncommon to have multiple ev loops in parallel. See for example the proxy.py project, which offers to run one async loop per process for a speedu…
Good design dictates that you start one loop and build the whole program around it, no? The docs for asyncio.run say as much.