Repository navigation
Closed
Labels
app/mcpxPackage/app: mcpx (pkgs/ or apps/ in this repo)Package/app: mcpx (pkgs/ or apps/ in this repo)effort/mMedium: expected under 1 day of workMedium: expected under 1 day of workkind/featureNew feature or capability requestNew feature or capability requestpriority/normalOrdinary priority (the default)Ordinary priority (the default)source/design-architectFiled by the repo design architect jobFiled by the repo design architect jobstatus:donetask/triageQueue packet kind: verify, reproduce, and route this itemQueue packet kind: verify, reproduce, and route this item
Description
Phase 2 of design #1601 (mcpx client cache hints). Gated on Phase 1 (the pool deadline/scope plumbing). Design doc: files/designs/code-mcpx-client-cache-hints.md in the keep-the-four-repos-healthy goal workspace.
Scope
Make cacheScope real at the disk boundary and define stale behaviour on refresh failure.
- Plumb the pool's catalogue scope/deadline through
SetSchemasso the daemon registry can seed and save them. internal/daemon/registry.go:SaveCacheskips pools whose catalogue scope isprivate— a private catalogue is never written to the on-disk schema cache. Cache-file entries record deadline + scope; bumpcacheVersion(older files are already ignored on mismatch).loadCache: a public entry whose deadline has passed is seeded expired — the firstSchemas()re-reads instead of serving a days-old catalogue as warm.- Pool: when an expired modern entry's refresh fails,
Schemas()serves the stale entry and records the error; the entry stays expired so the next call retries. A failed first fetch is unchanged (error, timestamp unset — perRefreshSchemas' existing discipline). - Retire conformance gap
caching-private-no-cross-auth(internal/conformance/coverage_stateful.go).
Evidence (main 33a4e67, 2026-10-28)
Registry.loadCache/SaveCache(internal/daemon/registry.go~L249-285) persist and re-seed every catalogue; no TTL is applied toFetchedAt, no scope is recorded.- Spec (register PG-10):
private= reuse only within the same authorization context; MUST NOT be shared across contexts. A restarted daemon cannot prove its callers are the same context — hence never persist (decision recorded on design(mcpx): honour upstream ttlMs and cacheScope — the pool catalogue cache gets a freshness deadline and a scope #1601).
Acceptance
- Test: a private-scoped catalogue is absent from the saved cache file; a public one is present with deadline + scope.
- Test: a public entry past its deadline at load is re-read on first
Schemas(), not served as fresh. - Test: expired entry + failing upstream → stale catalogue served, error recorded, next call retries the refresh.
- Test: failed first fetch still errors and leaves the cache unset.
caching-private-no-cross-authretired; pkgs/mcpx tests pass in CI.
Out of scope
Register truth-up and the list_changed verification test (Phase 3); background revalidation (declined on #1601 — synchronous refresh is the recorded decision).
Metadata
Metadata
Assignees
Labels
app/mcpxPackage/app: mcpx (pkgs/ or apps/ in this repo)Package/app: mcpx (pkgs/ or apps/ in this repo)effort/mMedium: expected under 1 day of workMedium: expected under 1 day of workkind/featureNew feature or capability requestNew feature or capability requestpriority/normalOrdinary priority (the default)Ordinary priority (the default)source/design-architectFiled by the repo design architect jobFiled by the repo design architect jobstatus:donetask/triageQueue packet kind: verify, reproduce, and route this itemQueue packet kind: verify, reproduce, and route this item
Activity
developing-today commentedon Oct 28, 2026
CODE-629
dezren39 commentedon Oct 28, 2026
🤖 Agent note · filed
dezren39 commentedon Oct 28, 2026
Picked up and parked by Lane B queue worker (queue task 1690, triage of #1603).
Dependency gate unmet — re-checked fresh: Phase 1 #1602 is still OPEN (its own triage was filed 2026-10-28T05:37Z; no implementing PR exists), and on current main (63ba170) there is no cacheScope plumbing to build on: no
cacheScope/CacheScopeininternal/poolorinternal/mcpclient, andPool.SetSchemas(pool.go:892) still takes no scope/deadline — it is the pre-existing disk seed this phase would extend once Phase 1 lands.Per the packet, this triage does not re-scope around the gate. Resume condition: #1602's Phase 1 plumbing merged (ttlMs/cacheScope surfaced in mcpclient + pool catalogue expiry), then confirm the Phase 2 scope against the as-built plumbing and enqueue the implementation packet. Parking 1 hour.
123 remaining items
dezren39 commentedon Oct 28, 2026
🤖 Agent note · picked up
compare with the records(the last queued check at the previous park). Merging per the task's resume brief.queue/1852-1603-cachescopedezren39 commentedon Oct 28, 2026
🤖 Agent note · done
compare with the records, conformance clients/servers, and the mcpx test job. The PR implements every mcpx: Phase 2 of #1601 — cacheScope at the disk boundary: private never persists, expired seeds expired, stale on refetch error #1603 acceptance item (private never persisted, deadline+scope recorded with cacheVersion 6, past-deadline seeds expired, stale-on-refetch-error with retry,caching-private-no-cross-authretired), so this issue is closed as complete. Phase 3 (mcpx: Phase 3 of #1601 — register truth-up, list_changed invalidation test, and nix#200 evidence #1604, task 1691) is now ungated.