From 4cc6fd7a42f580903ee1b85afb5864700c6597f1 Mon Sep 17 00:00:00 2001 From: Jakub Zych Date: Wed, 30 Sep 2026 14:57:33 +0200 Subject: [PATCH] docs(11-07): record plan 11-07 progress, decisions and requirements --- .planning/REQUIREMENTS.md | 28 ++++++++++++++-------------- .planning/ROADMAP.md | 6 +++--- .planning/STATE.md | 21 +++++++++++++-------- 3 files changed, 30 insertions(+), 25 deletions(-) diff --git a/.planning/REQUIREMENTS.md b/.planning/REQUIREMENTS.md index 7e05932..b230431 100644 --- a/.planning/REQUIREMENTS.md +++ b/.planning/REQUIREMENTS.md @@ -24,9 +24,9 @@ Requirements for v1 (the Płytarium port). Each maps to roadmap phases. "User" b - [x] **CLI-01**: The `summer` binary (cobra) discovers commands registered by plugins and offers rich output (spinner, progress bar, table, prompts) with non-TTY degradation, following the summer-bonfire design - [x] **CLI-02**: Scaffolding commands generate a plugin, model, migration, command, job and admin controller with stubs that compile - [x] **CLI-03**: Migration commands run up, status, and roll back the last migration of a named plugin -- [ ] **CLI-04**: Plugins register recurring commands (daily or interval) that a scheduler runs in-process or via `summer schedule:run` +- [x] **CLI-04**: Plugins register recurring commands (daily or interval) that a scheduler runs in-process or via `summer schedule:run` - [ ] **CLI-05**: Płytarium commands are ported: oauth-client (create, list without reprinting secrets, add redirect URIs, set scope ceiling), prune-notifications, reindex with drop-old-index flag -- [ ] **CLI-06**: Queue worker runs in-process or via `summer queue:work` +- [x] **CLI-06**: Queue worker runs in-process or via `summer queue:work` ### Internationalization and mail (I18N) @@ -85,19 +85,19 @@ Requirements for v1 (the Płytarium port). Each maps to roadmap phases. "User" b ### Background jobs (JOBS) -- [ ] **JOBS-01**: River runs on the shared *sql.DB with riverdatabasesql for transactional enqueue and riverpgxv5 for LISTEN/NOTIFY; job outcomes (complete, fail, skip) are recorded and queryable through a job manager service +- [x] **JOBS-01**: River runs on the shared *sql.DB with riverdatabasesql for transactional enqueue and riverpgxv5 for LISTEN/NOTIFY; job outcomes (complete, fail, skip) are recorded and queryable through a job manager service - [ ] **JOBS-02**: CSV import write job and Discogs match job (240 s timeout) are ported; the match job re-enqueues itself with a delay on a Discogs rate-limit error instead of failing the batch - [ ] **JOBS-03**: Wishlist digest coalesces notifications in a 30-minute window and deletes its queue row on completion ### Realtime (RT) -- [ ] **RT-01**: The websockets plugin publishes to the existing Centrifugo server (gocent) and issues connection and subscription JWTs with the same secret and claims, served at GET /api/realtime/token. *Note (D-12, D-16): the Centrifugo client is a hand-rolled `net/http` client in the framework package `lighthouse/centrifugo` rather than the originally named gocent library, and the publisher lives in that framework package rather than an app websockets plugin.* -- [ ] **RT-02**: A channel-namespace authorizer registry lets plugins register authorizers (collection, wishlist); the server re-validates on every subscribe and channel names never expose raw ids -- [ ] **RT-03**: A broadcastable model interface emits live patches with bulk-write suppression, separate from durable notifications +- [x] **RT-01**: The websockets plugin publishes to the existing Centrifugo server (gocent) and issues connection and subscription JWTs with the same secret and claims, served at GET /api/realtime/token. *Note (D-12, D-16): the Centrifugo client is a hand-rolled `net/http` client in the framework package `lighthouse/centrifugo` rather than the originally named gocent library, and the publisher lives in that framework package rather than an app websockets plugin.* +- [x] **RT-02**: A channel-namespace authorizer registry lets plugins register authorizers (collection, wishlist); the server re-validates on every subscribe and channel names never expose raw ids +- [x] **RT-03**: A broadcastable model interface emits live patches with bulk-write suppression, separate from durable notifications ### Search (SRCH) -- [ ] **SRCH-01**: Album documents sync to Typesense scoped by collection_id, behind a settings kill-switch, degrading gracefully when the DB or config is absent +- [x] **SRCH-01**: Album documents sync to Typesense scoped by collection_id, behind a settings kill-switch, degrading gracefully when the DB or config is absent - [ ] **SRCH-02**: The reindex command asserts zero documents with collection_id 0 before and after, and can drop the legacy index ### Integrations (INTG) @@ -167,9 +167,9 @@ Which phases cover which requirements. Updated during roadmap creation. | CLI-01 | Phase 1 | Complete | | CLI-02 | Phase 4 | Complete | | CLI-03 | Phase 5 | Complete | -| CLI-04 | Phase 11 | Pending | +| CLI-04 | Phase 11 | Complete | | CLI-05 | Phase 14 | Pending | -| CLI-06 | Phase 11 | Pending | +| CLI-06 | Phase 11 | Complete | | I18N-01 | Phase 4 | Complete | | I18N-02 | Phase 7 | Complete | | I18N-03 | Phase 4 | Complete | @@ -210,13 +210,13 @@ Which phases cover which requirements. Updated during roadmap creation. | API-07 | Phase 13 | Pending | | API-08 | Phase 14 | Pending | | API-09 | Phase 15 | Pending | -| JOBS-01 | Phase 11 | Pending | +| JOBS-01 | Phase 11 | Complete | | JOBS-02 | Phase 14 | Pending | | JOBS-03 | Phase 14 | Pending | -| RT-01 | Phase 11 | Pending | -| RT-02 | Phase 11 | Pending | -| RT-03 | Phase 11 | Pending | -| SRCH-01 | Phase 11 | Pending | +| RT-01 | Phase 11 | Complete | +| RT-02 | Phase 11 | Complete | +| RT-03 | Phase 11 | Complete | +| SRCH-01 | Phase 11 | Complete | | SRCH-02 | Phase 14 | Pending | | INTG-01 | Phase 14 | Pending | | INTG-02 | Phase 14 | Pending | diff --git a/.planning/ROADMAP.md b/.planning/ROADMAP.md index 4121ee4..3479c1d 100644 --- a/.planning/ROADMAP.md +++ b/.planning/ROADMAP.md @@ -505,7 +505,7 @@ Plans: 4. A channel-namespace authorizer registry re-validates on every subscribe; a broadcastable model interface with bulk-write suppression emits exactly one summary event for a bulk operation. 5. Typesense sync is scoped by `collection_id` behind a settings kill-switch and degrades gracefully without DB/config. -**Plans:** 6/7 plans executed +**Plans:** 7/7 plans executed **Research flag:** yes Plans: @@ -525,7 +525,7 @@ Plans: - [x] 11-04-PLAN.md — Web Push (flare VAPID driver, RFC 8291/8292) and websockets:health, websockets:generate-vapid-keys, websockets:test-push **Wave 5** *(blocked on Wave 4 completion)* -- [ ] 11-07-PLAN.md — Unit tests last: full coverage, failing-when-broken T-11 evidence, check-phase11.sh gate, security review and validation map +- [x] 11-07-PLAN.md — Unit tests last: full coverage, failing-when-broken T-11 evidence, check-phase11.sh gate, security review and validation map ### Phase 11.1: SummerCMS documentation for humans and AI agents (INSERTED) @@ -654,7 +654,7 @@ Phases execute in numeric order: 1 → 2 → 3 → 4 → 5 → 6 → 7 → 8 → | 8. OAuth2.1 authorization server | 10/10 | Complete | 2026-09-23 | | 9. Backend admin authentication and schema pipeline | 12/12 | In Progress| | | 10. Admin Vue SPA | 5/5 | Complete | 2026-09-27 | -| 11. Jobs, realtime and search infrastructure | 6/7 | In Progress| | +| 11. Jobs, realtime and search infrastructure | 7/7 | In Progress| | | 11.1. SummerCMS documentation for humans and AI agents | 0/TBD | Not started | - | | 11.2. Ready to share: summercms.io website and newsletter plugin | 0/TBD | Not started | - | | 12. Płytarium API — Collections and Albums | 0/TBD | Not started | - | diff --git a/.planning/STATE.md b/.planning/STATE.md index 8f78887..46d4085 100644 --- a/.planning/STATE.md +++ b/.planning/STATE.md @@ -3,17 +3,17 @@ gsd_state_version: "1.0" milestone: v1.0 current_phase: 11 current_phase_name: Jobs, realtime and search infrastructure -status: executing -stopped_at: Completed 11-04-PLAN.md -last_updated: "2026-09-30T11:54:39.865Z" +status: verifying +stopped_at: Completed 11-07-PLAN.md +last_updated: "2026-09-30T12:57:19.775Z" last_activity: 2026-09-29 last_activity_desc: Phase 11 execution started -state_head: a0f65cdc09be9ab956103a53c02971d723cdd0d9 +state_head: 45fb00af1a32f9fa48f9fe8cd122da3857091234 progress: total_phases: 19 completed_phases: 9 total_plans: 85 - completed_plans: 84 + completed_plans: 85 milestone_name: milestone --- @@ -30,7 +30,7 @@ See: .planning/PROJECT.md (updated 2026-09-16) Phase: 11 (Jobs, realtime and search infrastructure) — EXECUTING Plan: 7 of 7 -Status: Ready to execute +Status: Phase complete — ready for verification Last activity: 2026-09-29 — Phase 11 execution started Progress: [██████░░░░] 60% @@ -139,6 +139,7 @@ Progress: [██████░░░░] 60% | Phase 11 P05 | 24 min | 2 tasks | 14 files | | Phase 11 P06 | 23 min | 3 tasks | 39 files | | Phase 11 P04 | 17 min | 2 tasks | 19 files | +| Phase 11 P07 | 59min | 3 tasks | 40 files | ## Accumulated Context @@ -380,6 +381,10 @@ Recent decisions affecting current work: - [Phase 11]: flare VAPID driver never follows redirects and sends only to https hosts on push.allowed_hosts (checked before dialing) - [Phase 11]: compass Persist now merges runtime values over the existing overrides.yaml so websockets:generate-vapid-keys --update cannot wipe other persisted overrides - [Phase 11]: websockets:health probes the Centrifugo info API (PHP only read local config); an error body fails the check +- [Phase 11]: Phase 11 removal checks are scripted: check-phase11.sh --removal applies anchor-exact mutations, requires the named test to fail on an assertion and restores the file byte for byte (cmp); kept out of --all because it edits tracked source +- [Phase 11]: Savepoint helpers (beachcomber, lighthouse) roll back when RELEASE fails, because a swallowed read error still aborts the Postgres transaction +- [Phase 11]: lagoon after-commit callbacks always receive a clean statement on the write's connection; side-effect GORM callbacks declare Before(gorm:commit_or_rollback_transaction) +- [Phase 11]: Phase gates accept a pending skip only by exact test name and pending text (TestBroadcastGoldens/created and /updated until Phase 12), in check-phase11.sh and check-phase10.1.sh ### Pending Todos @@ -410,6 +415,6 @@ Items acknowledged and carried forward from previous milestone close: ## Session Continuity -Last session: 2026-09-30T11:54:39.388Z -Stopped at: Completed 11-04-PLAN.md +Last session: 2026-09-30T12:57:09.320Z +Stopped at: Completed 11-07-PLAN.md Resume file: None