You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@avro.apache.org by "Jeff Hodges (JIRA)" <ji...@apache.org> on 2010/03/27 02:40:27 UTC

[jira] Created: (AVRO-492) python implementation should encode numbers as little-endian

python implementation should encode numbers as little-endian
------------------------------------------------------------

                 Key: AVRO-492
                 URL: https://issues.apache.org/jira/browse/AVRO-492
             Project: Avro
          Issue Type: Bug
          Components: python
    Affects Versions: 1.3.1
            Reporter: Jeff Hodges
            Assignee: Jeff Hodges


The current version of the Python implementation uses big-endian encoding when writing and reading numeric data. The spec specifies that little-endian encoding should be used instead[1]. 

[1] http://hadoop.apache.org/avro/docs/current/spec.html#binary_encode_primitive 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (AVRO-492) python implementation should encode numbers as little-endian

Posted by "Bruce Mitchener (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/AVRO-492?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12850455#action_12850455 ] 

Bruce Mitchener commented on AVRO-492:
--------------------------------------

STRUCT_INT and STRUCT_LONG are only used in the process of handling floats and doubles.

The interop testing just tests that the file could be read ... it won't test that the data came through correctly currently.  If there was an error in something like integer/long encoding/decoding, it would show up due to the other things that use that (like strings) that would fail were it wrong.

The interop tests need to be modified so that at least some of the fields being serialized and read back in have the same value for each language and can be verified in each test that reads in the interop data.

Make sense?


> python implementation should encode numbers as little-endian
> ------------------------------------------------------------
>
>                 Key: AVRO-492
>                 URL: https://issues.apache.org/jira/browse/AVRO-492
>             Project: Avro
>          Issue Type: Bug
>          Components: python
>    Affects Versions: 1.3.1
>            Reporter: Jeff Hodges
>            Assignee: Jeff Hodges
>         Attachments: AVRO-492.patch
>
>
> The current version of the Python implementation uses big-endian encoding when writing and reading numeric data. The spec specifies that little-endian encoding should be used instead[1]. 
> [1] http://hadoop.apache.org/avro/docs/current/spec.html#binary_encode_primitive 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (AVRO-492) python implementation should encode numbers as little-endian

Posted by "Jeff Hammerbacher (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/AVRO-492?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12850452#action_12850452 ] 

Jeff Hammerbacher commented on AVRO-492:
----------------------------------------

I left this as a TODO because tests were passing. Did you see any failures with the previous encoding?

> python implementation should encode numbers as little-endian
> ------------------------------------------------------------
>
>                 Key: AVRO-492
>                 URL: https://issues.apache.org/jira/browse/AVRO-492
>             Project: Avro
>          Issue Type: Bug
>          Components: python
>    Affects Versions: 1.3.1
>            Reporter: Jeff Hodges
>            Assignee: Jeff Hodges
>         Attachments: AVRO-492.patch
>
>
> The current version of the Python implementation uses big-endian encoding when writing and reading numeric data. The spec specifies that little-endian encoding should be used instead[1]. 
> [1] http://hadoop.apache.org/avro/docs/current/spec.html#binary_encode_primitive 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (AVRO-492) python implementation should encode numbers as little-endian

Posted by "Jeff Hodges (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/AVRO-492?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Jeff Hodges updated AVRO-492:
-----------------------------

    Attachment: AVRO-492.patch

Changes the numeric encoding to be little endian. Python internal tests pass, and so do the interop tests.

This latter part is the baffling part. They seemed to pass before. Did I miss something?

> python implementation should encode numbers as little-endian
> ------------------------------------------------------------
>
>                 Key: AVRO-492
>                 URL: https://issues.apache.org/jira/browse/AVRO-492
>             Project: Avro
>          Issue Type: Bug
>          Components: python
>    Affects Versions: 1.3.1
>            Reporter: Jeff Hodges
>            Assignee: Jeff Hodges
>         Attachments: AVRO-492.patch
>
>
> The current version of the Python implementation uses big-endian encoding when writing and reading numeric data. The spec specifies that little-endian encoding should be used instead[1]. 
> [1] http://hadoop.apache.org/avro/docs/current/spec.html#binary_encode_primitive 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.