I have the following scenario:
- there is a schedule defined for a workflow with a BUFFER_ONE policy (though no policy seems to achieve what I need)
- sometimes, I need to reset the workflow (one that was triggered from a schedule)
- it seems the schedule ignores that fact though, and even though I can see the workflow (the one I’ve reset) running in a schedule, it would still start a new workflow (when the scheduled time comes) while the restarted one is running, regardless of the policy, kind of like a reset workflow didn’t count when it comes to schedule policy
Is there any way to set this up properly? Or what would you advise is the easiest way to work around it?
What I’m trying to achieve is: I’d like only one schedule-defined workflow to run at a time, while I’d also like to be able to reset those workflows occasionally (I’m resetting from the UI).
PS Ideally, I’d like to work it the other way around as well, e.g. if I reset a workflow while a different workflow in a schedule is already running, I’d like the reset to fail or be a no-op. This is less of a concern though, I almost never reset any other workflow than the most recent one.
PS2 Am I crazy to want this and to wonder why it doesn’t work like this by default? I’m just wondering if I’m perhaps missing some core Temporal semantics or perhaps trying to use it in a non-intended way.