Home / reference / icechunk-rust
Icechunk Rust#
The Icechunk rust library is used internally by Icechunk Python. It is currently not designed to be used in standalone form.
- Icechunk Rust Documentation at docs.rs
We welcome contributors interested in implementing more Rust functionality!
WebAssembly (browsers)#
icechunk builds for wasm32-unknown-unknown with default-features = false. There it runs on the JavaScript event loop, with no Tokio runtime or threads:
- Async traits such as
Storagedo not requireSendfutures, so a backend can await JS promises (for examplefetch). Implement them with#[icechunk_storage::maybe_send_async_trait]instead of#[async_trait]; it keepsSendfutures on every other target. icechunk::rtruns tasks and timers on the JS event loop and blocking work (decompression, decoding) inline. Use a Web Worker to keep a page responsive with large repositories.zstd-syscompiles C code: build withclangandAR_wasm32_unknown_unknown=llvm-ar. Otherars write archives the wasm linker cannot index, and zstd silently goes missing at link time.- Garbage collection and expiration are not supported yet (they use Tokio timers).
The JavaScript package @earthmover/icechunk is built this way for browsers.