Repository navigation
feat(fabric-api): Package the Looking Glass rollout as Components - #1123
Merged
Merged
Conversation
4 tasks
4 tasks
privateip
force-pushed
the
feat/lg-backend-packaging
branch
from
October 26, 2026 20:41
908b913 to
637966b
Compare
privateip
force-pushed
the
feat/lg-backend-packaging
branch
from
October 26, 2026 20:49
637966b to
ba5cc3b
Compare
privateip
marked this pull request as ready for review
October 27, 2026 01:55
scotwells
previously approved these changes
Oct 27, 2026
Turning on aggregate probe budgets and the Looking Glass service meant hand-editing the fabric-router and gateway manifests in the order the contract requires, and nothing stopped an overlay from enabling the service before every node charged direct operator probes. Four opt-in Components package that rollout. fabric-api-permits adds --probe-permits to the fabric-router sidecar, mounts the ServiceAccount token into it and grants get on the gateway's Lease alone; fabric-api-require-permits adds --require-probe-permits and the gateway Service address. aggregate-budgets adds --aggregate-budgets to the gateway, and service adds --service-config-map, the looking-glass service identity, the fabric-api-service ConfigMap shipped disabled and a Role that can get that ConfigMap alone. Each fails its build without the Component it needs. The ConfigMap carries Flux's ssa IfNotPresent annotation, so an operator's kubectl stop survives reconciliation. task test:manifests renders each valid composition under tests/manifests and checks that each out-of-order one fails, and a new CI job runs it. configuration.md documents the limit flags with tuning guidance and the contract's failure bounds, and the clock check. operations.md documents the Components and the enabling order, the switch and what happens to running work, diagnosis from the new metrics and alerts, and the upgrade and rollback order. The Looking Glass service design, the fabric-api architecture, deployment and security pages and the alert catalog describe the same. Fixes #1047
privateip
force-pushed
the
feat/lg-backend-packaging
branch
from
October 27, 2026 02:02
ba5cc3b to
6c138d6
Compare
ecv
previously approved these changes
Oct 27, 2026
ecv
left a comment
Contributor
There was a problem hiding this comment.
Approve.
Rendered all five fixtures at 6c138d6 with kustomize v5.8.3: the two valid compositions build, the three invalid ones fail for the intended reason. Components are opt-in and RBAC is narrow.
- RBAC for the switch is supplied and tight:
config/fabric-api/components/service/rbac.yamlis a namespaced Role withgetonconfigmapslimited toresourceNames: [fabric-api-service], bound to thefabric-api-gatewayServiceAccount. That matches the code, which polls throughmgr.GetAPIReader()(uncachedget, no list/watch). - Router permits RBAC is equally narrow:
fabric-api-permits/rbac.yamlgivesfabric-routergeton the single Leasefabric-api-gatewayingalactic-system. No Secrets or ConfigMaps access, no cluster-wide rules. kustomize.toolkit.fluxcd.io/ssa: IfNotPresentonfabric-api-serviceis the correct Flux mechanism: Flux creates the object once, skips server-side apply while it exists, so an operator'skubectledit survives reconciles. It renders onto the ConfigMap as written.- Flip side: Git can never turn the service off or back on once the object exists, and deleting the ConfigMap from Git only prunes it, after which it is recreated as
disabled. The kustomization header explains the "no reconcile re-enables after an emergency stop" half but not that a Git revert is not a way to disable; say so indocs/fabric-api/configuration.md. - Invalid cases fail for the right reasons:
permits-without-sidecarandrequire-without-permitsdie on the no-op patch withno matches for Id ...,service-without-budgetsdies on thetestop (Unable to access invalid index: 1).task test:manifestsinverts the exit status fortests/manifests/invalid/*, so a build that unexpectedly succeeds prints FAIL and exits 1. CI runs it in the newmanifestsjob. - Opt-in confirmed: no kustomization in the repo lists the new Components (the only match in
config/fabric-api/kustomization.yamlis a comment), so merging changes no deployment. - Rollout hazards are documented in the Component headers: permits and require-permits change the DaemonSet pod template and restart FRR on every node, so roll as a routing change.
Follow-ups:
- The invalid-case loop treats any build failure as success, so a typo in a fixture path or a base rename would keep it green. Grep the error text (
no matches for Id/invalid index) inTaskfile.yamltest:manifests. service/deployment-patch.yamltestsargs/1 == --aggregate-budgets, which depends on base args being exactly[gateway]plus the budgets flag; a new base arg at index 1 would make the guard fail wrongly or pass wrongly. Acceptable now, fragile later.- Flip side of the
IfNotPresentannotation deserves a runbook line: the emergency stop iskubectlonly.
scotwells
previously approved these changes
Oct 27, 2026
privateip
dismissed stale reviews from scotwells and ecv
October 27, 2026 12:12
The merge-base changed after approval.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Turning on aggregate probe budgets and the Looking Glass service meant hand-editing manifests in a strict order, and nothing stopped an overlay from enabling the service before every node charged direct operator probes.
Four opt-in Kustomize Components package the rollout, and each fails its build without the one it needs. The service switch ships disabled and survives a Flux reconcile once an operator flips it.
The operator docs cover the switch and running work, the limits and their failure bounds, diagnosis from the new metrics, and upgrade and rollback. Third of three stacked changes, on top of #1122. It waits for #1111 and #1112 and rebases onto them.
Test plan
Fixes #1047