[Java IO] Add ArrowFlight IO connector#37904
Conversation
Summary of ChangesHello, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed! This pull request introduces a new Java I/O connector for Apache Arrow Flight, significantly enhancing data transfer capabilities within Beam pipelines. The connector leverages Arrow Flight's high-performance RPC framework to facilitate efficient reading from and writing to Arrow Flight servers, minimizing serialization overhead and enabling faster data movement. This integration expands Beam's ecosystem by providing a robust solution for interacting with various Arrow Flight-compatible data systems. Highlights
🧠 New Feature in Public Preview: You can now enable Memory to help Gemini Code Assist learn from your team's feedback. This makes future code reviews more consistent and personalized to your project's style. Click here to enable Memory in your admin console. Using Gemini Code AssistThe full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips. Invoking Gemini You can request assistance from Gemini at any point by creating a comment using either
Customization To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a Limitations & Feedback Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for GitHub and other Google products, sign up here. Footnotes
|
b384457 to
1b3518d
Compare
|
Assigning reviewers: R: @chamikaramj for label java. Note: If you would like to opt out of this review, comment Available commands:
The PR bot will only process comments in the main thread (not review comments). |
Abacn
left a comment
There was a problem hiding this comment.
Thanks for the new IO! Had an initial comment to kick off
d0551f0 to
7252108
Compare
|
Run Java_Amazon-Web-Services2_IO_Direct PreCommit |
|
Reminder, please take a look at this pr: @chamikaramj @damccorm @shunping |
|
Assigning new set of reviewers because Pr has gone too long without review. If you would like to opt out of this review, comment R: @kennknowles for label java. Available commands:
|
|
Reminder, please take a look at this pr: @kennknowles @Abacn |
|
Assigning new set of reviewers because Pr has gone too long without review. If you would like to opt out of this review, comment R: @ahmedabu98 for label java. Available commands:
|
|
waiting on author |
Add a new IO connector for Apache Arrow Flight, enabling high-performance data transfer over gRPC using the Arrow columnar format. Includes read (BoundedSource) and write (DoFn with doPut) support with endpoint-level split parallelism and bearer token authentication. Fixes apache#20116
- Register :sdks:java:io:arrow-flight in javaioPreCommit task (build.gradle.kts) - Add --add-opens JVM arg for Arrow native memory on JDK 17+ - Make host() nullable at AutoValue level to fix factory method NPE - Eagerly materialize rows from Arrow buffers to prevent stale access - Move root.setRowCount() after vector population for correct ordering - Use AtomicInteger for thread-safe write record counting in tests
3e4fe51 to
447a459
Compare
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #37904 +/- ##
============================================
+ Coverage 54.76% 56.99% +2.23%
- Complexity 1716 3634 +1918
============================================
Files 1066 1186 +120
Lines 169075 190661 +21586
Branches 1255 3774 +2519
============================================
+ Hits 92589 108676 +16087
- Misses 74269 78501 +4232
- Partials 2217 3484 +1267
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
|
Reminder, please take a look at this pr: @ahmedabu98 @damccorm |
Summary
Add a Java I/O connector for Apache Arrow Flight, providing bounded reads and batched writes over gRPC using Arrow record batches.
Fixes #20116
Changes
ArrowFlightIO.Read: fetches the Arrow schema throughgetInfo, splits work byFlightEndpoint, and converts record batches to BeamRowvalues throughArrowConversion.ArrowFlightIO.Write: buffers Beam rows into configurable batches, converts them to Arrow vectors, streams them throughdoPut, and propagates server errors.ArrowConversion.ArrowSchemaTranslatorfor supported primitive types.withToken().flight-core, adds the:sdks:java:io:arrow-flightmodule, and includes it injavaioPreCommit.Java 17+ runtime requirement
Arrow requires
--add-opens=java.base/java.nio=ALL-UNNAMEDon JVMs executing the connector. Beam SDK containers enable this by default. Other environments must configure the local or runner JVM and SDK harnesses as documented inArrowFlightIOJavadoc.Testing
Tests use an in-process
FlightServerand cover:Validated locally on Java 17 with:
Validated tests on Java 21 with:
Did this cause any problems?
Rollback/revert this commit and redeploy the service.
Thank you for your contribution! Follow this checklist to help us incorporate your contribution quickly and easily:
CHANGES.mdwith noteworthy changes.See the Contributor Guide for more tips on making the review process smoother.