You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit 83e1aad
Browse filesBrowse the repository at this point in the historyBrowse files
8.**WASM decompression preload** prevents initialization failures under slow network
307
311
9.**Cache budget division** for multi-file: consider fewer large files over many small ones
308
312
10.**BufferedIterableSource** (10s, 300MB) smooths network latency for playback
313
+
11.**Read coalescing** (`BatchingReadable`): merges `read()` calls arriving in the same microtask tick (gap <64KiB, ≤4MiB span) before they reach `CachedFilelike`
309
314
310
315
## Common Pitfalls
311
316
- Server missing `Accept-Ranges: bytes` header → fails at open
Coalescing layer between `McapIndexedReader` and `CachedFilelike`. Accumulates `read()` calls that arrive within the same microtask tick, sorts them by offset, and merges those whose gap is `< 64 KiB` (up to a `4 MiB` merged span) into a single underlying read — cutting HTTP Range requests for MCAP files with many small chunks.
317
+
318
+
### Notes
319
+
- Single-member groups are forwarded zero-copy; multi-member groups are sliced (copied) per request so a small result does not pin the full merged buffer in memory.
320
+
- Only coalesces reads that are concurrently pending in the same tick. `McapIndexedReader` issues reads strictly sequentially (each awaited before the next), so real coalescing depends on concurrent access — validate request-count reduction empirically for a given workload.
321
+
322
+
---
323
+
296
324
## Multi-File Cache Budget Distribution
297
325
298
326
When `MultiIterableSource` handles multiple remote URLs:
@@ -321,5 +349,5 @@ This means:
321
349
|`packages/suite-base/src/util/BrowserHttpReader.ts`| HTTP Range request implementation |
322
350
|`packages/suite-base/src/util/FetchReader.ts`| Streams API EventEmitter adapter |
323
351
|`packages/suite-base/src/util/RequestQueue.ts`| Global concurrency limiter (10 max) |
0 commit comments