rahil-c opened a new pull request, #20192:
URL: https://github.com/apache/hudi/pull/20192

   ### Describe the issue this Pull Request addresses
   
   closes #20191
   
   `read_blob()` on OUT_OF_LINE blobs fails under `KryoSerializer` when Hudi's 
Kryo registrator is not configured.
   The broadcast `HadoopStorageConfiguration` keeps its Hadoop `Configuration` 
in a `transient` field that only Java serialization restores, so executors get 
a null configuration.
   
   ### Summary and Changelog
   
   `read_blob()` now works under any `spark.serializer`.
   
   - `BatchedBlobReader`: adds `broadcastStorageConf`, which broadcasts the 
Hadoop configuration wrapped in Spark's `SerializableConfiguration`, and 
`storageConfFrom`, which rebuilds the `HadoopStorageConfiguration` on the 
executor. This matches how the rest of Hudi's read path ships configuration 
(for example `HoodieFileGroupReaderBasedFileFormat`).
   - `BatchedBlobReader.readBatched`, `processRDD` and 
`BatchedBlobReadExec.doExecute` use the new broadcast.
   - `TestBatchedBlobReaderKryo`: reads OUT_OF_LINE blobs after a Kryo round 
trip of the broadcast value with no Hudi registrator. Local mode does not 
serialize broadcasts, so the test does the round trip itself.
   
   The new test fails on master with a `NullPointerException` from the null 
configuration (`HadoopStorageConfiguration.writeObject`) and passes with this 
change.
   `TestBatchedBlobReaderKryo`, `TestReadBlobSQL` and `TestBatchedBlobReader` 
pass (37 tests).
   
   ### Impact
   
   None on public APIs. `BatchedBlobReader.processRDD` now takes 
`Broadcast[SerializableConfiguration]`; it is an internal helper.
   
   ### Risk Level
   
   low
   
   ### Documentation Update
   
   none
   
   ### Contributor's checklist
   
   - [x] Read through [contributor's 
guide](https://hudi.apache.org/contribute/how-to-contribute)
   - [x] Enough context is provided in the sections above
   - [x] Adequate tests were added if applicable
   


-- 
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]

Reply via email to