Repository navigation
feat(moq-net): origin::Consumer::local is public again - #9159
Conversation
An embedder that records, republishes, or meters each broadcast once, on the node that ingests it, needs the view of routes that entered here. It went behind test-support in #9053 on the belief that nothing outside moq-net's tests read it. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
There was a problem hiding this comment.
✅ No new issues found.
Approach: sound. Un-gating local() and folding local_view() into it is the smallest change that restores the public API, and it avoids exposing the other test-support doors.
Reviewed changes
Consumer::local()is public: thetest-supportgate is removed andlocal_view()is folded into it. The body is unchanged, so behavior is identical.- Doc comments: the
local()doc says who reads it, and theHorizon::localdoc link is updated. - Tests: every
local_view()call inorigin.rstests now useslocal(). A grep finds no remaining references to the old name.
claude-sonnet-5-5 | 𝕏
|
No actionable comments were generated in the recent review. Walkthrough
Merge Risk:
|

origin::Consumer::local()is public again, with no feature gate.Why
#9053 moved
Consumer::local()behindtest-support, on the belief that nothing outside moq-net's tests read it. An embedder of the relay library does: a service that records, republishes, or meters each broadcast exactly once needs to act on the node that ingests it, not on every node a cluster peer forwards it to. The local view, which hides every route aLink::PeerorLink::Upstreamhandle announced, is exactly that, and it has no public substitute:RouteInfo::entered_from()andorigin::Sourceare gated too, and filtering routes by hand would need both.Enabling
test-supportin a production build to reach it would also expose the other test doors (with_solicit,with_update_hold,entered_from), so the gate isn't a workable answer.Changes
origin::Consumer::local()is public and ungated. The crate-privatelocal_view()it wrapped is folded into it, and the crate's own tests calllocal().Public API and wire impact
moq_net::origin::Consumer::local()to the default public API. Not breaking: it was public in the last release.Validation
just check(in the dev shell) passes: 10,724 tests, includinglocal_view_hides_peer_routesand moq-relay's cluster tests that readlocal().Models
Size: S
Implementer: Claude Code, claude-opus-5-5, high effort
🤖 Generated with Claude Code
(Written by Claude Opus 5.5 with high effort)
Review
Rewritten by
quest reviewafter each round.Head: 733ecb6
Base: origin/main at f9fc03b
Risk: medium,
the base has no RISK.md to name what is always high or customer-facing, so every change is mediumClassified: medium by default
Reviewer: Codex, gpt-6.1-sol, medium effort
Session:
01a1f2aa-1cba-7140-bc41-deaf1fde4862, round 1Score: 10/10,
The change exposes the existing local-route filter without changing behavior and updates internal references consistently; source review found no actionable defects, with builds and tests not run as instructed.Rounds: 2; first round 0; findings 0: fixed 0, refuted 0, open 0
Findings: none