Repository navigation
Bound the fetches of the experimental ReaderExecutor by the request map, not by read_until - #125606
Conversation
…read_until` `read_until` now limits only what a window serves. A fetch stops at the end of the request-map run (holes up to `reader_executor_min_bytes_for_seek` are read through), and so does a held GET. Adds `ReaderExecutorBytesOutsideRequestMap`.
…em cache segment The segment fills only from its committed front, so the hole is read in any case; reading it in the same fetch saves a request.
|
Workflow [PR], commit [4a68db8] Summary: ✅
AI ReviewSummaryThe PR bounds experimental Missing context / blind spots
Findings❌ Blockers
Tests
Final VerdictStatus: ❌ Block — preserve bounded I/O for existing unmapped callers and cover the sparse/discarded-read case. The dismissed thread was neither reopened nor replied to; no duplicate inline review was posted. |
Without caches, the plan keeps the window's unserved bytes in memory, so the separate no-cache path is not needed.
Build profile diff (arm_release)Comparing ✅ No significant changes. Binary sizes
The official master build is compiled with Slowest function optimization changes (ThinLTO)Median per-function time ratio to the master baseline:
Compile time of recompiled translation units3251 translation units recompiled, 17100 s compile time in total, 3251 of them have a recent master baseline. |
…he default look-ahead
…end by binary search
|
I found an issue with The table is on the CREATE TABLE gap (k UInt64, v UInt64) ENGINE = MergeTree ORDER BY k
SETTINGS storage_policy = 's3', min_bytes_for_wide_part = 0;
INSERT INTO gap SELECT number, cityHash64(number) FROM numbers(1000000);
SELECT sum(v) FROM gap WHERE k < 20000 OR k > 900000
SETTINGS use_reader_executor = 1, reader_executor_use_long_connections = 1,
reader_executor_window_size = 131072, remote_filesystem_read_method = 'read';It returns the right sum ( |
With it on, two bugs fail tests: - `use_reader_executor` with `local_filesystem_read_method = 'mmap'` reads stale bytes of a rewritten same-size local file (`05055_backup_lock_file_non_atomic_backend`); fix in #113617. - `reader_executor_use_long_connections` sizes the held GET from the read position but opens it at the fetch start, so a fetch from a cache segment's committed front ends before the position: `ReaderExecutor: source ended` (`04513`, `05182`); fixed by #125606. `reader_executor_use_long_connections` and its dependency on `use_reader_executor` go with it. CI report: https://s3.amazonaws.com/clickhouse-test-reports/praktika.html?PR=106734&sha=09174651b0bd517f1371eb39e39355bb7d243811&name_0=PR PR: #106734 Co-Authored-By: Claude Opus 5.5 <[email protected]>
04327: turn off hole read-through, so a multi-buffer read of a Compact part does not read the chunks of other columns.
A column stream of a Compact part (the multi-buffer reader on object storage) gets a request map that spans the chunks of the other columns, so `DeliveredBytes` is less than `BytesFromSource`. The `reader_executor_min_bytes_for_seek = 0` workaround did not address it.
The experimental
ReaderExecutorcapped each fetch atread_until, the end of the current task. Nowread_untillimits only what is served. A fetch is bounded by the window and by the request map from #122250: it stops at the end of the map run that holds the position, and reads through holes up toreader_executor_min_bytes_for_seek. A held GET ends there too. A fetch that ends inside a filesystem cache segment continues to the bytes that the map still wants in that segment, because the segment fills only from its committed front.New counter
ReaderExecutorBytesOutsideRequestMap. Known limit: the map is per part, so readers that share a split part can fetch past their share; a per-reader map comes later.Related: #122250
Related: #115816
Changelog category (leave one):
🤖 Generated with Claude Code
Workflow [PR]
Sync PR [sync-upstream/pr/125606]
Version info
26.11.1.2231-master(included in26.11and later)