The transaction catalogue in docs/design/data-model.md:399-411 introduces itself as "Each row below is one database transaction: either all of its effects happen, or none do", then lists join, direct send, broadcast, receive, task create, task start, task submit, task approve, task requeue, prune, and launch-teardown reap.
Two Task transactions are missing:
task abandon (src/store/tasks.ts:641-697) — CAS the Task to revision +1, set status = 'abandoned' and abandoned_at, clear lease_owner_id/lease_expires_at/review_summary and the worktree_path/worktree_branch/worktree_base_ref trio, append the abandoned Task Event carrying the reason, and notify creator, assignee, and reviewer (the assignee's notification being the clear_safe Sign-off, ADR-0016).
task land (src/store/tasks.ts:715-751) — clear the worktree trio and send the assignee the clear_safe Sign-off. Worth a row precisely because it is the one entry that breaks the table's pattern: it is not a status transition, status stays completed, it appends no Task Event, and its CAS predicate is worktree_path matching the row just read rather than the revision bump every other Task row uses (src/store/tasks.ts:715-729 docstring). An archived assignee is skipped.
Both are single BEGIN IMMEDIATE transactions like their neighbours, so the table's stated scope covers them.
Impact: the catalogue is the document's enumeration of atomic units, and a reader auditing which operations are all-or-nothing gets an incomplete answer for the two terminal Task operations. The land omission also hides the one place where the CAS predicate is not the revision, which is the detail a reader most needs when reasoning about concurrent task land calls.
Acceptance: docs/design/data-model.md's transaction catalogue has a task abandon row and a task land row, each stating its atomic effects in the table's existing terse style, with land's non-transition nature and its worktree_path CAS predicate visible.
Found while implementing #29, which is scoped to that issue's three passages (prune scope, the 2 -> 3 migration narrative, and abandon/land actor authority in the Tasks invariants) and does not cover this table.
The transaction catalogue in
docs/design/data-model.md:399-411introduces itself as "Each row below is one database transaction: either all of its effects happen, or none do", then lists join, direct send, broadcast, receive,task create,task start,task submit,task approve,task requeue, prune, and launch-teardown reap.Two Task transactions are missing:
task abandon(src/store/tasks.ts:641-697) — CAS the Task to revision +1, setstatus = 'abandoned'andabandoned_at, clearlease_owner_id/lease_expires_at/review_summaryand theworktree_path/worktree_branch/worktree_base_reftrio, append theabandonedTask Event carrying the reason, and notify creator, assignee, and reviewer (the assignee's notification being theclear_safeSign-off, ADR-0016).task land(src/store/tasks.ts:715-751) — clear the worktree trio and send the assignee theclear_safeSign-off. Worth a row precisely because it is the one entry that breaks the table's pattern: it is not a status transition,statusstayscompleted, it appends no Task Event, and its CAS predicate isworktree_pathmatching the row just read rather than the revision bump every other Task row uses (src/store/tasks.ts:715-729docstring). An archived assignee is skipped.Both are single
BEGIN IMMEDIATEtransactions like their neighbours, so the table's stated scope covers them.Impact: the catalogue is the document's enumeration of atomic units, and a reader auditing which operations are all-or-nothing gets an incomplete answer for the two terminal Task operations. The
landomission also hides the one place where the CAS predicate is not the revision, which is the detail a reader most needs when reasoning about concurrenttask landcalls.Acceptance:
docs/design/data-model.md's transaction catalogue has atask abandonrow and atask landrow, each stating its atomic effects in the table's existing terse style, withland's non-transition nature and itsworktree_pathCAS predicate visible.Found while implementing #29, which is scoped to that issue's three passages (prune scope, the
2 -> 3migration narrative, and abandon/land actor authority in the Tasks invariants) and does not cover this table.