You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@gobblin.apache.org by "ASF GitHub Bot (Jira)" <ji...@apache.org> on 2023/05/01 18:41:00 UTC

[jira] [Work logged] (GOBBLIN-1827) Avro Flattener should order nested optional fields correctly if they have a non-null default value

     [ https://issues.apache.org/jira/browse/GOBBLIN-1827?focusedWorklogId=859898&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-859898 ]

ASF GitHub Bot logged work on GOBBLIN-1827:
-------------------------------------------

                Author: ASF GitHub Bot
            Created on: 01/May/23 18:40
            Start Date: 01/May/23 18:40
    Worklog Time Spent: 10m 
      Work Description: Will-Lo merged PR #3689:
URL: https://github.com/apache/gobblin/pull/3689




Issue Time Tracking
-------------------

    Worklog Id:     (was: 859898)
    Time Spent: 20m  (was: 10m)

> Avro Flattener should order nested optional fields correctly if they have a non-null default value
> --------------------------------------------------------------------------------------------------
>
>                 Key: GOBBLIN-1827
>                 URL: https://issues.apache.org/jira/browse/GOBBLIN-1827
>             Project: Apache Gobblin
>          Issue Type: Bug
>          Components: gobblin-core
>            Reporter: William Lo
>            Assignee: Abhishek Tiwari
>            Priority: Major
>          Time Spent: 20m
>  Remaining Estimate: 0h
>
> * Consider the following description:
> * Record R1 \{
>  *   fields : {[
>  *      {
>  *        Union : [
>  *          null,
>  *          Record R2 {
>  *            fields : {[
>  *                {
>  *                  String S1
>  *.                  default: String S3
>  *                }, \{
>  *                  String S2
>  *                }
>  *            ]}
>  *          }
>  *      }
>  *   ]}
>  * }
>  * will be flattened to:
>  * Record R1 \{
>  *   fields : {[
>  *      {
>  *        Union : [ null, String S1]
>  *.       default: String S3
>  *      }, \{
>  *        Union : [ null, String S2]
>  *      }
>  *   ]}
>  * }
> Due to the addition of the AvroCompatibilityHelper, Avro flattening can run into an issue in the above scenario due to the nested non-null default S3 since the default type needs to be the first type in the field order. So R1 should have field S1 as Union [String S1, null]



--
This message was sent by Atlassian Jira
(v8.20.10#820010)