Skip to content

Count the fast store toward presence when the slow store is read-only - #2959

Merged
MarcusSorealheis merged 5 commits into
TraceMachina:mainfrom
amankrx:fix/fast-slow-has-read-only-slow
Oct 19, 2026
Merged

MarcusSorealheis merged 5 commits into
TraceMachina:mainfrom
amankrx:fix/fast-slow-has-read-only-slow

Conversation

@amankrx

@amankrx amankrx commented Oct 19, 2026 •

Copy link
Copy Markdown
Member

What and why

FastSlowStore::has_with_results answers from the slow store alone, so a blob only the fast store holds is re-uploaded to the slow one. With slow_direction: read_only (or get) the slow store never receives uploads: the fast store is the only place a new blob can be, yet presence skipped it. Clients were told to upload blobs they had already stored, and a reader that missed its own fast tier was told the blob did not exist.

Across instances this matters when the fast store is shared: on a three-pod CAS with an lz4 compression tier over one backend in front of read-only raw shards, every blob stored after the switch was missing on the other two pods. A per-instance fast tier (memory, local filesystem) still answers only for what that instance stored.

With a read-only or get-only slow store the fast store is now checked first and the slow store is asked about the misses only. A writable slow store keeps the old behaviour.

How was this verified?

Three tests in fast_slow_store_test.rs: read-only and get-only slow stores find an upload only the fast store holds and an older blob only the slow store holds; a writable slow store still reports a fast-only blob missing. On a bed, fresh uploads to one CAS pod were missing on the other two before the change and present after it.

Risk

Low: the new branch runs only when the slow store is read-only or get-only, where nothing is ever re-uploaded to it.

AI assistance

An agent drafted the change and I reviewed every line.

@vercel

vercel Bot commented Oct 19, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
nativelink Ready Ready Preview Oct 19, 2026 8:03pm UTC
nativelink-aidm Ready Ready Preview Oct 19, 2026 8:03pm UTC

Request Review

Comment thread nativelink-store/src/fast_slow_store.rs Resolved
Comment thread nativelink-store/src/fast_slow_store.rs Resolved
Comment thread nativelink-store/src/fast_slow_store.rs Resolved
Comment thread nativelink-store/src/fast_slow_store.rs Resolved

@MarcusSorealheis MarcusSorealheis left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@MarcusSorealheis
MarcusSorealheis merged commit bd87f4d into TraceMachina:main Oct 19, 2026
32 checks passed

This branch was successfully deployed

2 active deployments
Preview – nativelink — 85f17ec8 Deployed Oct 19, 2026 by vercel[bot]
Preview – nativelink-aidm — 85f17ec8 Deployed Oct 19, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants