Builds stable identities for scheduled workflow activations.
Cron delivery has to survive worker retries, duplicate job delivery, and code deploys between the time a scheduler queues an activation and the time Squidie receives it. This module keeps the scheduler-supplied or derived signal identity independent from the current workflow definition so an already persisted scheduled run can still be found after workflow code drifts.
Summary
Functions
Derives the deterministic run id used to fence one scheduled activation.
Returns the scheduler signal id from the payload or derives one from a window.
Functions
@spec run_id(String.t(), String.t(), String.t()) :: {:ok, Ecto.UUID.t()} | {:error, {:invalid_schedule_identity, term()}}
Derives the deterministic run id used to fence one scheduled activation.
The inputs are serialized workflow and trigger names plus a stable signal id.
Returns the scheduler signal id from the payload or derives one from a window.