feat: add governed fast work-record sync

Assistant: codex
Assistant-Model: gpt-5.6-sol
Assistant-Session: 01a053ff-1d6f-7fe2-ac1c-a6eb40a42a0c
This commit is contained in:
tegwick 2026-08-30 22:38:54 +02:00
parent 7ea7690dfc
commit 58414404d6
10 changed files with 1280 additions and 32 deletions

View file

@ -0,0 +1,86 @@
---
id: RMGR-WP-0012
type: workplan
title: "Fast work-record mutation and forge projection trigger"
domain: infotech
repo: repo-manager
status: active
owner: codex
topic_slug: infotech
created: "2026-08-30"
updated: "2026-08-30"
related:
- RMGR-WP-0005
- RMGR-WP-0008
- STATE-WP-0083
- STATE-WP-0086
state_hub_workstream_id: "c9690d0f-ed75-56a5-9738-39fe49856e2e"
---
# Fast work-record mutation and forge projection trigger
## Goal
Make ad-hoc, workplan, and task creation and updates deterministic and quick,
then ask the authoritative State Hub to derive one repository projection from
the pushed Forgejo commit. Repository files and the forge remain authoritative;
Repo Manager does not upload a workstation-built replacement projection.
## Canonical identifiers and deterministic registration
```task
id: RMGR-WP-0012-T01
status: done
priority: high
state_hub_task_id: "7d8ecdbd-4350-54e7-8f6c-4692e1e0f3ea"
```
Use the work-record kind registry as the only identifier grammar. Accept
repository-qualified ad-hocs and assign missing deterministic UUIDv5 values
locally without replacing legacy UUIDs or requiring a registrar host.
## Governed ad-hoc and task mutations
```task
id: RMGR-WP-0012-T02
status: done
priority: high
state_hub_task_id: "f6add501-4153-5df5-aacc-ebd444dca00c"
```
Add concurrency-safe, idempotent commands for daily ad-hoc task creation and
general task creation/update while retaining optimistic Git HEAD checks and
explicit push sealing.
## Fast authoritative projection trigger
```task
id: RMGR-WP-0012-T03
status: done
priority: high
state_hub_task_id: "02d155c6-0baa-573a-9055-4aee91dcb246"
```
Add one sync command that validates local records, writes only missing derived
identifiers, verifies the branch is visible on its upstream, verifies the hub
is the railiance01 primary, and requests reconciliation against that exact
forge commit.
## Regression, performance, and operator cutover
```task
id: RMGR-WP-0012-T04
status: progress
priority: high
state_hub_task_id: "723c77ab-c2a3-545f-94d2-174b6f983a67"
```
Cover canonical/ad-hoc grammar, retries, Git preconditions, incorrect hub
identity, exact-commit reconciliation, and concise receipts. Document the fast
path and retain registrar reconciliation only as a legacy migration tool.
Implementation and local verification are complete: the Repo Manager suite is
green, the focused fast-path tests enforce two HTTP requests, and current agent
and repository-standard documentation points at `rmgr sync`. This task remains
in progress until the matching State Hub endpoint is deployed and one live
Forgejo-to-primary receipt establishes the production latency baseline.