Tracking Issue: Remove spawn_io and spawn_blocking_io; hosts pass in every I/O provider
Maintainer antworten meist innerhalb von 1 Tag
Dieses Issue hat noch niemand übernommen.
Bewertung
- Schwierigkeit
- 5/5
- Geschätzter Aufwand
- Über eine Woche
- Anfängerfreundlichkeit
- 15/100
Rechercherichtung
This is a multi-step tracking issue, not a single edit; start by reading the Executor trait in vortex-io/src/runtime/mod.rs and the completion-based IoService / IoSource interface in vortex-io/src/request/mod.rs, which is the target shape. The first checkbox is the smallest slice: turn the std_file reader into an IoService provider that owns its blocking pool, then confirm no read-path code calls spawn_blocking_io and that existing vortex-io tests still pass. Done means spawn_io and spawn_blocking_io are gone from both Executor and Handle with every reader supplied by the host.
Vom Indexierungsmodell aus dem Issue-Text verfasst.
Beschreibung
This is a tracking issue for removing spawn_io and spawn_blocking_io from the runtime Executor trait (vortex-io/src/runtime/mod.rs), so that every byte source a scan reads is passed in by the host rather than driven by Vortex's runtime. Part of #9062.
Motivation
Executor has four methods, and two of them exist only because Vortex performs I/O itself: spawn_io for the object-store reader's async reads, and spawn_blocking_io for std::fs work in std_file, plus the JNI, Python and CUDA readers. A host with its own I/O stack has to route that work through its executor even when it would rather read through its own system. A fiber runtime such as ClickHouse's Silk, with one pinned thread per CPU and all I/O on io_uring, is the sharpest case: a blocking task on one of its threads stalls that CPU, and Vortex's own reads never reach its rings.
The V2 scan already reads through IoService / IoSource (vortex-io/src/request/mod.rs), which is completion-based and performs no I/O itself. Once every reader is a provider behind that interface, the runtime only has to run futures and CPU tasks.
Design
pub trait Executor: Send + Sync {
fn spawn(&self, fut: BoxFuture<'static, ()>) -> AbortHandleRef;
fn spawn_cpu(&self, task: Box<dyn FnOnce() + Send + 'static>) -> AbortHandleRef;
}
Each reader becomes an IoService implementation that owns whatever drives its I/O. The object-store provider owns its Tokio runtime, and the std::fs provider owns a blocking pool. A host supplies its own providers, or picks Vortex's. Filesystem listing and writes go the same way.
Driving the I/O is the host's job. A host that supplies a provider also runs whatever powers it, whether that's a Tokio runtime, a blocking pool or an io_uring completion loop. Vortex doesn't try to hide that, because it's specific to each engine. What Vortex owes the host is no hidden drivers: nothing on the read path spawns its own I/O tasks onto the host's executor and quietly relies on a waiting thread to poll them, the way the object-store reader's spawn_io tasks rely on DuckDB threads entering smol's executor today.
Steps
-
std_fileand object-store reads asIoServiceproviders that own their threads - JNI, Python and CUDA readers moved the same way
- Filesystem listing and writes off
spawn_blocking - V1 scan reads through
IoService, or V1 is retired, so nothing on the read path callsspawn_io - Remove
spawn_ioandspawn_blocking_iofromExecutorandHandle
Unresolved questions
- Whether writes belong behind the same provider interface as reads, or get their own.
Implementation history
- Vorherrschende Sprache
- Rust
- Sterne
- 3.2k
- Forks
- 239
- Ø Merge
- 1 T. 4 Std.
- Gemergte PRs (30 T.)
- 684
Entwicklungsumgebung
- Kein Dockerfile und keine Docker-Compose-Datei
- Hat eine Pull-Request-Vorlage
- Beitragsleitfaden lesen
Erste Schritte
- Lesen Sie das ganze Issue und danach den Beitragsleitfaden des Projekts.
- Schreiben Sie ins Issue, dass Sie es übernehmen — das erspart doppelte Arbeit.
- Forken Sie das Repository und arbeiten Sie in einem Branch.
- Öffnen Sie einen Pull Request, der die Issue-Nummer nennt.
Mehr aus vortex-data/vortex
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 70/100
vortex-data/vortex#12633 ·
Maintainer antworten meist innerhalb von 1 Tag
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 77/100
vortex-data/vortex#12628 ·
Maintainer antworten meist innerhalb von 1 Tag
-
Schwierigkeit 1/5 Unter einer Stunde Anfängerfreundlichkeit 88/100
vortex-data/vortex#12491 ·
Maintainer antworten meist innerhalb von 1 Tag
-
Fallible constructor for nested_case_whenEvtl. vergeben Ein verknüpfter Pull Request ist offen oder bereits gemergt. Offen
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 72/100
vortex-data/vortex#11425 ·
Maintainer antworten meist innerhalb von 1 Tag
-
Schwierigkeit 3/5 1-2 Tage Anfängerfreundlichkeit 67/100
vortex-data/vortex#12635 ·
Maintainer antworten meist innerhalb von 1 Tag
Alle Issues in vortex-data/vortex
Ähnliche Issues
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 65/100
marklauter/tsong#110 ·
-
docs enhancement
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 78/100
wasm-bindgen/wasm-bindgen#5503 · 1 Kommentar ·
Maintainer antworten meist innerhalb von 1 Tag
-
needs-triage
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 68/100
Maintainer antworten meist innerhalb von 1 Tag
-
marketing
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 85/100
Maintainer antworten meist innerhalb von 1 Tag
-
area: engine bug needs milestone
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 70/100
Mudcrab-Team/mudcrab#1197 · 1 Kommentar ·
Maintainer antworten meist innerhalb von 1 Tag