Skip to content

Commit d4002e1

Browse files
committed
docs: close coderabbit chunk 011 and refresh backlog
1 parent 5f0a9ea commit d4002e1

File tree

7 files changed

+492
-180
lines changed

7 files changed

+492
-180
lines changed

AGENTS.md

Lines changed: 116 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -8,35 +8,34 @@
88

99
<!-- Table of Contents -->
1010
# Table of Contents
11-
1. [[AGENTS# AGENTS|AGENTS]]
12-
1. [[AGENTS## Important Information|Important Information]]
13-
1. [[AGENTS### Sections You Must Actively Maintain|Sections You Must Actively Maintain]]
14-
2. [[AGENTS### Job Queue|Job Queue]]
15-
3. [[AGENTS### TUI App|TUI App]]
16-
1. [[AGENTS#### TUI stack and structure|TUI stack and structure]]
17-
2. [[AGENTS#### Overlays and input behavior|Overlays and input behavior]]
18-
3. [[AGENTS#### Current tabs|Current tabs]]
19-
4. [[AGENTS#### Keybindings (important)|Keybindings (important)]]
20-
5. [[AGENTS#### Redis/admin plumbing|Redis/admin plumbing]]
21-
6. [[AGENTS#### Config + run|Config + run]]
22-
7. [[AGENTS#### Observability|Observability]]
23-
1. [[AGENTS##### Guardrails|Guardrails]]
24-
4. [[AGENTS### Project Status|Project Status]]
25-
5. [[AGENTS### Notes|Notes]]
26-
2. [[AGENTS## Working Tasklist|Working Tasklist]]
27-
1. [[AGENTS### Prioritized Backlog|Prioritized Backlog]]
28-
2. [[AGENTS### Finished Log|Finished Log]]
29-
3. [[AGENTS## TUI Tasks|TUI Tasks]]
30-
1. [[AGENTS### TUI Task Chains|TUI Task Chains]]
31-
2. [[AGENTS### TUI Parallelization & Priorities|TUI Parallelization & Priorities]]
32-
4. [[AGENTS## Daily Activity Logs|Daily Activity Logs]]
33-
1. [[AGENTS### 2025-09-13–Rewrote `AGENTS.md`|2025-09-13–Rewrote `AGENTS.md`]]
34-
1. [[AGENTS#### ##### 06:39 – Starting `AGENTS.md` Enhancements|##### 06:39 – Starting `AGENTS.md` Enhancements]]
35-
1. [[AGENTS##### 06:39 – Starting `AGENTS.md` Enhancements|06:39 – Starting `AGENTS.md` Enhancements]]
36-
5. [[AGENTS## APPENDIX B: WILD IDEAS — HAVE A BRAINSTORM|APPENDIX B: WILD IDEAS — HAVE A BRAINSTORM]]
37-
1. [[AGENTS### Codex's Top Picks|Codex's Top Picks]]
38-
6. [[AGENTS## Appendix C: Codex Ideas in Detail|Appendix C: Codex Ideas in Detail]]
39-
11+
1. [AGENTS](#agents)
12+
1. [Important Information](#important-information)
13+
1. [Sections You Must Actively Maintain](#sections-you-must-actively-maintain)
14+
2. [Job Queue](#job-queue)
15+
3. [TUI App](#tui-app)
16+
1. [TUI stack and structure](#tui-stack-and-structure)
17+
2. [Overlays and input behavior](#overlays-and-input-behavior)
18+
3. [Current tabs](#current-tabs)
19+
4. [Keybindings (important)](#keybindings-important)
20+
5. [Redis/admin plumbing](#redisadmin-plumbing)
21+
6. [Config + run](#config-run)
22+
7. [Observability](#observability)
23+
1. [Guardrails](#guardrails)
24+
4. [Project Status](#project-status)
25+
5. [Notes](#notes)
26+
2. [Working Tasklist](#working-tasklist)
27+
1. [Prioritized Backlog](#prioritized-backlog)
28+
2. [Finished Log](#finished-log)
29+
3. [TUI Tasks](#tui-tasks)
30+
1. [TUI Task Chains](#tui-task-chains)
31+
2. [TUI Parallelization & Priorities](#tui-parallelization-priorities)
32+
4. [Daily Activity Logs](#daily-activity-logs)
33+
1. [2025-09-13–Rewrote `AGENTS.md`](#2025-09-13-rewrote-agentsmd)
34+
1. [##### 06:39 – Starting `AGENTS.md` Enhancements](#0639-starting-agentsmd-enhancements)
35+
1. [06:39 – Starting `AGENTS.md` Enhancements](#0639-starting-agentsmd-enhancements)
36+
5. [APPENDIX B: WILD IDEAS — HAVE A BRAINSTORM](#appendix-b-wild-ideas-have-a-brainstorm)
37+
1. [Codex's Top Picks](#codexs-top-picks)
38+
6. [Appendix C: Codex Ideas in Detail](#appendix-c-codex-ideas-in-detail)
4039
<!-- End of TOC -->
4140

4241
---
@@ -144,6 +143,12 @@ Pre-commit hook
144143
- Enable hooks once per clone: `make hooks` (sets `core.hooksPath=.githooks`).
145144
- Reminder: Whenever you touch `AGENTS.md`, also ensure the features ledger is current (the hook will do this, but run the script manually if needed).
146145

146+
#### Updating Backlog & Features Ledger
147+
1. Edit the `Prioritized Backlog` section here in `AGENTS.md` with the new item status/notes.
148+
2. Mirror the change in `docs/features-ledger.md` (same feature row or add a new one) so both artifacts stay aligned.
149+
3. Run `python3 scripts/update_progress.py` to refresh the progress bars in `docs/features-ledger.md` and `README.md`.
150+
4. Review the script output, then stage/commit the updated files together with your backlog changes.
151+
147152
CI auto-update
148153
- On merges to `main`, a GitHub Actions workflow (`.github/workflows/update-progress.yml`) runs the progress updater and commits any changes to the ledger/README automatically.
149154
- This provides a consistent source of truth even if local hooks are bypassed.
@@ -175,12 +180,19 @@ Use this checklist to track work. Keep it prioritized, update statuses, and refe
175180
- [ ] Admin: Requeue-from-DLQ command with count/range support (exposed to TUI)
176181
- [ ] Admin: Workers-list admin call (IDs, last heartbeat, active item) for Workers tab
177182
- [ ] Metrics: Optional TUI runtime metrics (ticks, RPC latency) for debugging
183+
- [ ] Admin: Rename ExactlyOnce handler/tests to AtLeastOnce and implement missing AtLeastOnce admin API endpoints
178184
- [x] Docs: Add TUI design README with SVG mockups
179185
- [ ] Docs: Update README TUI section with tabs, screenshots, and new keybindings
180186
- [ ] Release: Add changelog entries for TUI tabbed layout and overlays
181187
- [x] Observability: Publish Anomaly Radar OpenAPI spec + client CI automation
182188
- [x] Observability: Finalize Anomaly Radar auth/error/pagination contract and document endpoints
183-
- [ ] Observability: Revisit chunk_008 OpenAPI/auth review items once spec + contract land
189+
- [x] Observability: Inject scopes into Anomaly Radar HTTP handlers via Admin API gateway/context plumbing
190+
- [x] Observability: Update dashboards/clients to follow Anomaly Radar pagination cursors and surface `next_cursor`
191+
- [x] Observability: Revisit chunk_008 rejections with enhanced OpenAPI auth/error responses and close out review items
192+
- [ ] Ops: Share port-forward helper across deployment scripts
193+
- [ ] DevOps: Add policy-as-code checks for security contexts and secret mounts
194+
- [ ] Docs: Audit API references to ensure they document the standardized error envelope + request IDs
195+
- [ ] Tooling: Add automated checks that validate handlers emit/log `X-Request-ID`
184196

185197
### Finished Log
186198
- [x] Rewrite `AGENTS.md` **2025-09-13 07:18** [Link to PR #123](https://github.com/flyingrobots/go-redis-work-queue/pull/123)
@@ -686,6 +698,80 @@ Please keep this document up-to-date with records of what you've worked on as yo
686698
> Follow-ups
687699
> - Run `go test ./...` once the existing suite failures (forecasting, exactly-once outbox, etc.) are resolved upstream.
688700
701+
> [!NOTE]
702+
> ### 2025-09-17 – Anomaly Radar Scope Guardrails & Pagination UX
703+
> Scoped the anomaly radar HTTP surface, made cursor pagination first-class, and refreshed docs/specs to match.
704+
>
705+
> Changes
706+
> - Added scope-aware HTTP helpers, cursor utilities, and idempotent start/stop responses under `internal/anomaly-radar-slo-budget/`.
707+
> - Updated handlers/tests to enforce scope checks, default/max pagination, and the standard JSON error envelope; new docs outline auth, error policy, and pagination flow.
708+
> - Published `docs/api/anomaly-radar-openapi.yaml` with CI validation plus contract notes in `docs/design/anomaly-radar-api-contract.md`.
709+
> - Exported a public wrapper at `pkg/anomaly-radar-slo-budget/` and refreshed the docs/OpenAPI spec with scope tables, error envelope notes, and a paginated metrics example.
710+
>
711+
> Important Learnings
712+
> - Centralised error helpers keep CLI/UI clients aligned once scopes are enforced—no divergent envelopes during failures.
713+
> - Treat cursors as opaque tokens in tests to avoid brittle assumptions; golden fixtures now flex with redis-backed pagination.
714+
> - Writing the OpenAPI spec early flushes review gaps (auth scopes, error schema) before client integration work starts.
715+
> - Stabilising the import path via a thin wrapper lets docs and clients converge without exposing internal packages prematurely.
716+
>
717+
> Next Steps
718+
> - Implement SLO budget calculations/visuals so the TUI widget has real data to render.
719+
> - Wire the TUI/Admin API integration to consume the new paginated endpoints and surface scope errors.
720+
> - Expand integration coverage for the gateway scope propagation once end-to-end plumbing completes.
721+
722+
> [!NOTE]
723+
> ### 2025-09-17 – PR#3 Review Chunk 009
724+
> Cleared the next CodeRabbit batch (30/30) and hardened docs + tooling along the way.
725+
>
726+
> Changes
727+
> - DLQ API docs now spell out auth scopes, server-enforced limits, purge-all schema/idempotency, and valid JSON responses (`docs/api/dlq-remediation-ui.md`).
728+
> - Added public wrappers for anomaly radar and chaos harness packages (`pkg/anomaly-radar-slo-budget/`, `pkg/chaos-harness/`) and updated docs accordingly.
729+
> - Improved auxiliary scripts (append_metadata, review task generators) with safer I/O, UTC timestamps, and accurate logging; trimmed slow sleeps from `demos/responsive-tui.tape`.
730+
> - Hardened Redis deployment manifest and Docker image health checks; updated BUGS.md guidance for heartbeats/schedulers/ledgers.
731+
>
732+
> Important Learnings
733+
> - Documentation needs to carry real contracts (auth, rate limits, JSON schemas) so downstream tooling stays in sync.
734+
> - Wrapper packages are a low-friction way to expose internal modules without destabilising the tree.
735+
> - Investing in script hygiene (UTC times, error handling) prevents subtle drift when other automation depends on them.
736+
>
737+
> Follow-ups
738+
> - Chunk 010 (remaining CodeRabbit feedback) still open; expect similar breadth across docs + tooling.
739+
> - Continue chipping away at backlog items once CodeRabbit sequence is complete (ExactlyOnce→AtLeastOnce rename already queued).
740+
741+
> [!NOTE]
742+
> ### 2025-09-17 – CodeRabbit PR#3 chunk_010 sweep
743+
> Closed the final CodeRabbit batch with deployment hardening, documentation polish, and secret handling fixes.
744+
>
745+
> Changes
746+
> - Hardened admin API and RBAC Kubernetes manifests: pod/container security contexts, RuntimeDefault seccomp, disabled SA token mounts, distinct health/readiness probes, and corrected Grafana compose mounts.
747+
> - Shifted the RBAC token service to file-backed secrets plus RS256 keys, updated token-service config/startup validation, and refreshed deployment docs (`deployments/docker/rbac-configs/token-service.yaml`, `deployments/README-RBAC-Deployment.md`).
748+
> - Clarified key docs (release plan freeze policy, purge reason validation, DLQ pipeline guardrails, HTTPS defaults, hit_percent rename) and converted `AGENTS.md` TOC to standard anchors.
749+
> - Completed the chunk_010 worksheet with accepted dispositions and a 100% progress bar (`docs/audits/code-reviews/PR3/e35da518e543d331abf0b57fa939d682d39f5a88.md.chunk_010.md`).
750+
>
751+
> Validation
752+
> - Updated shell scripts (`deploy-staging.sh`, `health-check-rbac.sh`, `setup-monitoring.sh`) to manage port-forward PIDs safely; existing Go test failures remain pre-existing and were not re-run.
753+
>
754+
> Follow-ups
755+
> - Propagate the new port-forward helpers to other deployment scripts.
756+
> - Add policy-as-code checks to enforce secret volume usage and security context drift.
757+
758+
> [!NOTE]
759+
> ### 2025-09-17 – CodeRabbit PR#3 chunk_011 sweep
760+
> Closed the remaining CodeRabbit review items with documentation polish and onboarding fixes.
761+
>
762+
> Changes
763+
> - Standardized DLQ pipeline error envelopes (codes + request IDs), clarified rate-limit headers, and documented cursor pagination.
764+
> - Updated DLQ UI purge-all example to the safe JSON POST form with idempotency and restructured the claude-008 reflection with front matter.
765+
> - Added a `go mod download` preflight step to README so first-time TUI users fetch dependencies before running.
766+
>
767+
> Follow-ups
768+
> - Verify other API docs reference the shared error envelope pattern.
769+
> - Consider adding automated checks for missing `X-Request-ID` logging in new handlers.
770+
>
771+
> Important Learnings
772+
> - Shared error envelope docs prevent API drift—keeping the pattern centralized avoids per-endpoint divergence.
773+
> - Adding dependency preflight steps in README shortens new contributor setup loops and avoids common module errors.
774+
689775
690776
## APPENDIX B: WILD IDEAS — HAVE A BRAINSTORM
691777
> [!NOTE]

README.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -78,6 +78,12 @@ Run worker only
7878

7979
An interactive TUI is available for observing and administering the job queue. It uses `Charmbracelet`’s Bubble Tea stack and renders queue stats, keys, peeks, a simple benchmark, and charts.
8080

81+
Before the first run, download dependencies:
82+
83+
```bash
84+
go mod download
85+
```
86+
8187
Run it:
8288

8389
```

0 commit comments

Comments
 (0)