Skip to content

net (11/12): Unify controller reads and expire viewer diagnostics - #788

Merged
Patrick W. Healy (phealy) merged 2 commits into
phealy/lightweight-status-cli-transportfrom
phealy/lightweight-status-thin-cluster
Sep 23, 2026
Merged

Patrick W. Healy (phealy) merged 2 commits into
phealy/lightweight-status-cli-transportfrom
phealy/lightweight-status-thin-cluster

Conversation

@phealy

@phealy Patrick W. Healy (phealy) commented Sep 16, 2026 •

Copy link
Copy Markdown
Contributor

Consolidated lightweight-status stack: 11/12

Based on #767. This existing draft PR is reused for the user-approved consolidation, replacing unnecessarily fragmented PRs rather than creating another set.

Scope

Cluster overview retention and summary-only pulls, unified legacy per-node reads, expiring viewer detail writes and lifecycle observers. Obsolete per-node broadcast subscription calls are removed with their owner; routine legacy full broadcasts retire in this layer so clients receive summary snapshots and deltas only.

Original work represented: #788, #789, #791. Cross-cutting originals may also be represented by adjacent functional layers.

Size

+1,202 / -283 = 1,485 non-generated changed lines, measured against the immediate parent. Generated changes: 0 lines, excluded from the approved 2,000-line ceiling. About 1,000 is a guideline, not a requirement to split coherent functionality.

Validation

  • Scoped make fmt with serialized shared linter lock (tmp/layer11-fmt.log)
  • go test ./cmd/unbounded-net-controller (tmp/layer11-tests.log)
  • go test ./cmd/unbounded-net-controller ./cmd/kubectl-unbounded/app/net after each CLI restack (tmp/layer11-cli-fix-tests.log, tmp/layer11-info-fix-tests.log)
  • Controller and CLI tests after final decoder restack (tmp/layer11-allocation-fix-tests.log)

The final stack preserves the validated implementation and all three CLI corrections exactly; its only additional tracked difference is the requested AGENTS.md approval/size policy. No PR is merged into main.

Approved 12-PR draft stack

Base: #745. Each PR targets its preceding layer.

#746 -> #812 -> #760 -> #762 -> #755 -> #757 -> #774 -> #764 -> #766 -> #767 -> #788 -> #748

This was referenced Sep 16, 2026

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot review overview

🟡 Changes recommended

Unresolved compatibility, freshness, validation, and lifecycle issues remain.

Get a fresh assessment by requesting another Copilot review.

Review effort: Lite
Findings: 1 High severity

Open (1)
What changed in this PR

Unifies controller status reads around summary caching and a shared expiring detail lifecycle.

Changes:

  • Adds summary-only cluster pulls and overview retention.
  • Routes legacy and WebSocket detail requests through the shared request manager.
  • Adds lifecycle, expiry, cancellation, and retention coverage.
File Description
cmd/​unbounded-net-controller/​ws_summary_test.go Updates WebSocket subscription tests.
cmd/​unbounded-net-controller/​websocket.go Removes automatic detail broadcasts and updates client lifecycle handling.
cmd/​unbounded-net-controller/​websocket_details.go Adds TTL-aware detail watching; lifecycle updates and queued expiry handling need changes (moderate).
cmd/​unbounded-net-controller/​websocket_details_test.go Tests detail expiry and observer cleanup.
cmd/​unbounded-net-controller/​server.go Enables thin storage and summary responses.
cmd/​unbounded-net-controller/​server_routes_test.go Updates legacy route tests.
cmd/​unbounded-net-controller/​node_status.go Adds thin-cache lifecycle and generic fetching.
cmd/​unbounded-net-controller/​node_overview.go Fetches and validates summaries; omitted diagnostic fields need presence validation (moderate).
cmd/​unbounded-net-controller/​node_legacy.go Binds detail lifecycle and startup safeguards.
cmd/​unbounded-net-controller/​node_legacy_test.go Tests cache lifecycle behavior.
cmd/​unbounded-net-controller/​detail_wait.go Adds metadata-based waiting for legacy reads.
cmd/​unbounded-net-controller/​detail_wait_test.go Tests shared legacy requests.
cmd/​unbounded-net-controller/​detail_requests.go Adds update notifications and expiry handling.
cmd/​unbounded-net-controller/​detail_legacy.go Invalidates requests on node replacement.
cmd/​unbounded-net-controller/​detail_legacy_test.go Tests replacement cancellation.
cmd/​unbounded-net-controller/​detail_api.go Routes legacy reads through the detail manager; cached pushes need refreshed receipt timestamps (moderate).
cmd/​unbounded-net-controller/​cluster_status.go Uses summary-only background pulls.
cmd/​unbounded-net-controller/​cluster_status_cache.go Retains overview metadata; normalization currently removes details needed by legacy clients (critical).
cmd/​unbounded-net-controller/​cluster_retention_test.go Tests retention and summary pulls.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread cmd/unbounded-net-controller/cluster_status_cache.go
@phealy
Patrick W. Healy (phealy) force-pushed the phealy/lightweight-status-thin-cluster branch from a1c10dd to 4c60435 Compare September 22, 2026 17:32
@phealy
Patrick W. Healy (phealy) force-pushed the phealy/lightweight-status-thin-cluster branch from 4c60435 to 9846f53 Compare September 22, 2026 17:58
@phealy
Patrick W. Healy (phealy) force-pushed the phealy/lightweight-status-thin-cluster branch from 9846f53 to d787464 Compare September 22, 2026 18:03
@phealy
Patrick W. Healy (phealy) marked this pull request as ready for review September 22, 2026 18:06
@phealy
Patrick W. Healy (phealy) requested a review from a team September 22, 2026 18:06
@phealy
Patrick W. Healy (phealy) force-pushed the phealy/lightweight-status-thin-cluster branch from d787464 to 03c0bce Compare September 22, 2026 19:06
@cchildress
Cameron Childress (cchildress) force-pushed the phealy/lightweight-status-thin-cluster branch from 03c0bce to b91b317 Compare September 22, 2026 19:39
@phealy
Patrick W. Healy (phealy) force-pushed the phealy/lightweight-status-thin-cluster branch 3 times, most recently from d5380ea to 3f6ce77 Compare September 23, 2026 16:03
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot-Session: d2243398-6c36-4c3d-969e-7ed7bfb5b459
Register every WebSocket client in summary mode and ignore the retired unsubscribe command so thin cluster state is never exposed as a misleading full-detail broadcast.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

Copilot-Session: d2243398-6c36-4c3d-969e-7ed7bfb5b459
@phealy
Patrick W. Healy (phealy) added this pull request to the merge queue Sep 23, 2026
Merged via the queue into main with commit 2e72893 Sep 23, 2026
22 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants