Show HN: Typed-arrow – compile‑time Arrow schemas for Rust
6 days ago
- #Rust
- #Data Processing
- #Arrow
- typed-arrow provides a strongly typed, compile-time way to declare Arrow schemas in Rust.
- Maps Rust types directly to arrow-rs typed builders/arrays and arrow_schema::DataType with zero runtime cost.
- Performance: Monomorphized builders/arrays with zero dynamic dispatch; avoids runtime DataType matching.
- Safety: Column types, names, and nullability live in the type system; mismatches fail at compile time.
- Interop: Uses arrow-array/arrow-schema types directly; no bespoke runtime layer.
- Supports nested structs, lists, dictionaries, timestamps, and more with compile-time schema generation.
- Example usage includes deriving Record for structs and building RecordBatches with compile-time schema checks.
- Metadata can be added at schema or field level with attributes.
- Supports various Arrow data types including primitives, strings, binary, temporal, decimal, nested types, and dictionaries.
- Missing support for BinaryView, Utf8View, ListView, LargeListView, and RunEndEncoded.