feat(io): route FileIO through configured runtime#2602
Open
geoffreyclaude wants to merge 3 commits into
Open
Conversation
Author
This was referenced Jun 8, 2026
342667f to
467cec5
Compare
467cec5 to
481b283
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.
Which issue does this PR close?
Runtimesupport enhancement #1958, feat!(runtime): Support custom Runtime in Catalog #2308.What changes are included in this PR?
This PR routes file storage work through the IO handle of an explicitly configured Iceberg
Runtime.The original runtime-segregation discussion in #1945 proposed configuring an OpenDAL executor directly. Since then, #2308 introduced Iceberg's
Runtimeabstraction and catalog-level runtime plumbing. This PR builds on that newer API and applies runtime dispatch at theFileIO/Storageboundary instead, so concrete storage implementations remain runtime-agnostic and theStoragetrait is unchanged.When a runtime is configured on
FileIO, the raw storage backend is kept unchanged and wrapped in a private runtime-aware adapter. The adapter dispatches storage operations, reader creation, byte-range reads, writer creation, writes, and close operations ontoruntime.io().Catalogs now propagate their configured runtime into the
FileIOinstances they build, and loadedTablevalues can be rebound withTable::with_runtimeso object-cache reads use the same runtime-awareFileIO. The DataFusion catalog-backed provider also has runtime-aware constructors, so table loads can use the runtime-aware path while scan streams continue to be polled by DataFusion as before.This deliberately does not change scan partitioning, eager file planning, or the DataFusion physical plan shape.
Thanks to @toutane for the preliminary work and discussion around runtime-aware Iceberg/DataFusion execution that helped shape this direction.
Disclosure: this PR was implemented with assistance from Codex and reviewed before submission.
Are these changes tested?
cargo fmt --checkcargo test -p iceberg test_file_io_with_runtime_routes_storage_operations --lockedcargo test -p iceberg file_io --lockedcargo test -p iceberg-datafusion test_catalog_backed_provider --lockedcargo check -p iceberg -p iceberg-catalog-rest -p iceberg-catalog-glue -p iceberg-catalog-hms -p iceberg-catalog-s3tables -p iceberg-catalog-sql -p iceberg-storage-opendal -p iceberg-datafusion --lockedcargo public-api -p iceberg --all-features -ss | diff - crates/iceberg/public-api.txtcargo public-api -p iceberg-datafusion --all-features -ss | diff - crates/integrations/datafusion/public-api.txt