hive-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Thejas M Nair (JIRA)" <>
Subject [jira] [Commented] (HIVE-3168) LazyBinaryObjectInspector.getPrimitiveJavaObject copies beyond length of underlying BytesWritable
Date Tue, 03 Jul 2012 20:32:38 GMT


Thejas M Nair commented on HIVE-3168:

The 2nd patch replaces the first, so you need to apply on the 2nd one. I tried applying it
to a fresh checkout of hive 0.9 branch and I was able to build it fine. Please post the build
error if you think it is related to the patch.

> LazyBinaryObjectInspector.getPrimitiveJavaObject copies beyond length of underlying BytesWritable
> -------------------------------------------------------------------------------------------------
>                 Key: HIVE-3168
>                 URL:
>             Project: Hive
>          Issue Type: Bug
>          Components: Serializers/Deserializers
>    Affects Versions: 0.9.0
>            Reporter: Thejas M Nair
>            Assignee: Thejas M Nair
>             Fix For: 0.10.0, 0.9.1
>         Attachments: HIVE-3168.1.patch, HIVE-3168.2.patch
> LazyBinaryObjectInspector.getPrimitiveJavaObject copies the full capacity of the LazyBinary's
underlying BytesWritable object, which can be greater than the size of the actual contents.

> This leads to additional characters at the end of the ByteArrayRef returned. When the
LazyBinary object gets re-used, there can be remnants of the later portion of previous entry.

> This was not seen while reading through hive queries, which I think is because a copy
elsewhere seems to create LazyBinary with length == capacity. (probably LazyBinary copy constructor).
This was seen when MR or pig used Hcatalog to read the data.

This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators:!default.jspa
For more information on JIRA, see:


View raw message