You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by GitBox <gi...@apache.org> on 2019/05/27 20:34:44 UTC

[GitHub] [spark] gcmerz opened a new pull request #24722: Fix for avro deserialization on union types with multiple non-null types

gcmerz opened a new pull request #24722: Fix for avro deserialization on union types with multiple non-null types
URL: https://github.com/apache/spark/pull/24722
 
 
   ## What changes were proposed in this pull request?
   
   This is a fix for https://github.com/palantir/spark/issues/560 where in a union avro type with more than one non-null value (for instance `["string", "null", "int"]`) the deserialization to a DataFrame would throw a `java.lang.ArrayIndexOutOfBoundsException`. The issue was that the `fieldWriter` relied on the index from the avro schema before null were filtered out.
   
   ## How was this patch tested?
   
   A test for the case of multiple non-null values was added and the tests were run using sbt by running `testOnly org.apache.spark.sql.avro.AvroSuite`
   
   Please review https://spark.apache.org/contributing.html before opening a pull request.
   

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org