Architecture Decision Record
ADR-080: Production Rollout with Automatic Revision-Only Rollback
Status
Accepted (2026-08-14). Revised 2026-09-03 (the smoke gate is now two tiers: a revision activation
gate runs before the HTTP probes, and the rollback selector filters on healthState instead of
taking a positional index, which closes the overshoot trade-off this record used to carry. The
pre-deploy gate sets have re-converged: Store's deploy job waits on eleven needs and ADC's on
twelve (ADC adds ai-eval-gate), backend-test-gate included in both, so neither rests on the
smoke gate as its only backend backstop. The rollout and revision-only rollback model itself is
unchanged, and the citation anchors are refreshed).
Anchors refreshed 2026-10-01.
Revised 2026-10-07: the four recency gates now run as steps of one freshness job and
backend-test-gate is retired, so deploy waits on seven needs in Store and eight in ADC, and the
test gate is the pull request's required checks.
Revised 2026-10-07: anchors refreshed after the v1.233.0 release and the Store and ADC deploy
workflow prunes; the rollout and revision-only rollback model is unchanged.
Revised 2026-10-21: Store's rollback loop now counts every app into a four-outcome rollback summary
and reports a no-candidate app there instead of under a clean-revert message, so the
indistinguishable-listing trade-off applies in full to ADC only; anchors refreshed after the
2026-10-19 Store and ADC deploy workflow changes and the 2026-10-20 ADC main.bicep change.
Revised 2026-10-26: ADC's rollback loop now counts every app into the same four-outcome rollback
summary as Store and no longer has a clean-revert message, so the indistinguishable-listing
trade-off applies equally to both repos; anchors refreshed after the Store and ADC deploy workflow
and main.bicep changes.
Revised 2026-10-28: anchors refreshed after the Store Defender for SQL and ADC #297 main.bicep
changes, and the ADR-057 and CONTRIBUTING citations now span their full quoted statements.
Revised 2026-11-23: the Trade-offs no longer claim the rollback loop is always reachable inside the
40-minute job, since a slow-failing total outage can reach the timeout first; anchors refreshed after
the Store and ADC deploy.yml and main.bicep growth.
Context
Both production apps deploy to Azure Container Apps from a single deploy.yml job on push to main,
and every gate runs before anything rolls out. The deploy job waits on seven needs in Store
(MMCA.Store/.github/workflows/deploy.yml:1318) and eight in ADC
(MMCA.ADC/.github/workflows/deploy.yml:1571): the shared seven are changes, supply-chain,
cost-guard, the freshness job (whose four steps are the recency gates dr-freshness, load-freshness,
cross-service-freshness and cross-browser-freshness), the chromium e2e-gate, foundation and
build-images, and ADC adds ai-eval-gate for its AI session scorer (ADR-111). The
image matrix pushes to ACR without rolling anything out. The rollout itself is one azure/arm-deploy
step over infra/main.bicep (MMCA.Store/.github/workflows/deploy.yml:1647-1653,
MMCA.ADC/.github/workflows/deploy.yml:1929-1935).
The question that step leaves open is what happens after ARM returns success. ARM success means the revision was accepted by the control plane, not that it serves: a container that boots, fails to reach Key Vault or its database, and crash-loops is still a successful template deployment. Without a post-deploy check, a green workflow run and a dead production are the same colour.
Two existing records already reason from an answer that was never itself written down. ADR-057 states
the premise outright: "production rollback is revision-only", the deploy reverts the image "and
nothing else", and the previous release therefore keeps serving against the new schema
(Website/docs-src/adr/057-expand-contract-schema-evolution-gate.md:31-40), which is the entire
justification for its expand/contract guard. ADR-030 depends on the same model from the other side:
startup migration is the sole migrator, so a failed startup migration fails the new revision and
"there is no automated down-migration"
(Website/docs-src/adr/030-startup-sole-migrator.md:128-130). Both CONTRIBUTING files say the same
thing to contributors (MMCA.Store/CONTRIBUTING.md:58-62, MMCA.ADC/CONTRIBUTING.md:59-63). This
ADR records the rollout and rollback model those documents assume.
Decision
Roll out one revision at a time, verify it from outside, and auto-revert the image only when the verification fails.
- Single-revision rollout. Every container app runs
activeRevisionsMode: 'Single', so a deploy replaces the serving revision rather than splitting traffic across two: Store's identity, catalog, sales, gateway and ui apps (MMCA.Store/infra/main.bicep:1842,2041,2165,2336,2465) and ADC's identity, conference, engagement, notification, gateway and ui apps (MMCA.ADC/infra/main.bicep:2144,2415,2569,2717,2912,3075). There is no canary or blue/green stage and no traffic-splitting step. - Readiness gating is the first line of defence. Every app carries startup, liveness and
readiness probes, so ACA holds user traffic on the old revision until the new one is ready
(
MMCA.Store/infra/main.bicep:2013-2016, five apps at:2013,2137,2304,2414,2539;MMCA.ADC/infra/main.bicep:2366-2384, six apps at:2366,2520,2668,2840,3003,3157). Every backend and the UI take readiness on/health/ready, which is the ADR-025 warm-up gate doing rollout duty. The Gateway is the exception in both repos: its readiness probe is/alive, because its/health/readyfans out to every downstream and would let one failed downstream mark the only Gateway replica unready, a 30-second probe there would also send an HTTP request to every downstream service every 30 seconds and keep their idle replicas off the Container Apps idle rate, and the Gateway has no JwtBearer warm-up task to wait for (MMCA.Store/infra/main.bicep:2417-2424,MMCA.ADC/infra/main.bicep:3019-3028). - A two-tier post-deploy smoke gate is the last gating step of the deploy job.
Smoke test (rollback on failure)verifies the freshly deployed fleet from outside Azure (MMCA.Store/.github/workflows/deploy.yml:1687,MMCA.ADC/.github/workflows/deploy.yml:1974): tier 1 proves the new revisions activated, tier 2 probes them over HTTP, and only these two can fail the job. The sharedprobehelper retries 12 times with a 15-second curl timeout and a 10-second sleep between attempts (MMCA.Store/.github/workflows/deploy.yml:1700-1709,MMCA.ADC/.github/workflows/deploy.yml:1987-1996); Store adds aprobe_posttwin with the same retry loop and exact-status rule (MMCA.Store/.github/workflows/deploy.yml:1711-1723). The step runs underset -uo pipefailwithout-e(:1694,:1981), so a failed probe records the failure instead of aborting the step before the rollback loop can run. - Tier 1 is a revision activation gate and runs before any probe. For every app the newest
revision by
createdTimemust reporthealthStateHealthy, arunningStateofRunningorRunningAtMaxScale, andtrafficWeight100, polled 30 times at 20-second intervals (about ten minutes) (MMCA.Store/.github/workflows/deploy.yml:1747-1777,MMCA.ADC/.github/workflows/deploy.yml:2020-2049). This is the tier that proves the code this run built is the code now serving, and Store's comment records the incident it closes (MMCA.Store/.github/workflows/deploy.yml:1670-1676): between 2026-08-28 and 2026-09-02 every backend revision failed activation, ACA kept the previous revision serving, and the step went green because the HTTP probes were answered perfectly by five-day-old code. Both repos read the revision as JSON and join it withjqrather than asking for-o tsv, because a top-level JMESPath multiselect list rendered as TSV prints one element per line instead of one tab-separated row and every field after the first parses back empty (MMCA.Store/.github/workflows/deploy.yml:1683-1686,1725-1735,MMCA.ADC/.github/workflows/deploy.yml:1998-2009). - Tier 2 probes assert an expected status code, not merely "not an error". Store checks Gateway
/health,/.well-known/jwks.json(through to Identity),/Products(Catalog, anonymous),/Ordersasserted as exactly 401, an unsignedPOST /Payments/webhookasserted as exactly 400 (the Stripe webhook path rejecting a delivery with no signature), plus the UI root (MMCA.Store/.github/workflows/deploy.yml:1779-1797); ADC checks Gateway/health, JWKS,/Events(Conference, anonymous),/Bookmarksand/Notifications/inboxboth asserted as 401, plus the UI root (MMCA.ADC/.github/workflows/deploy.yml:2051-2062). An anonymous 200 on a protected route is a failure, because it would mean authorization stopped being enforced; a 401 from the service proves the request traversed Gateway to service to auth pipeline. - Hardening checks observe, they do not gate. The Gateway
X-Content-Type-Optionscheck prints a warning and never sets the failure flag, because a missing hardening header is not a "revision not serving" condition and must not trip a fleet-wide rollback (MMCA.Store/.github/workflows/deploy.yml:1799-1806,MMCA.ADC/.github/workflows/deploy.yml:2064-2071). - On failure, walk every app back to its last healthy revision. The loop iterates the full app
list (five for Store at
MMCA.Store/.github/workflows/deploy.yml:1695, six for ADC atMMCA.ADC/.github/workflows/deploy.yml:1982). Per app it first re-reads the newest revision and skips that app entirely when the revision is already Healthy, Running and holding 100% of the traffic (MMCA.Store/.github/workflows/deploy.yml:1831-1838,MMCA.ADC/.github/workflows/deploy.yml:2091-2096), so a gate that failed for some other reason cannot undo a good activation. For the rest it selects the newest revision that isactive,Provisioned,Healthyand not the newest by name, then issuesaz containerapp revision copy --from-revision(MMCA.Store/.github/workflows/deploy.yml:1841-1859,MMCA.ADC/.github/workflows/deploy.yml:2106-2121). Every app is attempted before any failure is reported (MMCA.ADC/.github/workflows/deploy.yml:2079-2081), so one bad app does not abandon the rest, and theazcall is deliberately not piped: a pipeline would reporttail's exit status and every rollback would look successful (MMCA.Store/.github/workflows/deploy.yml:1846-1848). - A failed rollback escalates louder than a failed deploy. Apps whose rollback failed accumulate
in
rollback_failed, and the step writes a "Smoke gate failed AND rollback incomplete" block into the job summary naming them, because a fleet split across revisions needs immediate manual attention and must never read as a clean auto-revert. Both repos count every app into one of four outcomes and always append a "Rollback summary: N rolled back, N skipped (newest revision live), N no candidate revision, N rollback failed" line to the job summary (MMCA.Store/.github/workflows/deploy.yml:1815,1861-1870,MMCA.ADC/.github/workflows/deploy.yml:2086,2123-2131); neither has a clean-revert message. - The run fails either way. After the rollback loop the step exits 1
(
MMCA.Store/.github/workflows/deploy.yml:1871,MMCA.ADC/.github/workflows/deploy.yml:2132), so a reverted deploy is still a red run: recovery is automatic, but it is never silent. - What runs after the gate is housekeeping and cannot fail the deploy. A build-cache purge is the
job's final step and carries
continue-on-error: true(MMCA.Store/.github/workflows/deploy.yml:1873-1891,MMCA.ADC/.github/workflows/deploy.yml:2134-2152), so a throttled or failed ACR purge can neither redden a good rollout nor reach the rollback path. Verification ends at the smoke gate. - Rollback is revision-only and never touches data or schema. There is no down-migration step and
no deploy-time
sqlcmdbackstop anywhere in the pipeline; each service self-applies its own migrations at startup as the sole migrator (MMCA.Store/.github/workflows/deploy.yml:1655-1665,MMCA.ADC/.github/workflows/deploy.yml:1937-1950). Reverting the image therefore leaves the new schema in place, which is exactly why ADR-057 requires every migration to be backward compatible one release back.
Rationale
- ARM success is the wrong success signal. The smoke gate converts "the control plane accepted the
template" into "the fleet is serving the revision this run built", which is the only claim a deploy
should be green on. Neither repo rests on it as its only backend backstop: in both, the test gate is
the pull request's required checks, because branch protection enforces admins and requires an
up-to-date branch, so the merged tree is the PR-tested tree
(
MMCA.Store/.github/workflows/deploy.yml:1319-1321,MMCA.ADC/.github/workflows/deploy.yml:1572-1574), and the smoke gate is a second line of defence rather than the gate of record. - Activation is a different question from reachability, so it gets its own tier. Every HTTP probe
enters through the Gateway, and a healthy Gateway keeps answering from the previous backend
revision when the new one never goes ready, so probes alone can only prove that something serves
(
MMCA.ADC/.github/workflows/deploy.yml:1955-1964). Asking the control plane which revision holds the traffic is the only check that distinguishes a shipped deploy from a silently skipped one. - Probing through the Gateway exercises the real path. Hitting the public Gateway FQDN rather than each service directly proves ingress, YARP routing, service discovery and the target service's auth pipeline in one request, which is what actually breaks: a service that deployed but cannot reach its secrets or database fails JWKS long before it fails a container health probe.
- Revision-only rollback is the cheap half that is safe to automate. Copying a previous revision is idempotent, fast and side-effect-free. Reverting data is neither, so it stays a human decision backed by the drilled restore path (ADR-009) instead of being attempted by a workflow step at 2 a.m.
- Single-revision mode keeps the failure model legible. With no traffic splitting there is exactly one serving revision per app, so "roll back" has an unambiguous meaning and an app whose rollback call failed is explicitly reported as split rather than as reverted. An app with no rollback candidate is not reported as split, which is the listing trade-off below.
- Loud beats tidy. Failing the run after a successful rollback, and escalating harder when the rollback itself failed, keeps a broken release visible; a workflow that self-healed quietly would let the same bad commit ship again.
Trade-offs
- Schema is never rolled back, so a bad migration is fix-forward only. The image reverts and the database does not, so the previous release resumes against the new schema. This is the constraint ADR-057's expand/contract guard exists to keep survivable, and a half-applied migration still needs manual recovery (ADR-030). A destructive migration turns the rollback path itself into a broken release.
- A mid-fleet rollback failure splits revisions. The loop is best-effort per app, so a partial failure leaves some apps on the new revision and some on the old, with no automated reconciliation: the escalation in the job summary is the entire remediation, and it is manual.
- Smoke-test blind spots. The tier-2 probes assert HTTP status codes on a handful of anonymous
endpoints. The stale-code blind spot is closed: a green gate answered by the previous revision is
now caught by tier 1 (
MMCA.Store/.github/workflows/deploy.yml:1670-1676). The rest remain. A revision that returns 200 with wrong data, a broken broker consumer, a stalled outbox, a failing inter-service gRPC edge, the SignalR hub, and every authenticated write path are all invisible to the gate. Store never probes Catalog writes, and reaches the Stripe path only through the unsigned webhook POST that must be rejected with 400, never a signed delivery (MMCA.Store/.github/workflows/deploy.yml:1788-1795); ADC never probes the live layer beyond a 401. - The app list is hand-maintained.
APPSis a literal string (MMCA.Store/.github/workflows/deploy.yml:1695,MMCA.ADC/.github/workflows/deploy.yml:1982), so a new container app added to Bicep is neither activation-checked nor rolled back until someone remembers to add it here. - A failed revision listing is indistinguishable from "nothing to roll back". The
az revision listcall swallows errors into an empty string, which is also what a genuinely empty result looks like when no other revision isactive,ProvisionedandHealthy, and in neither repo does that app joinrollback_failed. Both repos log "no candidate revision ... left on <current>" and count the app under "no candidate revision" in the rollback summary (MMCA.Store/.github/workflows/deploy.yml:1841-1843,1856-1859,MMCA.ADC/.github/workflows/deploy.yml:2106-2108,2118-2121), so the case is visible in both but still not separated from a listing failure. - Detection is slow and bounded by the job timeout. The activation gate runs first and can spend
at least ten minutes before a single probe is sent (30 x 20s of sleep, plus one sequential
az containerapp revision listper app on every pass); each failing probe then burns up to 12 attempts, and the probes run sequentially. A probe whose curl hits the full 15-second timeout costs about five minutes (12 x (15s + 10s)), while one that gets a wrong status code or a refused connection back at once costs about two minutes (12 x 10s of sleep), all against atimeout-minutes: 40job (MMCA.Store/.github/workflows/deploy.yml:1317,MMCA.ADC/.github/workflows/deploy.yml:1570). Both repos now bound the activation tier the same way, on one shared budget (see the 2026-09-10 revision), so a fleet-wide activation failure costs that budget once in either repo rather than scaling with the app count. The rollback loop is not reachable inside the 40-minute job when all (or most) of the six tier-2 probes in either repo hit the full curl timeout: about 30 minutes of probes on top of the activation tier and the rollout earlier in the same job reaches the timeout before the loop runs. One or two slow-failing probes, or any number that fail fast, leave the loop reachable. - Only a smoke-gate failure triggers a rollback. A regression that passes the probes and is found
minutes later is reverted by hand (a redeploy of the previous commit or a manual
revision copy); there is no alert-driven auto-rollback wired to the SLO alerts (ADR-062).
Revision (2026-09-10)
ADC's activation tier is now one shared budget over the whole fleet, matching Store. The attempt
loop is the outer loop and the apps are iterated inside it: for i in $(seq 1 30) at
MMCA.ADC/.github/workflows/deploy.yml:1677 encloses for app in $APPS at :1679, the pass
collects a pending list and breaks on the first fully-activated sweep (:1690), and there is one
sleep 20 per pass (:1692), the whole gate spanning :1668-1697. Store's is the same shape
(MMCA.Store/.github/workflows/deploy.yml:1514 outer, :1516 inner, break at :1529, sleep at
:1531).
The arithmetic is the point of the change, not the tidiness. A shared budget is 30 x 20s = about ten
minutes of activation polling regardless of how many apps are pending, so the ceiling no longer
scales with the fleet: ADC's six apps used to be able to spend roughly an hour there, against a
timeout-minutes: 40 job (:1304; Store :1199). A job killed at its timeout never reaches its
rollback loop, so the old shape could turn a failed activation into a deploy with no revert, which is
the failure this record exists to prevent. Both rollback loops are unchanged and reachable
(MMCA.ADC/.github/workflows/deploy.yml:1730-1761,
MMCA.Store/.github/workflows/deploy.yml:1565-1600).
Revision (2026-10-01)
Three current-state statements are corrected; the rollout and revision-only rollback model is
unchanged. First, the Gateway is not readiness-gated on /health/ready: in both repos its
readiness probe is /alive, because its /health/ready fans out to every downstream and one failed
downstream would mark the only Gateway replica unready, while the Gateway has no JwtBearer warm-up
task for readiness to wait on (MMCA.Store/infra/main.bicep:1956-1963,
MMCA.ADC/infra/main.bicep:2423-2432). The backends and the UI still take readiness on
/health/ready. Second, Store's tier 2 gained a sixth probe: an unsigned POST /Payments/webhook
through a new probe_post helper that must return exactly 400, so a webhook that accepts an
unauthenticated delivery or a payment path that is not served fails the gate
(MMCA.Store/.github/workflows/deploy.yml:1420-1432,1497-1504); the Trade-offs blind-spot line no
longer says Store never probes Stripe. Third, the Status line said both deploy jobs wait on the
same ten needs, which contradicted Context: Store waits on eleven and ADC on twelve
(MMCA.Store/.github/workflows/deploy.yml:1136, MMCA.ADC/.github/workflows/deploy.yml:1185). Every
deploy.yml and main.bicep anchor in Context, Decision, Rationale and Trade-offs is refreshed, and
the ADR-057 citation now spans the quoted lines (057-expand-contract-schema-evolution-gate.md:20-26).
The 2026-09-10 revision keeps its original anchors as a historical record.
Revision (2026-10-06)
No content correction: the rollout and revision-only rollback model, the eleven and twelve
deploy needs, the probe set and the rollback semantics all still match source. Both deploy.yml
files grew, so every anchor moved. The facts the 2026-09-10 revision records now sit at: ADC's shared
activation budget seq 1 30 at MMCA.ADC/.github/workflows/deploy.yml:1638 with one sleep 20 at
:1653 (Store MMCA.Store/.github/workflows/deploy.yml:1519 and :1536), the rollback loops at
MMCA.ADC/.github/workflows/deploy.yml:1687-1732 and MMCA.Store/.github/workflows/deploy.yml:1577-1623,
and timeout-minutes: 40 at ADC :1241 and Store :1186. The Gateway /alive readiness probe the
2026-10-01 revision cites is now at MMCA.Store/infra/main.bicep:1966-1973 and
MMCA.ADC/infra/main.bicep:2473-2482. Every deploy.yml, main.bicep and ADR-030 anchor in
Context, Decision, Rationale and Trade-offs was re-verified against current source; the earlier
revisions keep their anchors as recorded.
Revision (2026-10-07)
Re-verified against current source. No content correction: the rollout and revision-only rollback
model, the probe set, the rollback semantics and the seven and eight deploy needs
(MMCA.Store/.github/workflows/deploy.yml:1083, MMCA.ADC/.github/workflows/deploy.yml:1145) all
still match source. Both deploy.yml files shrank in their workflow prunes and MMCA.ADC/infra/main.bicep
grew, so every anchor in Context, Decision, Rationale and Trade-offs moved and is re-pointed here.
- The 2026-10-06 revision's statement that the eleven and twelve
deployneeds still match source is historical: the needs are now seven in Store and eight in ADC, as the third Status sentence and Context already record. The 2026-10-06 anchors no longer resolve and stay as recorded; the facts they cite now sit at: ADC's shared activation budgetseq 1 30atMMCA.ADC/.github/workflows/deploy.yml:1530with onesleep 20at:1545(StoreMMCA.Store/.github/workflows/deploy.yml:1406and:1423), the rollback loops atMMCA.ADC/.github/workflows/deploy.yml:1579-1624andMMCA.Store/.github/workflows/deploy.yml:1464-1510, andtimeout-minutes: 40at ADC:1144and Store:1082. - ADC's probe URLs are no longer held in separate variables: each probe passes its URL inline
(
MMCA.ADC/.github/workflows/deploy.yml:1552-1563, StoreMMCA.Store/.github/workflows/deploy.yml:1430-1448), so the tier-2 citations drop the old variable-line ranges. - Anchors re-verified against current source: arm-deploy
MMCA.Store/.github/workflows/deploy.yml:1300-1306andMMCA.ADC/.github/workflows/deploy.yml:1433-1439; no-sqlcmd sole-migrator note Store:1308-1316, ADC:1441-1451; smoke step Store:1338, ADC:1475;set -uo pipefailStore:1345, ADC:1482;APPSStore:1346, ADC:1483;probeStore:1351-1360, ADC:1488-1497;probe_postStore:1364-1374; JSON plusjqrevision read Store:1334-1337,1376-1386, ADC:1499-1510; tier 1 Store:1398-1428, ADC:1521-1550; incident comment Store:1321-1327; tier-2 probes Store:1430-1448, ADC:1552-1563; unsigned-webhook comment Store:1439-1446; hardening Store:1450-1457, ADC:1565-1572; skip guard Store:1473-1483, ADC:1585-1592; selector and copy Store:1484-1496, ADC:1593-1607; unpiped copy Store:1491-1493; swallowed listing Store:1486-1488,1497-1499, ADC:1602-1604,1611-1613; attempt-every-app comment and summary ADC:1580-1582,1615-1623, Store summary:1501-1509;exit 1Store:1510, ADC:1624; purge Store:1512-1530, ADC:1626-1644; gateway-serves-old-code rationale ADC:1453-1474; test-gate rationale Store:1084-1086, ADC:1146-1148(unchanged);activeRevisionsMode: 'Single'MMCA.ADC/infra/main.bicep:1688,1935,2088,2223,2413,2576; ADC probe blocks:1886-1911, six apps at:1886,2039,2174,2341,2504,2658; ADC Gateway/alivereadiness:2520-2529. The Storemain.bicepanchors are unchanged.
Revision (2026-10-21)
Re-verified against current source. The rollout and revision-only rollback model, the seven and
eight deploy needs (MMCA.Store/.github/workflows/deploy.yml:1098,
MMCA.ADC/.github/workflows/deploy.yml:1160), the probe set, the shared 30 x 20s activation budget
and the skip, selector and copy rules all still match source. Store's rollback reporting changed,
and both deploy.yml files and both main.bicep files moved, so every anchor in Context, Decision,
Rationale and Trade-offs is re-pointed here. The 2026-10-07 revision's anchors, including its
statement that the Store main.bicep anchors were unchanged, stay as recorded.
- Store's rollback loop counts each app as rolled back, skipped (newest revision live), no
candidate revision, or rollback failed, and always appends one "Rollback summary" line with the
four counts to the job summary (
MMCA.Store/.github/workflows/deploy.yml:1497,1543-1552); it no longer has a clean-revert message. An app with no rollback candidate is logged as "no candidate revision ... left on <current>" (:1538-1541). The listing still swallows errors into an empty string (:1523-1525) and the app still does not joinrollback_failed, so a failed listing and an empty one remain indistinguishable in Store too, but the case is no longer reported as a clean revert. ADC is unchanged: "no previous revision ... skipping" (MMCA.ADC/.github/workflows/deploy.yml:1630) and "All apps rolled back to their previous revision" whenrollback_failedis empty (:1640), which it also writes when every app was skipped as already serving (:1607-1609). The Decision escalation bullet and the Trade-offs listing bullet now describe both repos, and the Rationale single-revision bullet no longer claims every post-failure state is either reverted or reported as split. - The Gateway
/alivereadiness rationale in source also gives a cost reason, which the Decision bullet now carries: a 30-second/health/readyprobe sends an HTTP request to every downstream service every 30 seconds, which alone keeps their idle replicas off the Container Apps idle rate (MMCA.Store/infra/main.bicep:2060-2066,MMCA.ADC/infra/main.bicep:2676-2682). - The ADR-030 citation for "a failed startup migration fails the new revision ... no automated
down-migration" now points at
030-startup-sole-migrator.md:113-115, and both CONTRIBUTING citations span the full revision-only statement,MMCA.Store/CONTRIBUTING.md:58-61andMMCA.ADC/CONTRIBUTING.md:58-61. - Anchors re-verified against current source:
timeout-minutes: 40StoreMMCA.Store/.github/workflows/deploy.yml:1097, ADCMMCA.ADC/.github/workflows/deploy.yml:1159; test-gate rationale Store:1099-1101, ADC:1161-1163; arm-deploy Store:1329-1335, ADC:1448-1454; no-sqlcmd sole-migrator note Store:1337-1347, ADC:1456-1469; smoke step Store:1369, ADC:1493;set -uo pipefailStore:1376, ADC:1500;APPSStore:1377, ADC:1501;probeStore:1382-1391, ADC:1506-1515;probe_postStore:1395-1405; JSON plusjqrevision read Store:1365-1368,1407-1417, ADC:1517-1528; tier 1 Store:1429-1459, ADC:1539-1568(seq 1 30Store:1437, ADC:1548;sleep 20Store:1454, ADC:1563); incident comment Store:1352-1358; tier-2 probes Store:1461-1479, ADC:1570-1581; unsigned-webhook comment Store:1470-1477; hardening Store:1481-1488, ADC:1583-1590; rollback loops Store:1495-1553, ADC:1597-1642; skip guard Store:1509-1520, ADC:1603-1610; selector and copy Store:1521-1537, ADC:1611-1628; unpiped copy Store:1528-1530; attempt-every-app comment ADC:1598-1600; summary Store:1543-1552, ADC:1633-1641;exit 1Store:1553, ADC:1642; purge Store:1555-1573, ADC:1644-1662; gateway-serves-old-code rationale ADC:1474-1483;activeRevisionsMode: 'Single'MMCA.Store/infra/main.bicep:1521,1703,1827,1979,2108andMMCA.ADC/infra/main.bicep:1838,2091,2244,2379,2569,2732; probe blocks Store:1675,1799,1947,2057,2182, ADC:2042,2195,2330,2497,2660,2814; Gateway/alivereadiness Store:2060-2067, ADC:2676-2685.
Revision (2026-10-26)
Re-verified against current source. The rollout and revision-only rollback model, the seven and
eight deploy needs (MMCA.Store/.github/workflows/deploy.yml:1099,
MMCA.ADC/.github/workflows/deploy.yml:1161), the probe set, the shared 30 x 20s activation budget,
the Gateway /alive readiness rationale and the skip, selector and copy rules all still match
source. ADC's rollback reporting changed, and both deploy.yml files and both main.bicep files
moved, so every anchor in Context, Decision, Rationale and Trade-offs is re-pointed here. The
2026-10-21 revision's anchors, including its statement that ADC's reporting was unchanged, stay as
recorded.
- ADC's rollback loop now counts each app as rolled back, skipped (newest revision live), no
candidate revision, or rollback failed (
MMCA.ADC/.github/workflows/deploy.yml:1605-1606), writes the incomplete block only whenrollback_failedis non-empty (:1643-1650), and always tees one "Rollback summary" line with the four counts to the job summary (:1651), matching Store (MMCA.Store/.github/workflows/deploy.yml:1497-1498,1544-1553). ADC no longer has a clean-revert message, and an app with no rollback candidate is logged as "no candidate revision for <app>: left on <newest>" (MMCA.ADC/.github/workflows/deploy.yml:1639). The listing still swallows errors into an empty string (:1626-1628) and the app still does not joinrollback_failed, so a failed listing and an empty one remain indistinguishable in both repos. The Decision escalation bullet and the Trade-offs listing bullet now describe one shared behavior. - The ADR-057 citation for "revision-only", "nothing else" and "keeps serving traffic against the
new schema" now spans
057-expand-contract-schema-evolution-gate.md:25-30, and the ADR-030 citation for "no automated down-migration" now spans030-startup-sole-migrator.md:115-117. - Anchors re-verified against current source:
timeout-minutes: 40StoreMMCA.Store/.github/workflows/deploy.yml:1098, ADCMMCA.ADC/.github/workflows/deploy.yml:1160; test-gate rationale Store:1100-1102, ADC:1162-1164; arm-deploy Store:1330-1336, ADC:1449-1455; no-sqlcmd sole-migrator note Store:1338-1348, ADC:1457-1470; smoke step Store:1370, ADC:1494;set -uo pipefailStore:1377, ADC:1501;APPSStore:1378, ADC:1502;probeStore:1383-1392, ADC:1507-1516;probe_postStore:1396-1406; JSON plusjqrevision read Store:1366-1369,1408-1418, ADC:1518-1529; tier 1 Store:1430-1460, ADC:1540-1569(seq 1 30Store:1438, ADC:1549;sleep 20Store:1455, ADC:1564); incident comment Store:1353-1359; tier-2 probes Store:1462-1480, ADC:1571-1582; unsigned-webhook comment Store:1471-1478; hardening Store:1482-1489, ADC:1584-1591; rollback loops Store:1496-1554, ADC:1598-1652; skip guard Store:1510-1521, ADC:1608-1616; selector and copy Store:1522-1538, ADC:1617-1637; unpiped copy Store:1529-1531; attempt-every-app comment ADC:1599-1601; summary Store:1544-1553, ADC:1643-1651;exit 1Store:1554, ADC:1652; purge Store:1556-1574, ADC:1654-1672; gateway-serves-old-code rationale ADC:1475-1484;activeRevisionsMode: 'Single'MMCA.Store/infra/main.bicep:1527,1709,1833,1985,2114andMMCA.ADC/infra/main.bicep:1874,2127,2280,2415,2605,2768; probe blocks Store:1681,1805,1953,2063,2188, ADC:2078,2231,2366,2533,2696,2850; Gateway/alivereadiness Store:2066-2073, ADC:2712-2721.
Revision (2026-10-28)
Re-verified against current source. No content correction: every container app in both repos
still runs activeRevisionsMode: 'Single', every backend and the UI still take readiness on
/health/ready, and the Gateway still takes readiness on /alive for the fan-out, idle-rate and
no-JwtBearer reasons the Decision bullet gives. Both main.bicep files moved (Store by +1 line,
ADC by -3 lines), so the main.bicep anchors in Decision are re-pointed here; the deploy.yml
anchors still resolve. The 2026-10-26 revision's anchors stay as recorded.
- The ADR-057 citation for "revision-only", "nothing else" and "keeps serving traffic against the
new schema" now spans
057-expand-contract-schema-evolution-gate.md:28-37("revision-only" at:28, "nothing else" at:35, "new schema" at:37), and both CONTRIBUTING citations span:58-62, where the revision-only statement ends with "NEW schema" at:62(MMCA.Store/CONTRIBUTING.md:58-62,MMCA.ADC/CONTRIBUTING.md:58-62). - Anchors re-verified against current source:
activeRevisionsMode: 'Single'MMCA.Store/infra/main.bicep:1528,1710,1834,1986,2115andMMCA.ADC/infra/main.bicep:1871,2124,2277,2412,2602,2765; probe blocks (theprobes: [lines) Store:1682,1806,1954,2064,2189(first block:1682-1685), ADC:2075,2228,2363,2530,2693,2847(first block:2075-2093); backend and UI readiness/health/readyStore:1685,1809,1957,2192, ADC:2093,2246,2381,2548,2865; Gateway/alivereadiness rationale and probe Store:2067-2074, ADC:2709-2718.
Revision (2026-11-23)
Re-verified against current source. The rollout and revision-only rollback model, the seven and
eight deploy needs (MMCA.Store/.github/workflows/deploy.yml:1318,
MMCA.ADC/.github/workflows/deploy.yml:1571), the probe set and its 401/400 assertions, the shared
30 x 20s activation budget, the skip, selector and copy rules, the four-outcome rollback summary and
the Gateway /alive readiness rationale all still match source. Every deploy.yml and
main.bicep anchor moved, so the 2026-10-28 revision's statement that the deploy.yml anchors still
resolve is historical; its anchors and those of the earlier revisions stay as recorded.
- The Trade-offs timeout bullet said the rollback loop is reachable inside the 40-minute job in both
repos. The figures in source do not support that unconditionally: the activation tier can spend
30 x 20s of sleep plus one
az containerapp revision listper app on each pass, at least ten minutes (MMCA.Store/.github/workflows/deploy.yml:1730,1755-1772,MMCA.ADC/.github/workflows/deploy.yml:2005,2029-2044), and each of the six tier-2 probes in either repo can spend 12 attempts of a 15-second curl timeout plus a 10-second sleep, about five minutes (MMCA.Store/.github/workflows/deploy.yml:1700-1709,1779-1797,MMCA.ADC/.github/workflows/deploy.yml:1987-1996,2051-2062), so a total outage whose probes all hit the curl timeout spends at least 40 minutes in the gate alone, inside atimeout-minutes: 40job (MMCA.Store/.github/workflows/deploy.yml:1317,MMCA.ADC/.github/workflows/deploy.yml:1570) that also runs the rollout first. The bullet now says the loop is not reachable when all (or most) failing probes hit the full curl timeout, and separates the slow (about five minutes) and fast (about two minutes) per-probe costs. - The ADR-030 citation for "a failed startup migration fails the new revision ... no automated
down-migration" now points at
030-startup-sole-migrator.md:128-130, the ADR-057 citation for "revision-only", "nothing else" and "new schema" at057-expand-contract-schema-evolution-gate.md:31-40("revision-only" at:31, "nothing else" at:38, "new schema" at:40), and the ADC CONTRIBUTING citation atMMCA.ADC/CONTRIBUTING.md:59-63("NEW schema" at:63); the Store one is unchanged atMMCA.Store/CONTRIBUTING.md:58-62. - Anchors re-verified against current source:
timeout-minutes: 40StoreMMCA.Store/.github/workflows/deploy.yml:1317, ADCMMCA.ADC/.github/workflows/deploy.yml:1570; test-gate rationale Store:1319-1321, ADC:1572-1574; arm-deploy Store:1647-1653, ADC:1929-1935; no-sqlcmd sole-migrator note Store:1655-1665, ADC:1937-1950; smoke step Store:1687, ADC:1974;set -uo pipefailStore:1694, ADC:1981;APPSStore:1695, ADC:1982;probeStore:1700-1709, ADC:1987-1996;probe_postStore:1711-1723; JSON plusjqrevision read Store:1683-1686,1725-1735, ADC:1998-2009; tier 1 Store:1747-1777, ADC:2020-2049; incident comment Store:1670-1676; tier-2 probes Store:1779-1797, ADC:2051-2062; unsigned-webhook comment and probe Store:1788-1795; hardening Store:1799-1806, ADC:2064-2071; rollback loops Store:1813-1871, ADC:2078-2132; skip guard Store:1831-1838, ADC:2091-2096; selector, copy and no-candidate branch Store:1841-1859, ADC:2106-2121; unpiped copy Store:1846-1848; attempt-every-app comment ADC:2079-2081; counters Store:1815, ADC:2086; incomplete block and summary Store:1861-1870, ADC:2123-2131;exit 1Store:1871, ADC:2132; purge Store:1873-1891, ADC:2134-2152; gateway-serves-old-code rationale ADC:1955-1964;activeRevisionsMode: 'Single'MMCA.Store/infra/main.bicep:1842,2041,2165,2336,2465andMMCA.ADC/infra/main.bicep:2144,2415,2569,2717,2912,3075; probe blocks Store:2013,2137,2304,2414,2539(first block:2013-2016), ADC:2366,2520,2668,2840,3003,3157(first block:2366-2384); backend and UI readiness/health/readyStore:2016,2140,2307,2542, ADC:2384,2538,2686,2858,3175; Gateway/alivereadiness rationale and probe Store:2417-2424, ADC:3019-3028.
Related
ADR-057 (built on this model: revision-only rollback is why every migration must be backward compatible one release back), ADR-030 (startup migration as sole migrator, the reason no schema revert exists to automate), ADR-025 (the readiness gate that keeps traffic off a cold revision during the rollout), ADR-064 (the recency gates that must be green before the rollout starts), ADR-009 (the drilled restore path that covers what revision rollback cannot), ADR-006 (per-service databases, so recovery blast radius is one service), ADR-062 (post-deploy detection for regressions the smoke gate misses).