Give each pending assignment its own condition, and keep a raised row until it clears
mesh/merge-gate pass: builds build-agent, mesh-controller, route-proxy → ace, g14, novox, shanks; no bus step; every machine composes with the change as it…
mesh/repo-check pass: its merge-check.sh passed
mesh/delivery superseded: a newer delivery to the same trunk took over its walk
mesh/delivery-group group fix/assign-says-why-a-module-is-not-there delivered: every member is delivered
mesh/merge-gate pass: builds build-agent, mesh-controller, route-proxy → ace, g14, novox, shanks; no bus step; every machine composes with the change as it…
mesh/repo-check pass: its merge-check.sh passed
mesh/delivery superseded: a newer delivery to the same trunk took over its walk
mesh/delivery-group group fix/assign-says-why-a-module-is-not-there delivered: every member is delivered
Second review of #150: one key per machine and module let a newer failure be cleared in the tick that raised it, pruning could orphan an open condition, and a build no longer waited for read as never asked although it may still run.
This commit is contained in:
@@ -8,8 +8,10 @@
|
||||
|
||||
-- Every build the controller asked for: a merge's new module, a plan's tier, a person's `build`, an `assign`
|
||||
-- with build. Kept once the ask is made, never before. Its outcome is the `build` row of the same id;
|
||||
-- an ask without one is still running, or was lost. not_asked is why the ask could not be made or waited
|
||||
-- for; for a merge that could not ask, the id is the controller's and no build's.
|
||||
-- an ask without one is still running, or was lost. not_asked is why the ask could not be handed over; for a
|
||||
-- merge that could not ask, the id is the controller's and no build's. outcome_unknown is why an asker that
|
||||
-- handed it over stopped waiting: the build may still run, and is read as in flight until its outcome or
|
||||
-- its bound.
|
||||
create table build_request (
|
||||
id text primary key,
|
||||
repository text not null,
|
||||
@@ -19,6 +21,7 @@ create table build_request (
|
||||
commit_hash text not null default '',
|
||||
asked_for text not null default '',
|
||||
not_asked text,
|
||||
outcome_unknown text,
|
||||
asked_at timestamptz not null default now()
|
||||
);
|
||||
create index build_request_asked_at on build_request (asked_at);
|
||||
@@ -28,7 +31,7 @@ create index build_request_asked_at on build_request (asked_at);
|
||||
-- assignment was refused then), expired (the build failed, was not registered, or said nothing within its
|
||||
-- bound) or withdrawn (`unassign`). raised_at is when an expiry or refusal was raised as a condition,
|
||||
-- acknowledged_at when a person took it back with `unassign`, cleared_at when its condition was cleared.
|
||||
-- Gone with its machine. Ended rows are deleted after 30 days.
|
||||
-- Gone with its machine. Ended rows are deleted after 30 days, once any condition raised for them is cleared.
|
||||
create table pending_assignment (
|
||||
id bigserial primary key,
|
||||
node uuid not null references node (id) on delete cascade,
|
||||
|
||||
Reference in New Issue
Block a user