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

ASF subversion and git services commented on AVRO-1574:
-------------------------------------------------------

Commit 58ebac451d176280febe5b2e95f78e6a065be4ec in avro's branch 
refs/heads/branch-1.7 from [~sekikn]
[ https://git-wip-us.apache.org/repos/asf?p=avro.git;h=58ebac4 ]

AVRO-1574: Create list for schema symbols with specified size.

Signed-off-by: Nandor Kollar <[email protected]>
Signed-off-by: Sean Busbey <[email protected]>
(cherry picked from commit 09c997e206615c4b23ab9ae2ab5f6a3d793e9afb)
(cherry picked from commit 2f6eb2f4ec2071bc03e52a3ba8ac1d6aeb954c88)


> Suboptimal arraylist creation
> -----------------------------
>
>                 Key: AVRO-1574
>                 URL: https://issues.apache.org/jira/browse/AVRO-1574
>             Project: Avro
>          Issue Type: Improvement
>          Components: java
>    Affects Versions: 1.7.7
>            Reporter: Zoltan Farkas
>            Assignee: Kengo Seki
>            Priority: Trivial
>              Labels: beginner
>             Fix For: 1.7.8, 1.9.0, 1.8.3
>
>         Attachments: AVRO-1574.patch
>
>   Original Estimate: 5m
>  Remaining Estimate: 5m
>
> in Schema.java:
> 1231         LockableArrayList<String> symbols = new 
> LockableArrayList<String>();
>  
> 1232         for (JsonNode n : symbolsNode)
>  
> 1233           symbols.add(n.getTextValue());
> should be changed to:
> 1231         LockableArrayList<String> symbols = new 
> LockableArrayList<String>(symbolsNode.size());
>  
> 1232         for (JsonNode n : symbolsNode)
>  
> 1233           symbols.add(n.getTextValue());
>  



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

Reply via email to