phoenix-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Jan Van Besien (JIRA)" <>
Subject [jira] [Updated] (PHOENIX-1587) Error deserializing empty array (which represents null)
Date Fri, 16 Jan 2015 07:59:34 GMT


Jan Van Besien updated PHOENIX-1587:
    Attachment: unit-test-for-PHOENIX-1587.patch

Attached a patch with some unit tests for the issue.

> Error deserializing empty array (which represents null)
> -------------------------------------------------------
>                 Key: PHOENIX-1587
>                 URL:
>             Project: Phoenix
>          Issue Type: Bug
>            Reporter: Jan Van Besien
>            Assignee: Jan Van Besien
>             Fix For: 4.3, 3.3
>         Attachments: PHOENIX-1587.patch, unit-test-for-PHOENIX-1587.patch
> Serializing null arrays results in an empty byte[]. The deserialization logic in PArrayDataType#createPhoenixArray
has a check to return null if the provided byte[] is empty, however it checks the length of
the byte[] rather than the provided length parameter. Note that the provided byte[] is typically
the whole underlying row; it has to be interpreted only from offset to length.
> Therefor, the check has to be replaced with a check on length rather than on bytes.length.

This message was sent by Atlassian JIRA

View raw message