github cloudflare/workers-sdk @cloudflare/workflows-shared@0.11.0

Minor Changes

  • #13983 9803586 Thanks @vaishnav-mk! - Add rollback support for local Workflows development

    Workflow steps can now register a compensation callback with trailing rollback options: step.do(name, fn, { rollback }) and step.do(name, config, fn, { rollback, rollbackConfig }). When the workflow fails, the local engine runs every registered rollback in reverse step-start order (LIFO), giving steps the opportunity to undo their side effects.

    Each rollback executes through an internal rollback-scoped Context.do, so it inherits the existing retry / timeout / attempt-tracking machinery. rollbackConfig lets users override the per-rollback config.

    Note: the public rollback option type lands with workerd's workflows_step_rollback compat flag. Until that ships, the trailing rollback options only flow through when called through the StepPromise wrapper from a worker that has the flag enabled.

Don't miss a new workers-sdk release

NewReleases is sending notifications on new releases.