Hi,
We have a use case, where we would like to use a temporal workflow to process completion signals for various other workflows throughout our app. We have some question on whether this is reasonable to do and some implementation details.
Each workflow will send a maximum one signal per run, so there should not be a problem on the sender side relating to the History Limit.
We are wondering how to handle this on the receiver side, as it might receive many signals. For each signal, we kick off an activity. The workflow body itself is essentially empty, as it only waits for signals in a loop.
The open questions are:
- how to handle the history limit and replays in case of crashes. We do not want the workflow to reprocess signals (execute activities) it has already seen
- In case a limit is reached, what’s the best way to handle this or let it terminate, and the new instance will handle the new signals.
For 2 at least, I guess we can keep a variable for signals received, update it and in case it’s more than X start as new. Is this reasonable?
Any guidance would really be appreciated, thanks!