Repository navigation
Description
Summary
On a node with no local replica of an upstream, the node-agent's demand-scoped dependency set expires that upstream's 1h TTL even while the upstream is under continuous load, drops its cluster from the snapshot, and the ODCDS re-discovery that should repair it immediately instead times out for ~5 minutes until the ADS stream happens to reset. Every request to that upstream from that node fails for the duration.
This is pre-existing (identical on rev191 and rev192) and has been invisible to every soak because the churn driver rolls aether-agent every ~15 minutes, which resets the dependency set and restarts the TTL clock. It only surfaces in the quiet hours between soaks.
Evidence (main-worker-03, 2026-09-05, 10 minutes before the soak's T0)
worker-03 has no local echo replica (echo runs on w02/w04/w05). The external prober on w03 hits echo.aether-test.aether.internal:18081 at 25 rps continuously.
00:45:25.993Z agent expired observed upstreams from node dependency set count=1
00:45:26.020Z agent service left dependency set; dropping cluster/vhost (cold path takes over)
cluster=aether-test/echo snapshot clusters 24→23, endpoints 10→9
00:45:26 → envoy cm odcds: on-demand discovery for cluster
00:50:36Z echo.aether-test.aether.internal[:18081] timed out (~2/s, for 5m10s)
00:50:36.363Z envoy DeltaAggregatedResources gRPC config stream to agent_xds closed: 13,
upstream_reset_after_response_started{connection_termination}
00:50:36.729Z agent observed undeclared upstream (ODCDS miss); adding to node dependency set
service=aether-test/echo ttl=1h0m0s → clusters 24; odcds-xdstp: added/updated 1 cluster(s)
Prober counters for the 30 minutes containing that episode, prober-qqwvb (w03) only:
| result | *.aether.internal |
*.svc.cluster.local |
|---|---|---|
http_error |
1397 | 1390 |
timeout |
157 | 166 |
Both DNS targets fail equally, and every dns_* class is zero — the resolver is not involved; this is the backend path.
Decisive correlation: over 24h the only two probers with any http_error are w01 and w03, exactly the two nodes with no local echo replica. w02/w04/w05 are at 0. Nodes with a local endpoint keep the cluster warm; nodes without one ride the demand-scoped path and hit this.
Pre-existing, not a regression: raw http_error deltas, w01 / w03 — post-rev192 (194 min): 198 / 2787; the 194 min before it on rev191: 1115 / 3910. Episodic on both builds.
Two separable defects
-
The TTL expires under load. Live traffic to the upstream does not refresh the dependency-set entry; only an ODCDS miss does. So a node that has been serving a cross-node upstream continuously for an hour drops it, on purpose, and then has to re-discover it. The TTL should be refreshed by observed use (or the drop should be deferred while the cluster has live connections/requests), not only by misses.
-
The ODCDS re-discovery stalls for 5 minutes — this is the outage. After the drop, Envoy's on-demand request for the cluster should produce an immediate
ODCDS miss → add → push. Instead the on-demand discovery timed out continuously for 5m10s and only succeeded once the ADS stream was reset (upstream_reset_after_response_started). That looks like the agent's delta-xDS ODCDS handling not answering a request for a resource it just removed on the same stream — a stuck-subscription or nonce/state bug. Same family as fix(capture): on-demand catch-all + default mesh-DNS/capture on #288 (capture ODCDS stuck-404, resolved via the catch-all), but on the outbound demand-scoped path.
(1) makes (2) reachable every hour; (2) is what turns a would-be 100ms blip into a 5-minute outage. Fixing (2) alone bounds the damage; fixing (1) alone hides (2) again.
Why no soak ever saw it, and why no alert fired
- The churn driver rolls
aether-agentroughly every 15 minutes across the 7h15m churn window. Each roll rebuilds the dependency set from ODCDS misses with a fresh 1h TTL, so the TTL never expires during a soak. The 09-03 and 09-04 runs recorded 15–31http_errorin 8 hours; the quiet 24h window around them holds thousands. The soak's own methodology masks the defect. - No alert:
EnvoyControlPlaneDisconnectedcannot trip because the stream stays up until the reset that fixes it. ~2,800 errors and a 5-minute single-node outage passed in silence. That is an alerting gap in its own right (a per-nodehttp_errorburst rule on the prober tier would have caught it).
Reproduction
Pick a node with no local replica of a service, drive continuous traffic to that service from that node, do not roll the agent, wait ~1h from the last ODCDS miss. Watch for expired observed upstreams in the agent log followed by cm odcds: ... timed out in Envoy.
Suggested acceptance
- Continuous traffic to a demand-scoped upstream keeps it in the dependency set (TTL refreshed on use, or expiry deferred while the cluster is active).
- An ODCDS request for a just-dropped cluster is answered within the on-demand timeout, on the existing stream, without needing a stream reset.
- A soak variant (or a dedicated test) that runs ≥1h15m without an agent roll on a node lacking a local replica, so this class is no longer methodologically invisible.
- A prober-tier alert on per-node
http_errorbursts.
Found by the 2026-09-05 soak pre-flight. Related: #288 (capture ODCDS stuck-404), proposal 004 (demand-scoped distribution), #638 (the other cross-node identity/binding defect that concentrates on non-local paths).
Activity
bpalermo commentedon Sep 5, 2026
Two data points from the 8h soak 2026-09-05 (rev192/0.92.0-a3cde6c)
1. The blind spot this issue describes is confirmed, quantitatively
Zero TTL episodes occurred inside the graded window (T0 01:05:51Z → 09:05:51Z). Across all five agents,
grep -cE "service left dependency set|expired observed upstreams"returned 3/3/4/2/1 — but every one of those 13 lines is timestamped 09:06:17Z, one second after I deleted the k6 DaemonSet at 09:06:16Z during teardown. Not one line fell inside the graded window.That is exactly the mechanism this issue predicts: the churn driver rolled
aether-agentat 02:35:51Z and again at 06:05:51Z, resetting the 1h TTL clock each time, so the TTL never got to expire under load. A soak structurally cannot observe this bug.http_erroron the mesh_dns tier inside the window was 11, and all 11 join the #638 TRIPLE episode by node and timestamp (8 on w05, 3 on w02) — none are TTL.2. A much cheaper reproduction than waiting an hour
The teardown accidentally produced a clean repro. Deleting the k6 runners shrank the demand set, echo left the dependency set on the nodes with no local echo replica, and ODCDS re-discovery stalled on exactly those nodes:
echo's three replicas were on w02/w04/w05, so w01 and w03 are precisely the no-local-replica nodes — the same pair as the pre-flight episode at 00:45–00:50Z. The proxy log on w03 shows the stall directly:
So the trigger is not the 1h TTL specifically — it is any demand-set shrink that drops a service from a node with no local replica. Deleting a workload that was holding the dependency reference reproduces it in seconds instead of an hour. That should make this far easier to write a regression test for.
One difference worth noting: this episode self-resolved in ~2 minutes (
rate(...[2m])non-zero only at the 09:07Z and 09:08Z steps, zero from 09:09Z), not the ~5m10s ADS-stream-reset stall seen pre-flight. Two nodes, ~267 requests total. Whether the shorter recovery is a property of the shrink path or just variance in when the ADS stream next resets, I did not determine.Neither episode fired an alert — still no coverage for this.
test(soak): add a no-roll window + demand-set shrink so #682 is visib…
fix(xds): unwedge ODCDS after a demand-set shrink and stop expiring i…
fix(xds): alias the ODCDS authority on the mesh port, and re-seed the…
bpalermo commentedon Sep 6, 2026
Soak 2026-09-06, rev203 — first soak window where the 1h TTL could actually expire under load. It expired on all five workers and cost nothing.
churn.sh now holds a 90-min no-roll window (06:54:20Z → 08:24:20Z) then a deliberate svc-5 → 0 for 90 s shrink.
Zero prober errors — no timeouts, no
http_error, either path — across the entire no-roll window, including on w01 and w03, the two no-local-echo-replica nodes that produced both 09-05 episodes. No ODCDS stall signature. Identity re-binding after the restore converged in ~8 s.Two caveats before reading this as fixed: echo kept 3 replicas (w02/w04/w05) throughout, so the specific stall path — a request to a service with no local replica while its cluster is absent — was not directly exercised; and the ~1h TTL fired only ~1 min into the window, so the sustained post-expiry state was observed for ~88 min rather than the expiry-under-demand transition being stressed repeatedly.
Also: the grading runbook's log phrase is wrong.
service left dependency setreturns a controlled zero; the real line isexpired observed upstreams from node dependency set.perf: drop controller-runtime from cni-install and prober (25→5 MiB, …
fix(registrar,node): copy cached endpoints out of the lock, never los…
chore(soak): first proxy roll at T0+60, honest SHRINK cost, k6 timing…
feat(agent)!: no cluster is named for the proxy's port, and 18081 and…