Repository navigation
Conversation
tamirms
force-pushed
the
tamirms/events-fetch-arenas-fanout
branch
from
October 5, 2026 13:36
e3e8c07 to
918ee23
Compare
Hot fetch: the batched read's options are built once, at open; the key list is cut from one buffer; each pinned value is read once; and the values are copied into one arena per batch instead of one allocation each. A fetch now makes two heap allocations per event id, both inside grocksdb, which TestHotStore_FetchEventsAllocationBudget pins. Cold fetch: payload copies go into arenas instead of one allocation each. A cold reader with a concurrency above one makes packfile's ReadItems call back from several goroutines, so each callback takes an arena from a per-call pool for its copy and no two share one. A single shared arena behind a lock made a fetch with 8 reads in flight 38% slower; with the pool it costs what the unpooled copies did. With warm caches, a 1,000-event page now makes 2,010 allocations instead of 4,008 hot and about 50 instead of 1,025 cold, and eight concurrent fetchers move 10% more hot pages and 17% more cold pages per second, with cold p99 21% lower. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01JCzMKKrK3NstGKvaxsHhL2
tamirms
force-pushed
the
tamirms/events-fetch-arenas-fanout
branch
from
October 5, 2026 15:58
918ee23 to
c3db605
Compare
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.
What
Why
TestHotStore_FetchEventsAllocationBudgetpins. A cold 1,000-event page makes about 50 instead of 1,025.Split out of #968. The cold read concurrency this PR used to set is now #1083, in the getEvents stack.
Known limitations
🤖 Generated with Claude Code