-
Notifications
You must be signed in to change notification settings - Fork 2.5k
Decimal handling bug in SparkAvroPostProcessor #14752
Copy link
Copy link
Open
Labels
area:ingestIngestion into HudiIngestion into Hudifrom-jirapriority:criticalProduction degraded; pipelines stalledProduction degraded; pipelines stalledpriority:highSignificant impact; potential bugsSignificant impact; potential bugstype:bugBug reports and fixesBug reports and fixestype:community-supportCommunity-relatedCommunity-related
Metadata
Metadata
Assignees
Labels
area:ingestIngestion into HudiIngestion into Hudifrom-jirapriority:criticalProduction degraded; pipelines stalledProduction degraded; pipelines stalledpriority:highSignificant impact; potential bugsSignificant impact; potential bugstype:bugBug reports and fixesBug reports and fixestype:community-supportCommunity-relatedCommunity-related
Type
Fields
Give feedbackNo fields configured for issues without a type.
This issue related to [#[Hudi-1343]|[https://github.com//pull/2192].]
I think the purpose of Hudi-1343 was to bridge the difference between avro 1.8.2(used by hudi) and avro 1.9.2(used by upstream system) thru internal Struct type. In particular, the incompatible form to express nullable type between those two versions.
It was all good until I hit the type Decimal. Since it can either be FIXED or BYTES, if an avro schema contains decimal type with BYTES as its literal type, after this two way conversion its literal type become FIXED instead. This will cause an exception to be thrown in AvroConversionHelper as the data underneath is HeapByteBuffer rather than GenericFixed.
JIRA info
Comments
28/Apr/21 15:53;shivnarayan;https://issues.apache.org/jira/browse/HUDI-1343?focusedCommentId=17325964&page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#comment-17325964
;;;