Uploaded image for project: 'Spark'
  1. Spark
  2. SPARK-27858

Fix for avro deserialization on union types with multiple non-null types

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • 2.4.3, 3.0.0
    • 2.4.4, 3.0.0
    • SQL
    • None

    Description

      This issue aims to fix 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.

      Attachments

        Issue Links

          Activity

            People

              gcmerz Gabbi Merz
              dongjoon Dongjoon Hyun
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: