Repository navigation
feat(registrar): mesh-wide service catalog in every agent (hybrid index) - #169
Merged
Merged
Conversation
Every agent now keeps a full local index of mesh service NAMES while endpoints stay demand-scoped — the hybrid that preserves Phase 2's fan-out property (per-change cost = consumer count) and gives the ODCDS cold path a local existence oracle. Protocol: SERVICE_ADDED/SERVICE_REMOVED events on the existing watch stream. A service exists while it has >=1 endpoint; transitions are derived inside Snapshot.Apply/Replace (0<->1 crossings, service-set diffs) so the catalog cannot desync from the endpoint data it summarizes. Catalog events BYPASS the watch filter (they are rare, deploy-time transitions — not pod churn) and the full catalog replays on every (re)connect before SNAPSHOT_COMPLETE; the client swaps it wholesale at the marker (only when the server actually resent state), so stale names cannot survive a reconnect. The on-demand observer rejects subscriptions for services not in the catalog: no dependency-set pollution, no watch-filter churn, no reload, no RPC for ghosts. New counter: aether.agent.upstreams.rejected. The new-service race (first caller vs catalog propagation, ~ms) resolves on the client's retry; declared upstreams remain the answer for correctness-critical first traffic. Part 1 of the cold-path convergence work; part 2 (catalog-gated RPC fill + leading-edge reload) brings cold warms to ~20-30ms. Co-Authored-By: Claude Opus 4.8 <[email protected]>
bpalermo
added a commit
that referenced
this pull request
Jun 13, 2026
TestServiceCatalog_ReplayAndIncrementals (merged in #169) left the fake watch stream's err nil, so after its events processStream looped forever — registrar_test TIMEOUT on main (and every branch's CI). Set io.EOF like the sibling processStream tests. The fix existed on the #169 branch but the squash-merge raced ahead of it. Co-authored-by: Claude Opus 4.8 <[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.
Part 1 of the ODCDS convergence plan (hybrid full-name-index / scoped-endpoints, per design discussion).
SERVICE_ADDED/SERVICE_REMOVEDon the existing watch stream; transitions derived insideSnapshot.Apply/Replace(0↔1 endpoint crossings) — impossible to desync.SNAPSHOT_COMPLETE(only when state was resent — a current client keeps its catalog).registry.ServiceCatalog: ghosts never touch dep set/filter/reload;aether.agent.upstreams.rejectedcounter.Part 2 (next PR): catalog-gated RPC-fill in the reload + leading-edge dep-change trigger + watch-cache purge on filter shrink + on_demand timeout 5s→2s.
🤖 Generated with Claude Code