Repository navigation
Parallelize listing of globbed s3 table function paths - #107567
alexey-milovidov wants to merge 149 commits into
Conversation
Listing files for the `s3` table function with a glob was a single serial stream of `ListObjectsV2` requests paginated by a continuation token, bound by the per-request latency of S3 (~0.1-0.3s). This dominates queries over buckets with many objects (issue #65572; an earlier attempt was #66504). List the matching files in parallel by walking the "directory" tree formed by the `/` delimiter: worker threads list different common prefixes concurrently, and subtrees that cannot contain a matching key are pruned during the walk, so for hierarchically partitioned layouts fewer objects are fetched, not merely listed in parallel. Controlled by the new setting `s3_list_object_parallelism` (default `1`, the previous serial behavior). Recursive globs (`**`) keep serial listing. Correctness is guaranteed by the existing per-file `RE2::FullMatch`, so the directory pruning only needs to be conservative. Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>
|
Workflow [PR], commit [6b93d30] Summary: ❌
AI ReviewSummaryAdds opt-in parallel listing for globbed S3 paths, using delimiter traversal and keyspace splitting, with adaptive recursive listing for sparse directories. One correctness blocker remains: parallel listing uses current-version metadata when reading an explicitly selected historical object version, which can silently omit rows. Listing output was traced through local reads and their full-key filtering, archive expansion, cluster task distribution, and the three sampling/inference consumers that explicitly retain serial ordering. The version mismatch affects metadata consumers before the historical object is read. Missing context / blind spots
Findings❌ Blockers
Tests
Final VerdictStatus: ❌ Block Preserve version-specific metadata on the parallel path and add regression coverage proving historical reads remain independent of listing parallelism. |
s3 table function paths
The previous commit parallelizes hierarchical globs by walking the '/' tree, but a single big flat directory still lists serially (S3 pagination within a prefix is sequential). Such directories are common when files are named by hash/UUID, e.g. `musicbrainz/mlhdplus-complete/<uuid>.txt.zst` (~600k files in one prefix). When a listed prefix is truncated but has no sub-directories, split it by keyspace: tile its remaining range into contiguous `(start_after, end]` sub-ranges and list them concurrently. Boundaries are derived from the byte alphabet observed in the listed page (so the split adapts to the actual keys, e.g. hex for UUIDs). Because the sub-ranges are contiguous they tile the interval with no gaps — a key whose byte is absent from the sampled alphabet still falls into the range that brackets it — so the split is complete regardless of the key distribution or character set. This avoids the fragility of the earlier attempt #66504, which used fixed split points assuming a uniform distribution and a fixed character set. Measured on `musicbrainz/mlhdplus-complete` (594415 flat files, real S3, ~75ms/list-request): listing drops from 37.6s to 3.7s (~10x) with identical results (same count, no duplicates, identical path checksum). Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>
…sions Testing the flat-directory keyspace split across many public datasets revealed two cases where parallel listing was slower than serial: - Keys that share a long common prefix (e.g. `gharchive/original/2015-..`, `wikistat/original/pageviews-..`): the byte alphabet cannot divide them, so the split produced one full bucket plus a fan of empty boundary probes (pure overhead). Now a single cheap probe (one `ListObjectsV2` after the current bucket) checks whether any key exists beyond it; if not, the range is paginated serially with no wasted probes. - Multi-level splitting compounded the empty-probe overhead with no benefit for such keys. The split is now a single level (the recursion gave nothing for uniformly distributed keys — they are already balanced after one fan-out — and only hurt clustered keys). The number of boundaries is also capped. Uniformly distributed keys (hashes/UUIDs) still get the full speedup (`musicbrainz/mlhdplus-complete`, 594415 files: ~9-10x), while clustered keys now match serial instead of regressing. Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>
The probe that decides whether a flat directory can be usefully split was evaluated on every page of a serially-paginated range, not once. For a directory whose keys share a common prefix (which is paginated serially), this issued one wasted probe request per page — roughly doubling the number of requests and making parallel listing ~50% slower than serial on `gharchive`/`wikistat` (~100k files each). Probe only on the first flat page; once a range is decided to be unsplittable, paginate it serially without probing again. Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>
Performance comparisonMeasured against real S3 ( Big flat directory, uniformly distributed keys — the target case (issue #65572)
(Plateaus at ~16 because the keyspace is split one level by the hex alphabet → ~16 concurrent sub-ranges.) Other shapes (serial vs. parallelism = 16)
Clustered keys (a long shared prefix) cannot be divided by keyspace; the one-shot probe detects this and paginates serially, so parallel matches serial rather than regressing (the small differences here are within run-to-run S3 noise, which I measured at ±10–20%). Correctness sweepIn addition, parallel vs. serial were checked to be byte-identical (count + path checksum) on a range of small/medium datasets — Caveats
|
…mbers Adding the `list_object_parallelism = 1` default member initializer made the implicit default constructor of `StorageObjectStorageQuerySettings` non-trivial, so `clang-tidy`'s `cppcoreguidelines-pro-type-member-init` began requiring every member to be initialized and failed the `Build (arm_tidy)` job. Give all members explicit default initializers; every call site uses designated aggregate initialization, so behavior is unchanged. Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>
…ng-slash globs The parallel glob listing walk pruned every `CommonPrefixes` entry whose component depth equalled the glob's. But an object whose key itself ends with `/` (a directory marker such as `root/dir/`, as created by some S3 tools) is returned by `ListObjectsV2` only as a `CommonPrefixes` entry when its parent is listed, and as a `Contents` entry when its own prefix is listed. For a glob like `root/*/` such a marker is accepted by `RE2::FullMatch`, so serial listing returned it while the parallel walk dropped it, making `s3_list_object_parallelism > 1` produce an incomplete result set. `makeShouldDescendPredicate` now descends one extra level into a fully-matching common prefix when the glob ends with `/`, so the marker object is surfaced from `Contents`. Behavior is unchanged for globs that do not end with `/`. Move `splitPathComponents` and `makeShouldDescendPredicate` into a dedicated `ParallelListingGlobPredicate` translation unit next to the `ObjectStorageParallelListingIterator` they serve, so the predicate can be unit-tested, and add a `gtest` regression case `DirectoryMarkerMatchesTrailingSlashGlob`. Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>
…ry buckets Flat keyspace splitting lists a big flat "directory" by resuming strictly after an arbitrary key (`StartAfter`) with an empty `Delimiter`. S3 Express / directory buckets reject `StartAfter` and only allow the `/` delimiter, so with `s3_list_object_parallelism > 1` an otherwise serial glob listing could turn into a `ListObjectsV2` error as soon as a flat range was probed or split. Gate keyspace splitting on a new `IObjectStorage::supportsListingKeyspaceSplit` capability (false by default; `S3ObjectStorage` returns `!client->isS3ExpressBucket`). When disabled, a flat directory is paginated serially while the hierarchical delimiter walk — which uses only the `/` delimiter and continuation tokens, both supported by directory buckets — stays parallel. Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>
`clang-tidy` flagged `compare`-based prefix/suffix checks (`modernize-use-starts-ends-with`) and disregarded `snprintf` return values (`cert-err33-c`) in `gtest_object_storage_parallel_listing`; switch to `starts_with`/`ends_with` and `fmt::format`. Add a test that a big flat directory listed with keyspace splitting disabled is still complete yet never issues a `StartAfter` request or an empty `Delimiter`, at parallelism 1/4/16 (and that, with splitting enabled, the same directory is indeed split — so the gate is meaningful). CI report: https://s3.amazonaws.com/clickhouse-test-reports/json.html?PR=107567&sha=8d2e9128969499945fbc99a6107e44c5754ebaca&name_0=PR&name_1=Build%20%28arm_tidy%29 Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>
The flat-directory tests derived hex names as `hex[x & 0xf]` from an LCG, but the low nibble of an LCG cycles with a period of at most 16 independent of the seed's high bits, so every `i` sharing `i mod 16` produced the same name. Each "big flat directory" therefore collapsed to ~16 distinct keys and the keyspace-split path was never taken (completeness still held, but only trivially). Add a `splitmix64` `hexName` helper that yields well-distributed unique names with a uniform first byte, so a flat directory is genuinely split — verified by the new gate test, whose `requests_with_start_after`/`requests_with_empty_delimiter` counters are now positive when splitting is enabled. Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>
…uzzer The Stress test reported `S3_ERROR No such key thrown` attributed to `04340_s3_parallel_flat_listing.sh`. The failing read was of a key `test_<db>/04340/data\xef\xbf\xbd.csv` — the UTF-8 replacement character where `_NN` should be — i.e. a mutation of this test's own path literal `http://localhost:11111/test/<db>/04340/data_NN.csv`, which the stress query fuzzer harvests and replays into the shared bucket. The test's `*.csv` glob then lists that corrupt sibling and the read of its body fails with `No such key`. This is unrelated to the parallel-listing feature: it reproduces identically with `s3_list_object_parallelism = 1` (the pre-existing serial code path), and in the failing run the only two `No such key` occurrences in the whole stress session were this test's serial and parallel queries. Anchor the read glob to `data_??.csv` instead of `*.csv`. This narrows both the S3 listing prefix (to `.../04340/data_`) and the matching regexp to the exact file shape, so a fuzzer-injected sibling with a mutated name is never listed or read. In a clean environment it lists the same 40 files, so the reference is unchanged. CI report: https://s3.amazonaws.com/clickhouse-test-reports/json.html?PR=107567&sha=1db36fa35a05e948591fbc96d1039427e0a25839&name_0=PR&name_1=Stress%20test%20%28arm_tsan%29 Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>
Re-merged
|
The
|
The `Hung check` reds on this PR are a real, PR-specific deadlock in the new `ObjectStorageParallelListingIterator`, not the generic flake (CI mis-links them to a name-only matcher issue). The consumer (e.g. the query's main thread inside `getPathSample`, called from the `StorageObjectStorage` constructor during query analysis) blocks in `popBatch` waiting on `result_available`, whose predicate only becomes true on `finished` or `stop`. Nothing observed query cancellation: when the query is killed (the hung dump shows `is_cancelled = 1`, which is `QueryStatus::isKilled`) the wait was never interrupted, and the destructor — the only place that sets `stop` — could not run because the constructor frame was parked in `popBatch`. The result was an unbounded hang ignoring `max_execution_time` and `KILL QUERY`. Make the parallel listing cancellation-aware, mirroring the serial path which is bounded by per-request timeouts: - `popBatch` now waits in bounded slices (`wait_for`) instead of indefinitely, and on each timeout calls a `check_cancellation` hook. Query cancellation does not notify our condition variables, so polling is required to observe it. On cancellation the hook throws the proper exception (`TIMEOUT_EXCEEDED` / `QUERY_WAS_CANCELLED`); `popBatch` sets `stop` and wakes the workers before propagating, so the exception unwinds the consumer and the iterator is destroyed. - `GlobIterator` builds the hook from `Context::getProcessListElementSafe` → `QueryStatus::throwIfKilled`. It is empty in non-query contexts (e.g. unit tests). - Worker threads now attach to the owning query's thread group via `ThreadGroupSwitcher`, so listing memory is accounted to the query and in-flight listing requests observe its cancellation (the same as the serial listing path). - With the consumer unblocked and `stop` set promptly, `~ObjectStorageParallelListingIterator`'s `pool.wait()` is bounded by a single (already bounded) listing request rather than hanging. Adds a deterministic `gtest` (`CancellationUnblocksBlockedConsumer`) that reproduces the consumer-blocked-on-a-stalled-producer state and asserts that cancellation interrupts the wait and the iterator destructs without blocking. Reports: - https://s3.amazonaws.com/clickhouse-test-reports/json.html?PR=107567&sha=607899a8a70ded0637ea3dd950b8ad7d401a42ee&name_0=PR&name_1=Stress%20test%20%28arm_ubsan%29 - https://s3.amazonaws.com/clickhouse-test-reports/json.html?PR=107567&sha=607899a8a70ded0637ea3dd950b8ad7d401a42ee&name_0=PR&name_1=Stress%20test%20%28arm_asan_ubsan%2C%20s3%29 Co-Authored-By: Claude Opus 4.8 <[email protected]>
Pushed the cancellation-aware fix for the
|
`ListObjectsV2` may return an empty page with `IsTruncated` set, which does not prove the directory marker is absent. Keep paginating such a range until an entry settles the question, and add a regression test. Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
🕵 Merged @groeneai, investigate the failure: https://s3.amazonaws.com/clickhouse-test-reports/praktika.html?PR=107567&sha=5934381d8e1ea5914cf0d207a08e0bbc14cfe647&name_0=PR&name_1=Stress%20test%20%28amd_msan%29 ( |
|
The failing build predates #127834. Workflow run 40983708219 was created at 01:05Z, about 7 hours before #127834 was merged (08:05Z). It tested On "still happening after the merge": CIDB has three The new head |
…ce split valid UTF-8 `splitWouldHelp` incremented the byte at the split position and `splitFlatRange` appended arbitrary sampled bytes to build slice boundaries. Both are sent as `StartAfter`, so a key with a multi-byte character at the split position (e.g. `p/é.csv`) produced an incomplete sequence (`p/\xC4`) or a lone continuation byte, which S3-compatible storages such as OpenStack Swift reject with `InvalidArgument`. Split only at ASCII bytes: probe only when the byte at the split position is below `0x7F` (so its successor is ASCII and the prefix ends on a character boundary), and form slice boundaries only from ASCII bytes. Keys with non-ASCII bytes at the split position are still covered by the last slice, which inherits the range's own upper bound. Add a unit test that validates every outgoing `StartAfter` for names beginning with non-ASCII characters and ASCII-leading names with a non-ASCII suffix. Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
🕵 Merged |
The delimited walk issues at least one request per descended sub-directory. For a sparse layout such as `root/p=*/data.csv` with one file per `p=...`, that is up to `page_size` times more requests than the serial recursive listing (10010 instead of 10 for 10000 directories), which no parallelism can compensate. When the first page of a fresh hierarchical range descends into at least 16 sub-directories and prunes none of them, `probeRecursiveListing` lists one recursive (delimiter-free) page over the same interval. If that page spans at least 8 sub-directories (or covers the whole range), the range is listed recursively from there on; otherwise the delimited walk goes on, having spent one extra request. This covers ordinary file globs and trailing-slash globs alike. It is disabled for a `_tags` scan, which fetches tags for every listed object, and for unordered storages. Added request-count regressions for both sparse layouts, and checks that dense and pruned layouts keep the delimited walk. Co-Authored-By: Claude Opus 5.5 <[email protected]>
…llelism Resolved conflicts with the new `s3_skip_hidden_files` setting: keep both `list_object_parallelism` and `skip_hidden_files` (with default member initializers), and keep `hidden_check_prefix_size` while the listing iterator is still created later in `GlobIterator` (serial or parallel).
|
🕵 Merged On the previous head
There are no unresolved review threads. |
…llelism Conflict in `IObjectStorage.h`: keep both the `ObjectStorageListResult` struct from this branch and the `RemoteHostFilter` forward declaration from master. Co-Authored-By: Claude Fable 5.2 <[email protected]>
The 26.11 release branch was cut without this setting, and master is now 26.12, so the settings changes history entry in the declaration must name 26.12. Co-Authored-By: Claude Fable 5.2 <[email protected]>
After merging master, `Aws::String` is no longer `std::string`, so the values taken from the `ListObjectsV2` result (`GetKey`, `GetETag`, `GetPrefix`, `GetNextContinuationToken`) need an explicit conversion to `String`, the same way the other listing code in `S3ObjectStorage.cpp` does it. Co-Authored-By: Claude Fable 5.2 <[email protected]>
|
🕵 Merged Two follow-up commits were needed for the merged tree:
Verified locally on the merged tree: |
|
I measured Setup: this PR's CI build of
Only the last glob gets faster; there the walk prunes 11 of every 12 months. OpenAQ and Ookla. The next table uses the same binary with only that comparison changed to
Each OpenAQ year then fits in one recursive page, so the walk runs at about serial speed instead of up to 3.3x slower. The cost is one more round trip wherever the probe fails. For the NOAA. After the switch to recursive listing, web/store loses here, unlike in your run, because each parallel worker opens its own connection. From this VM, a new connection to eu-central-1 takes about 200 ms. At p=16 the query opened 16 connections (3.2 s in total), while serial listing opened 1. For reference, the flat case is faster here too: musicbrainz (594,415 files) takes about 98 s serially and 42 s at p=16. The VM is CPU-bound at p=16 (3.7 of 4 cores busy), which limits the gain to 2.3x rather than your 10x. I did not rebuild from source or run the gtests. Request-count assertions for small trees may need updating along with the constant. How the threshold-2 binary was made, and the runs
|
alexey-milovidov
left a comment
There was a problem hiding this comment.
Sophisticated, but well-contained. LGTM.
…llelism Resolved the conflict in `StorageObjectStorageSource.cpp`: keep both the `config.h` include from `master` and the `<algorithm>` include from this branch. Co-Authored-By: Claude Fable 5.2 <[email protected]>
`clang-tidy` now enforces `modernize-use-nodiscard`, and the `arm_tidy` builds failed on the listing methods this branch adds to `IObjectStorage` and on `ListRange::isPastEnd`. https://s3.amazonaws.com/clickhouse-test-reports/praktika.html?PR=107567&sha=d351da9243cfeb249b2b2f9910d806a02a158616&name_0=PR&name_1=Build%20%28arm_tidy%2C%201%2F4%29 #107567 Co-Authored-By: Claude Fable 5.2 <[email protected]>
Address review: `probeRecursiveListing` ran only for a page with at least 16 unpruned sub-directories, so partitioned layouts with few values per level (e.g. `type=*/year=*/quarter=*/`) never reached it and were listed with one request per leaf directory. Measured on real S3, that was up to 9 times slower than the serial listing. Lower `MIN_CHILDREN_FOR_RECURSIVE_PROBE` to 2 and add unit tests for such layouts. #107567 (comment) Co-Authored-By: Claude Fable 5.2 <[email protected]>
|
🕵 @snelheidai, thanks for the measurements. Applied in
Not changed in this pass:
These three cost extra requests or connections but do not affect the results, and the setting is off by default ( Also in this push: merged |
| for (const auto & object : result.GetContents()) | ||
| { | ||
| ObjectMetadata metadata{ | ||
| .size_bytes = static_cast<uint64_t>(object.GetSize()), |
There was a problem hiding this comment.
[Blocker] Preserve the selected object's version when attaching listing metadata
Unlike S3IteratorAsync, this path always attaches the current version's ListObjectsV2 metadata, even when uri.version_id selects an older version. That bypasses the version-aware HEAD in StorageObjectStorageSource::createReader and uses the current size to bound the historical read.
For example, let the current data.csv contain 9\n (2 bytes), and version old contain 1\n2\n (4 bytes). Reading s3('.../data*.csv?versionId=old', ..., 'CSV', 'x UInt64') with s3_list_object_parallelism=8 and prefetch enabled bounds the old-version read to 2 bytes, silently returning [1] instead of [1,2]. If the current version is empty, s3_skip_empty_files=1 skips the non-empty historical version entirely. _size, _etag, and _tags also describe the wrong version.
Mirror the serial iterator's reads_explicit_version branch: return the key with metadata unset when uri.version_id is non-empty, allowing the existing version-aware metadata request to run. Add a focused stateless regression comparing parallelism 1 and 8 for historical versions with different sizes; the HTTP mock in 05814_s3_explicit_version_size_from_version_metadata.sh can be reused.
AI review of a later commit does not approve the PR, see the AI Review comment.
|
📊 Cloud Performance Report
This PR has no regressions or improvements in this comparison. Only clickbench Q31 was flagged, at +10.6% (240 ms vs 217 ms), and it stays not_sure: master's timings for this query changed character after 2026-11-23 (Q10 and Q30 are affected too), and its history is noisy. The PR adds an opt-in parallel listing path for globbed S3 reads, behind the new setting s3_list_object_parallelism, which defaults to 1 and keeps the old serial listing. Q31 reads a local table and never calls that code, so the shift is not plausibly caused by this change. clickbenchFlagged queries (1 of 43)
Change = percent below ×2; the ratio of medians (×N faster/slower) beyond, where percent understates the scale. q-value = BH-FDR adjusted p; smaller is stronger evidence. MIRAI flags a query when q < fdr_q (default 0.10) — the value the verdict is based on. tpch_adapted_1_official🟢 No significant changes Debug info
|
Speeds up listing files over globbed paths on S3-compatible object storage (the
s3ands3Clustertable functions, theS3table engine, and theirgcs,cosn,ossaliases), in two complementary ways. The listing was a single serial stream ofListObjectsV2requests paginated by a continuation token, bound by the per-request latency of S3 (~75 ms measured againstclickhouse-public-datasets); this dominates queries over buckets with many objects. An earlier attempt (#66504) used speculative keyspace splitting with fixed split points assuming a uniform key distribution and a fixed character set, and was closed as fragile.Controlled by the new setting
s3_list_object_parallelism(default1= the previous serial behavior).1. Hierarchical layouts — walk the "directory" tree formed by the
/delimiter with several worker threads in parallel, pruning subtrees that cannot contain a matching key (so for partitioned layouts likeyear=*/month=*/fewer objects are fetched, not merely listed in parallel). Recursive globs (**) keep serial listing.2. Big flat directories (e.g. files named by hash/UUID —
musicbrainz/mlhdplus-complete/<uuid>.txt.zst, ~600k files in one prefix) — when a listed prefix is truncated but has no sub-directories, split it by keyspace: tile the remaining range into contiguous(start_after, end]sub-ranges listed concurrently, with boundaries derived from the byte alphabet observed in the listed page. Because the sub-ranges are contiguous they tile the interval with no gaps — a key whose byte is absent from the sampled alphabet still falls into the range that brackets it — so the split is complete regardless of the key distribution or character set. The split is a single level and is probe-gated: before splitting, one cheapListObjectsV2checks whether any key exists beyond the current bucket; if not (keys share a common prefix, e.g.pageviews-YYYYMMDD-HH), the directory is paginated serially instead of issuing a fan of empty boundary probes. This is the robust counterpart to #66504 — it never regresses for clustered keys. On S3 Express / directory buckets — which rejectStartAfterand only allow the/delimiter — keyspace splitting is disabled automatically (detected viaisS3ExpressBucket), so flat ranges are paginated serially while hierarchical layouts are still listed in parallel. Directory buckets also return listings in no particular order (IObjectStorage::listsKeysInLexicographicOrder), so every order-dependent shortcut (the end bound of a widened walk, the budget-trim resume, the single-page directory-marker stop) is disabled for them and ranges are paginated by continuation tokens only.Correctness of glob matching is guaranteed by the existing per-file
RE2::FullMatch, so the directory pruning only needs to be conservative.Measured against real S3 (
clickhouse-public-datasets, ~75 ms/list-request) across ~16 datasets — all return identical results (same count, no duplicates, identical path checksum), serial vs parallel:musicbrainz/mlhdplus-complete(594415 files): 37s → 3.7s (~10x).wikistat(97529) /gharchive(100091): probe sends them serial; parallel matches serial (no regression).web/store: ~2.5x (bounded by its small directory count; scales toward the parallelism factor for larger trees).nyc-taxi,ontime,hits/native,sensors,tranco,youtube,adsblol,bluesky, …): correct, no regression.A unit test (
gtest_object_storage_parallel_listing) asserts every key is produced exactly once across parallelism 1–64, including adversarial cases (bytes outside the sampled alphabet, shared long prefixes, boundary keys, mixed hierarchical+flat). Stateless tests (04339_s3_parallel_glob_listing,04340_s3_parallel_flat_listing) verify parallel and serial listing return identical results.Closes: #65572
Related: #66504
Changelog category (leave one):
Changelog entry (a user-readable short description of the changes that goes into CHANGELOG.md):
Added a setting
s3_list_object_parallelismto list globbed paths on S3-compatible object storage in parallel. It applies to reads through thes3ands3Clustertable functions, theS3table engine, and theirgcs,cosn,ossaliases. Hierarchically partitioned layouts are listed by walking the tree of common prefixes concurrently; a single big flat directory is listed by splitting its keyspace into contiguous sub-ranges. This speeds up queries over buckets with many objects (e.g. ~10x for a directory of 600k files).Workflow [PR]
Sync PR [sync-upstream/pr/107567]