-
Notifications
You must be signed in to change notification settings - Fork 13
[chore] Implement datatype conversion for all types in arrow.rs #81
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
This PR implements Arrow datatype conversions for previously unimplemented Fluss types (Decimal, Time, Timestamp, TimestampLTz, Bytes, Binary) in the to_arrow_type function. This completes the type mapping functionality needed for Arrow serialization/deserialization, addressing issue #78.
Key changes:
- Adds Decimal128 conversion with precision/scale mapping
- Implements Time/Timestamp type conversions with precision-based TimeUnit selection
- Adds Binary and Bytes type mappings to Arrow binary types
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
Copilot reviewed 1 out of 1 changed files in this pull request and generated 6 comments.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
luoyuxia
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@beryllw Thanks for the pr. Left minor comments.
| .expect("length exceeds i32::MAX"), | ||
| ), | ||
| DataType::Array(arrow_type) => ArrowDataType::List( | ||
| arrow_schema::Field::new_list_field(to_arrow_type(arrow_type.get_element_type()), true) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit:
consider nullable of arrow_type
| let key_type = to_arrow_type(map_type.key_type()); | ||
| let value_type = to_arrow_type(map_type.value_type()); | ||
| let entry_fields = vec![ | ||
| arrow_schema::Field::new("key", key_type, false), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
dito
Purpose
Linked issue: close #78
Brief change log
Tests
API and Format
Documentation