tasks: log the adapter's ready state at startup (Q14 F9) #1552

Open
opened 2026-10-10 17:11:04 +00:00 by jarvis · 1 comment
Contributor

The Q14 plan rev7 review (rev-sol-01, finding F9) failed the plan's tracker check. scripts/mosaic tasks --business mosaic-stack reads the persisted task_current view and never calls the tracker adapter. A cached row passes even when the adapter refuses.

The adapter keeps a state (starting, ready, refused), but nothing outside the process can see it. A refusal logs tasks <business> startup <code> to stderr, which goes to the journal. A successful start logs nothing, unless the version is untested. mosaic bus status reads only files and /proc.

The fix logs one line when a start succeeds: tasks <business> startup ready <version>. It goes after startup() passes every check and the startup reconcile finishes, at the point state becomes ready. A transient retry that later succeeds logs the line too. Then a restart in the Q14 window, forward item 7 or rollback item 5, leaves a positive line in the journal with a timestamp, and the plan can require it.

The unit runs scripts/mosaic from the checkout, so the window's own restart loads the change. No separate deploy is needed.

Scope: packages/tasks/src/adapter.mjs (one line), its tests and packages/tasks/README.md. Nothing under packages/bus or packages/cli changes. Brief: docs/plans/2026-10-10_q14-adapter-ready-line.md.

The Q14 plan rev7 review (rev-sol-01, finding F9) failed the plan's tracker check. `scripts/mosaic tasks --business mosaic-stack` reads the persisted `task_current` view and never calls the tracker adapter. A cached row passes even when the adapter refuses. The adapter keeps a `state` (`starting`, `ready`, `refused`), but nothing outside the process can see it. A refusal logs `tasks <business> startup <code>` to stderr, which goes to the journal. A successful start logs nothing, unless the version is untested. `mosaic bus status` reads only files and /proc. The fix logs one line when a start succeeds: `tasks <business> startup ready <version>`. It goes after `startup()` passes every check and the startup reconcile finishes, at the point `state` becomes `ready`. A transient retry that later succeeds logs the line too. Then a restart in the Q14 window, forward item 7 or rollback item 5, leaves a positive line in the journal with a timestamp, and the plan can require it. The unit runs `scripts/mosaic` from the checkout, so the window's own restart loads the change. No separate deploy is needed. Scope: `packages/tasks/src/adapter.mjs` (one line), its tests and `packages/tasks/README.md`. Nothing under `packages/bus` or `packages/cli` changes. Brief: `docs/plans/2026-10-10_q14-adapter-ready-line.md`.
Author
Contributor

Deferred until the Q14 hold ends (lead decision 82, c9a25a47). Q14 plan rev8's gate V (brain 6743ec95c, sha f4003b78) answers F9 from the Vikunja pod request log, so this change isn't a window prerequisite. packages/tasks stays frozen until ops-01 reports the hold ended. Brief: docs/plans/2026-10-10_q14-adapter-ready-line.md.

Deferred until the Q14 hold ends (lead decision 82, c9a25a47). Q14 plan rev8's gate V (brain 6743ec95c, sha f4003b78) answers F9 from the Vikunja pod request log, so this change isn't a window prerequisite. `packages/tasks` stays frozen until ops-01 reports the hold ended. Brief: `docs/plans/2026-10-10_q14-adapter-ready-line.md`.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: mosaicstack/stack#1552