You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@parquet.apache.org by "Fokko Driesprong (Jira)" <ji...@apache.org> on 2020/02/25 13:26:00 UTC

[jira] [Resolved] (PARQUET-1759) InternalParquetRecordReader Use Singleton Set

     [ https://issues.apache.org/jira/browse/PARQUET-1759?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Fokko Driesprong resolved PARQUET-1759.
---------------------------------------
    Resolution: Fixed

> InternalParquetRecordReader Use Singleton Set
> ---------------------------------------------
>
>                 Key: PARQUET-1759
>                 URL: https://issues.apache.org/jira/browse/PARQUET-1759
>             Project: Parquet
>          Issue Type: Improvement
>            Reporter: David Mollitor
>            Assignee: David Mollitor
>            Priority: Minor
>              Labels: pull-request-available
>             Fix For: 1.12.0
>
>
> https://github.com/apache/parquet-mr/blob/d85a8f5dcfc1381655fcccaa81a2e83ba812f6a4/parquet-hadoop/src/main/java/org/apache/parquet/hadoop/InternalParquetRecordReader.java#L260-L262
> Code currently instantiates a {{HashSet}} (with a default internal data structure of size 16}} and then makes it immutable.  Use Collection#singleton to achieve this same goal with fewer lines of code and less memory requirements.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)