diff --git a/03-DESIGN/01-to-be/08-milestones/sign-in-page-lead-answers.md b/03-DESIGN/01-to-be/08-milestones/sign-in-page-lead-answers.md index a4d17925..9e3f5c4d 100644 --- a/03-DESIGN/01-to-be/08-milestones/sign-in-page-lead-answers.md +++ b/03-DESIGN/01-to-be/08-milestones/sign-in-page-lead-answers.md @@ -58,10 +58,21 @@ R2-4 08-connectivity.md: move one more section that predates the milestone out i R2-5 networkmanager also calls uplink-names again when its bus connection comes back (an event), with one row in the tests. R2-6 Name the reader of the events: nats.nats_stream_messages filtered to mesh.seat.node-uplink.event.*.. R2-7 The bounds of §15 (60 s), §16 (10 s) and §19 (256 kept) stay stated constants. -R2-8 Going back: a seat's definition goes back before its holders (definitions first, then holders), in reverse of the ordering edges. +~~R2-8 Going back: a seat's definition goes back before its holders (definitions first, then holders), in reverse of the ordering edges.~~ *Corrected by R3-2 (2026-11-24): going back is one delivery group of the three seat definitions and their holders together, since the manifest check refuses either without the other.* R2-9 open keeps unencoded only RFC 3986's unreserved characters and : / ? # [ ] @ & = + % ; every other character is percent-encoded; §28's test adds , and ". R2-10 Say what the publish grant covers, as read in mesh-sdk's EmitSeat and the grants part: the holder's own node's subject only, or every node's; if every node's, say so (the events are a record only). R2-11 A kept event keeps its message id when published again, so the bus drops a duplicate. R2-12 The watcher's read (uplink_sign_in) also counts refused publishes, shows the last session start and its outcome, and shows the resolver's refusal of the names as routes answers it. R2-13 The guard writes resolved's refusal to the journal once per change, not every round. R2-14 i3's open writes one journal line per call, opened or refused, with the program. + +## Round 3 + +Lead answers to round 3 (the last) of the reviews by architectural domain of design/0687-sign-in-page at ffb64bc7 (fix-1981@g14, 2026-11-24). + +R3-1 (running-and-testing, health-and-events, seams-and-tools: the sequence). The watcher keeps the next sequence of its message ids in a file `sequence` in the folder of §12, written whole (to a file beside, renamed over), never reset while the folder lives, removed with it; a test in §25: a watcher restarted after its events were published and pending/ emptied makes ids it has not used before, and the bus keeps them. Principle: failure must be loud; work that reports success and did nothing is the worst fault. +R3-2 (security-and-upgrade: going back). R2-8 was wrong: the manifest check refuses a holder without its seat's new verbs and a seat definition without its holders' serves, either order. The milestone goes back as it was delivered: one delivery group of the three seat definitions and their holders together. Correct R2-8 and the part's going-back lines to say this. (The lead's earlier answer, corrected on the reviewer's reading of mesh-sdk `catalogue/seats.go`.) +R3-3 (seams-and-tools: invokes). Add seat:node-resolver.routes to networkmanager's invokes (§13), since uplink_sign_in reads it. +R3-4 (health-and-events notes). The README says the watcher's health is judged only once the tool runner has reached the bus; uplink_sign_in counts the events dropped past the 256 bound. +R3-5 (seams-and-tools note). Add the tool uplink_publish_again, which asks the publish of the kept events now, with a unit test. Principle: every act a module does by itself can be started by a tool. +R3-6 (security-and-upgrade note). The prepare confirms, on each machine that runs networkmanager, that the tool runner runs as the same account as the watcher (the folder is 0700). diff --git a/03-DESIGN/01-to-be/08-milestones/sign-in-page.md b/03-DESIGN/01-to-be/08-milestones/sign-in-page.md index 59131748..98c481f6 100644 --- a/03-DESIGN/01-to-be/08-milestones/sign-in-page.md +++ b/03-DESIGN/01-to-be/08-milestones/sign-in-page.md @@ -48,8 +48,10 @@ events; `networkmanager`'s `uplink-tools` answers those two and watches nothing: `routes`, `route` and `unroute`, served by `systemd-resolved`, whose guard keeps the resolver file and runs ADR 0688's fallback (design 50 resolver-fallback): all stay. `node-display-session` has `reload`, `workspaces` and `windows`, served by `i3`, whose own tool `i3_exec` runs a command line in the session: all stay, and `open` is the narrow verb -beside `i3_exec` that issue 935 asks for. **Going back one version** (U-N7, R2-8), in reverse of the ordering edges, -the holders first and the seat definitions after them: `systemd-resolved` back leaves the names on the link until the +beside `i3_exec` that issue 935 asks for. **Going back one version** (U-N7; R3-2, which corrects R2-8): as the milestone was +delivered, one delivery group of the three seat definitions and their holders together, since the manifest check +refuses a holder without its seat's new verbs and a seat definition without its holders' `serves`, in either order. +Then: `systemd-resolved` back leaves the names on the link until the network manager changes that link's domains, and nothing else; `networkmanager` back removes the watcher's process and its state folder (§12) with the resource, publishes no more and calls nothing; `i3` back drops `open`; nothing else stays behind. @@ -195,6 +197,8 @@ stays behind. message_id, body}`, written whole by the watcher and deleted by the bundle once the bus acknowledged it (§20). - `names.json`, written whole by the bundle: its last `uplink-names` call, `{names, result, at}`, `result` one of `ok`, `no holder` or the failure. + - `sequence`, written whole by the watcher (beside and renamed over): the next sequence of its message ids and + kept files, never reset while the folder lives, removed with it (R3-1), so an id is never used twice. Nothing else reads or writes the folder. 13. **The bundle gives the resolver the check's host name** (ADR 0687 §2; R-N6, H-M3, S-M1, R2-5). At its start, @@ -208,7 +212,8 @@ stays behind. file then lists the mesh's resolvers, through which the check already resolves. A failed call is written to its journal with the reason, makes its health unhealthy (§23) and is asked again at the next such moment or by its tool (§23), never on a timer (the lead's answer of 2026-11-24: events first). Its manifest `invokes` - `seat:mesh-module-assigner.assignments` and `seat:node-resolver.uplink-names`. The prepare reads whether the + `seat:mesh-module-assigner.assignments`, `seat:node-resolver.uplink-names` and `seat:node-resolver.routes`, which + `uplink_sign_in` reads (§23; R3-3). The prepare reads whether the node-engine says `running` for a module it restarted, and writes it in the milestone file. 14. **The watcher watches the network manager's rating as it changes** (ADR 0687 §3; R2-1). It hears the network manager's `PropertiesChanged` signal on the system bus for `Connectivity`, `PrimaryConnection`, @@ -255,7 +260,7 @@ stays behind. any other end shows nothing. 20. **The events are kept by the watcher and published by the bundle, in order** (ADR 0689 §2; H-M5, R2-1, R2-11). The watcher writes each event of §21 into `pending/` (§12) at its change, with `at` the time of the change and a - `message_id` of `..` made once. It keeps at most 256 files, a stated constant (R2-7); past + `message_id` of `..` made once, the sequence taken from `sequence` (§12). It keeps at most 256 files, a stated constant (R2-7); past that it deletes the oldest with a journal line naming it. The bundle publishes them in sequence order on the seat's subject (§1), each with its `message_id` as the bus's message id, so a second publish of one is dropped by the bus as a duplicate, awaiting the stream's acknowledgement, and deletes each file once acknowledged; it does so @@ -285,20 +290,23 @@ stays behind. 23. **Its tools and its health** (H-M1, S-M3, R2-12; ADR 0240), served by the bundle: - `uplink_sign_in` (reads): from the watcher's `state` (§12): whether it is subscribed, the last rating heard and when, the ask open now (network, link, since), the asks opened and ended since its start, the last open with - its outcome and time, the last notification, the last session start with what it did; from the folder: the - events waiting in `pending/` and the publishes refused since the bundle's start; from `names.json`: the last + its outcome and time, the last notification, the last session start with what it did, the events dropped past + the bound of 256 (R3-4); from the folder: the events waiting in `pending/` and the publishes refused since the + bundle's start; from `names.json`: the last `uplink-names` call; and, where a holder of `node-resolver` runs on its node, the resolver's refusal of the names as `/node-resolver.routes` answers it (`uplink_names.refused`). - `uplink_names_again` (acts): calls `uplink-names` now as §13 does. - `uplink_rating_again` (acts): asks the watcher `rating-again` (§12). + - `uplink_publish_again` (acts): publishes the kept events in `pending/` now, as §20 does (R3-5). - `uplink_health` (the health tool of §11): unhealthy while the watcher's socket does not answer, while the watcher is not subscribed, or while the last `uplink-names` call stands failed, naming which; `no holder` is healthy. 24. **Its README** says the two parts and their shared folder, that the watcher opens the page and tells the person on its own machine without the bus, how it finds the session (§16, §17), that it keeps and the bundle publishes the two events from the network manager's own rating, that with the check switched off it neither opens nor keeps, - and that the bundle calls `uplink-names` where a holder of `node-resolver` runs (ADR 0687 §2, §3; ADR 0689). Its - review reads it. + and that the bundle calls `uplink-names` where a holder of `node-resolver` runs (ADR 0687 §2, §3; ADR 0689); and + that the watcher's health is judged only once the tool runner has reached the bus, since its health tool is the + bundle's (R3-4). Its review reads it. 25. **Its tests** (ADR 0687 and ADR 0689, *How it is checked*), unit, with the network manager's D-Bus signals, logind, the user manager, the opener and the notification service stood in, and no bus: PORTAL at a join opens the page and shows one notification; PORTAL at the watcher's start does the same; PORTAL to FULL shows that the @@ -311,14 +319,19 @@ stays behind. events in order with their message ids and deletes each on acknowledgement, keeps a refused one and publishes it at the next moment; `uplink-names` called at the bundle's start, on a changed `check-address`, when the bus connection comes back and on a running holder of `node-resolver`, `no holder` recorded as healthy; the health - tool unhealthy for a watcher not subscribed and for a failed `uplink-names` call; each tool. **One integration + tool unhealthy for a watcher not subscribed and for a failed `uplink-names` call; a watcher restarted after its + events were published and `pending/` emptied makes message ids it has not used before, and the bus keeps them + (R3-1); `uplink_publish_again` publishes what waits (R3-5); each tool. **One integration test** starts `networkmanager` whole, watcher and bundle, with no bus: it sees the page opened by the stood-in opener; then it starts a real bus holding `node-uplink`'s definition and a stand-in holder of `node-resolver`, and sees the kept events published in order with the times of their changes and `uplink-names` called (R-M4, R2-1). 26. **Nothing names a network in it** (ADR 0687 §6): §33 holds for its code, configuration and tests. 27. **Its manifest** declares the process of §11, the directory of §12, the `consumes` and `invokes` of §13, and - keeps its claim of `node-uplink`, its package, its configuration file and its service as today. + keeps its claim of `node-uplink`, its package, its configuration file and its service as today. The prepare + confirms, on each machine that runs `networkmanager`, that the tool runner runs as the same account as the + watcher, `${machine:account}`, since the folder of §12 is that account's alone (mode 0700), and writes it in the + milestone file (R3-6). 28. **`systemd-networkd`'s README says it announces neither event and opens nothing** (ADR 0687 §1): systemd-networkd cannot tell a sign-in page. Its review reads it.