Repository navigation
docs(infra): record D-BLUEGREEN, and correct the kubectl-scale claim it was built around - #607
Merged
Merged
Conversation
…it was built around The blue/green stack shipped without its decision record. This adds it, and revises the two places that still described the old deploy as current state. - `D-BLUEGREEN` in infrastructure-decisions.md. The part worth having on the record is why neither existing Argo rejection answers this question: `D-ARGO` rejects Argo *Workflows* because the DAG is inside the process, and `D-DEPLOY` notes Argo *CD* is out of scope as a question about who applies manifests. Argo **Rollouts** is a third product answering a third question, and "we said no to Argo" is the obvious and wrong way to short-circuit it. What settled it is that a controller's marginal value here is percentage canaries, and those need a traffic provider: `ingress.enabled: false`, so without one its blueGreen strategy swaps a Service selector, which is what forty lines of chart already do. - §14.2's Helm paragraph in infrastructure.md described a deploy that no longer exists — one replica under `Recreate` with an init container migrating between the old pod's deletion and the new pod's boot. One claim this was built around turns out to be false, which is the reason the Makefile is in this diff. `dev-resume` states that helm's three-way merge "sees no manifest diff after a kubectl scale, so it would leave the replica counts at zero". On that basis the deploy's third phase is unsound, because it retires a colour with exactly that `kubectl scale`: the next release renders a manifest identical to the last one, so an unrestored count would leave the target colour at zero — and both `--atomic --wait` and `kubectl rollout status` pass trivially there, since a 0-replica Deployment is vacuously rolled out, so only the preview smoke test would catch it. Measured on kind against helm 3.17 rather than reasoned about: install at 1, `kubectl scale` to 0, `helm upgrade` with the value unchanged, and the live object goes back to 1. That is Helm 3 patching the live object against the rendered manifest rather than against the previous one; the comment captures Helm 2. So the retirement is sound as written, the comment is corrected here, and `dev-resume` keeps `kubectl` for the reason that does hold — a `helm upgrade --wait` would re-run the release's hooks, including the schema migrate, just to put a replica count back. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]>
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.
The blue/green stack shipped without its decision record. This adds it, revises the two places that still described the old deploy as current state, and corrects a false claim the design had been built around.
D-BLUEGREENThe part worth having on the record is why neither existing Argo rejection answers this question.
D-ARGOrejects Argo Workflows because the DAG is inside the process;D-DEPLOYnotes Argo CD is out of scope as a question about who applies manifests. Argo Rollouts is a third product answering a third question, and "we said no to Argo" is the obvious and wrong way to short-circuit it.What settled it: a controller's marginal value here is percentage canaries, and those need a traffic provider.
ingress.enabled: falseand §4.1's edge is unbuilt, so without one, Rollouts' blueGreen strategy swaps a Service selector — which is what the chart already does, in exchange for a CRD, a controller to run and upgrade, and a second owner of the Service object.The entry also records the two reasons it was worth doing before the ALB (the
control_plane_unreachablepath meant a slow deploy could fail a running hour-long task, charged to the launch budget; and the reconciler'sAheadverdict plus E011 had already built the expand half), the refuse-breaking-outright decision, and the deferred ALB weighted-target-group follow-on with the_next/staticresidual risk it addresses.§14.2
It still described a deploy that no longer exists — one replica under
Recreate, with an init container migrating between the old pod's deletion and the new pod's boot.The false claim, which is why the Makefile is in this diff
dev-resume's comment states that helm's three-way merge "sees no manifest diff after a kubectl scale, so it would leave the replica counts at zero".If that held, the deploy's third phase would be unsound, because it retires a colour with exactly that
kubectl scale. The next release renders a manifest identical to the last one, so an unrestored count would leave the target colour at zero — and nothing on the happy path would notice:--atomic --waitandkubectl rollout statusboth pass trivially for a 0-replica Deployment, which is vacuously rolled out. Only the preview smoke test would fail, and it would fail as a connection error rather than as "the colour never scaled up".Measured on kind against helm 3.17 rather than reasoned about:
spec.replicashelm upgrade --install --set replicas=1kubectl scale --replicas=0helm upgrade --set replicas=1(manifest unchanged)That is Helm 3 patching the live object against the rendered manifest rather than against the previous one; the comment captures Helm 2 behaviour. So the retirement is sound as written. The comment is corrected here, and
dev-resumekeepskubectlfor the reason that does hold — ahelm upgrade --waitwould re-run the release's hooks, including the schema migrate, just to put a replica count back.Verification
make skills-checkpasses; the Makefile still parses. Docs and one comment only — no behaviour change.🤖 Generated with Claude Code