Cyclium.Migrations.V20 (Cyclium v0.1.10)

Copy Markdown View Source

V20: Add subject_value column to cyclium_workflow_instances.

Backs the cross-node dedup gate in Cyclium.WorkflowEngine. The engine extracts the value of the workflow's declared subject_key from each triggering payload and stamps it on the instance. Workflows without a subject_key, and rows that predate this migration, get the sentinel string "_" so the column is NOT NULL and queryable.

Pairs with a Cyclium.WorkClaims claim keyed on "workflow:<stack>:<workflow_id>:<subject_value>" to prevent two nodes in the same stack from creating duplicate instances for the same triggering event.

Summary

Functions

down()

up()