xbattlax opened a new pull request, #2063:
URL: https://github.com/apache/iceberg-rust/pull/2063

   Replace rust_decimal with fastnum::D128 to support 38-digit decimal 
precision as required by the Iceberg spec, addressing issue #669.
   
   **Changes**
   - Add `crates/iceberg/src/spec/values/decimal_utils.rs` with compatibility 
layer providing rust_decimal-like API using fastnum
   - Update `Cargo.toml` to add fastnum, remove rust_decimal, num-bigint, 
num-traits
   - Update `crates/iceberg/src/spec/values/datum.rs` for new decimal API
   - Update `crates/iceberg/src/spec/values/literal.rs` for JSON serialization
   - Update `crates/iceberg/src/transform/bucket.rs` and `truncate.rs` for 
transforms
   - Update `crates/iceberg/src/arrow/schema.rs` and `parquet_writer.rs` for 
Arrow integration
   - Remove RUSTSEC-2024-0399 ignore from `.cargo/audit.toml`
   
   **Notes**
   
   fastnum::D128 provides exactly 38-digit precision with stack-based storage 
(no heap allocation), meeting the Iceberg spec requirement. The decimal_utils 
module provides helper functions that match the rust_decimal API:
   - `decimal_from_i128_with_scale()` - create decimal from mantissa and scale
   - `decimal_mantissa()` / `decimal_scale()` - extract components
   - `i128_from_be_bytes()` / `i128_to_be_bytes_min()` - binary serialization
   
   Closes #669


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to