Skip to content

e2e G-CLIENT-03: regional proxy warming (validates core latency claim) #1036

Closed as not planned

Description

@alpergundogdu

Validates the core latency/locality claim. Depends on: e2e harness (multi-region node fixture).

  • Setup: blob H held only by a far node (high RTT); a nearby bonded non-holder in the client's region.
  • Steps: client fetches H → assert it routes through the nearby proxy (not the far holder), the proxy pull-through-fills and caches H, and publishes a DHT STORE; a second regional client then fetches H → assert it gets the nearer copy (a real locality win).
  • Negative: proxy ranks by measured RTT only (spoofed region claim does not help); if the proxy declines, the client falls back to the direct far holder; speculative spend stays within the unrecouped-leech budget.

Spec anchor: internal/Product/gaps-and-e2e-test-specs.md#g-client-03.

Activity

  1. added
    prio:critical
    prio:high
    kind:test
    on Jun 30, 2026
  2. altanoruc commented on Jul 19, 2026

    @altanoruc
    Contributor

    Automated triage note for a later run: this e2e is not currently standalone. The client proxy-warming trigger it is meant to validate is still unimplemented and tracked by #1174; that issue is itself waiting on pinned latency constants plus the per-peer RTT-map/background-sweep prerequisite. Please mark this blocked on those implementation issues and, once they land, pin the deterministic multi-region/RTT test seam to use. Until then an agent would have to build production behavior and invent the latency harness while writing the e2e, well beyond this issue's stated test scope.

  3. thiras commented on Aug 1, 2026

    @thiras
    Contributor

    Audit note (2026-08-01, HEAD b2a9651): the blocking premise in the triage comment is lifted — the proxy-warming trigger, RttMap, and pinned latency constants shipped in #1357 (ed9c624); see the update on #1174.

    What actually remains before this e2e can be written: a deterministic multi-region/RTT test seam, and the fallback-chain residue tracked as #1174's remaining scope (today only the first warmed candidate is used).

  4. alpergundogdu commented on Aug 20, 2026

    @alpergundogdu
    ContributorAuthor

    Closing after reconciling this spec against current `main`.

    Warming works and is covered; the full RTT e2e is not worth its cost. The proxy-warming machinery landed in #1357/#1725 and its behavior is already tested where it matters:

    • Candidate selection / latency check (unit-tested): `proxy_warming_order` (no-op when the best holder is near, no-op when no candidate clears the margin, picks qualifying candidates nearest-RTT-first) and `failover_order` (holders-by-RTT, proxies-prepended, holders-only fallback), plus `retry_disposition` and region-ordering. This is the actual "route through the nearer node" decision.
    • Warming mechanism (e2e-tested in pieces): node-to-node pull-through fill+cache (`node_to_node_coalesce`), and DHT STORE-on-cache-insert (`run_republish_publishes_immediately_on_cache_insert`, `client_store_lands_record_at_server`).
    • Ranking is measured-RTT-only in code: `failover_order` drops `region_hint` on emitted proxy candidates, so a spoofed region cannot change the rank — enforced structurally, unit-covered.

    The only piece a standalone G-CLIENT-03 would add is tying the RTT-driven "far vs near" routing together end-to-end. That needs a new harness seam to make one node deterministically "far" (probe RTT is pure loopback wall-clock; no latency-injection seam exists, `RttMap` is unwired). Building that production-config seam for one integration test is low marginal value over the existing unit + partial-e2e coverage, so closing rather than carrying it as a High-priority gap.

    Doc-rot found and fixed alongside: the spec negative clause (client "speculative spend / leech budget" -> the proxy pull-leg RampPacer credit window) and a stale `discovery::proxy_warming_order` docstring ("uses only the first entry" / "default off", both false since #1725).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    kind:testprio:criticalprio:high

    Type

    No type

    Fields

    Priority

    None yet

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions