[
https://issues.apache.org/jira/browse/HIVE-11288?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14644762#comment-14644762
]
Greg Phillips commented on HIVE-11288:
--------------------------------------
[~swarnim] I think you are spot on. I can create an additional ticket to
investigate how we can modify the InstanceCache contract to ensure it is not
misused.
I would like to limit the scope of this ticket to address the instance cache
returning the incorrect schema if possible.
Concerning the recent Hive QA failure, the test that failed has no relation to
the patch that I am able to discern. The changes in the provided patch are
limited to the avro serde, which is not referenced in the TestStreaming class
or any referenced classes.
> Avro SerDe InstanceCache returns incorrect schema
> -------------------------------------------------
>
> Key: HIVE-11288
> URL: https://issues.apache.org/jira/browse/HIVE-11288
> Project: Hive
> Issue Type: Bug
> Reporter: Greg Phillips
> Assignee: Greg Phillips
> Attachments: HIVE-11288.2.patch, HIVE-11288.3.patch,
> HIVE-11288.4.patch, HIVE-11288.patch
>
>
> To reproduce this error, take two fields in an avro schema document matching
> the following:
> "type" : { "type": "array", "items": [ "null", { "type": "map", "values": [
> "null", "string" ] } ] }
> "type" : { "type": "map", "values": [ "null" , { "type": "array", "items": [
> "null" , "string"] } ] }
> After creating two tables in hive with these schemas, the describe statement
> on each of them will only return the schema for the first one loaded. This
> is due to a hashCode() collision in the InstanceCache.
> A patch will be included in this ticket shortly which removes the hashCode
> call from the InstanceCache's internal HashMap, and instead provides the
> entire schema object.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)