You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flink.apache.org by "Chesnay Schepler (JIRA)" <ji...@apache.org> on 2016/02/16 10:46:18 UTC

[jira] [Commented] (FLINK-3321) TupleSerializerBase.getLength should know the length when all fields know it

    [ https://issues.apache.org/jira/browse/FLINK-3321?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15148356#comment-15148356 ] 

Chesnay Schepler commented on FLINK-3321:
-----------------------------------------

how would you differentiate whether a field serializer doesn't know it's length?

> TupleSerializerBase.getLength should know the length when all fields know it
> ----------------------------------------------------------------------------
>
>                 Key: FLINK-3321
>                 URL: https://issues.apache.org/jira/browse/FLINK-3321
>             Project: Flink
>          Issue Type: Improvement
>          Components: Java API
>            Reporter: Gabor Gevay
>            Priority: Minor
>              Labels: starter
>
> TupleSerializerBase.getLength currently always returns -1, but it could actually know the length, when all the field serializers know their lengths (since no null can appear anywhere in Tuples, nor can a subclass of Tuple with additional fields appear).
> (The serializer knowing the exact size has various performance benefits, for example see FixedLengthRecordSorter, or CompactingHashTable.getInitialTableSize.)



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)