Files
archie/internal/platform/pg/migrations/00017_approvals_actions.sql
T
sam a101b64703 fix(runs): a cancelled run's trail records who stopped it (#2100)
Cancelling a run moved it and the runs it called to cancelled and wrote nothing
to either trail, so a stopped run could not say when it stopped or who asked.

The stop now returns the runs it stopped and records one cancel entry on each,
in the same transaction, naming the principal that asked. The entry is a step
named cancel with the caller's identity, so the run detail shows it with the
rest of the trail.
2026-11-27 19:24:19 +11:00

10 lines
406 B
SQL

-- +goose Up
-- One approval can cover a sequence of actions, approved in one act. The
-- request's own action columns describe the first action; actions lists all of
-- them in the order they run, each with the decision and digest that bind its
-- approval.
ALTER TABLE approvals.requests ADD COLUMN actions jsonb NOT NULL DEFAULT '[]';
-- +goose Down
ALTER TABLE approvals.requests DROP COLUMN actions;