[jira] [Commented] (MYFACES-3170) [perf] use initialCapacity for ArrayList

2015-11-18 Thread Leonardo Uribe (JIRA)

[ 
https://issues.apache.org/jira/browse/MYFACES-3170?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15011779#comment-15011779
 ] 

Leonardo Uribe commented on MYFACES-3170:
-

The improvement is minimal. It is not something really required.

> [perf] use initialCapacity for ArrayList
> 
>
> Key: MYFACES-3170
> URL: https://issues.apache.org/jira/browse/MYFACES-3170
> Project: MyFaces Core
>  Issue Type: Improvement
>  Components: General
> Environment: myfaces trunk
>Reporter: Martin Kočí
>Assignee: Martin Kočí
>Priority: Minor
>
> new ArrayList() creates Object [10]  and in some situation it is not 
> necessary. For example, UIInput.addValidator allocates ArrayList of size ten 
> but in real usage nobody adds 10 validators to one component.
> Analyze usage of new ArrayList() and myfaces code and use initialCapacity if 
> possible.
> i



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


[jira] [Commented] (MYFACES-3170) [perf] use initialCapacity for ArrayList

2015-10-29 Thread Thomas Andraschko (JIRA)

[ 
https://issues.apache.org/jira/browse/MYFACES-3170?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=14981010#comment-14981010
 ] 

Thomas Andraschko commented on MYFACES-3170:


AFAICS it's already used in many places.
[~lu4242] WDYT? is this still required in trunk?

> [perf] use initialCapacity for ArrayList
> 
>
> Key: MYFACES-3170
> URL: https://issues.apache.org/jira/browse/MYFACES-3170
> Project: MyFaces Core
>  Issue Type: Improvement
>  Components: General
> Environment: myfaces trunk
>Reporter: Martin Kočí
>Assignee: Martin Kočí
>Priority: Minor
>
> new ArrayList() creates Object [10]  and in some situation it is not 
> necessary. For example, UIInput.addValidator allocates ArrayList of size ten 
> but in real usage nobody adds 10 validators to one component.
> Analyze usage of new ArrayList() and myfaces code and use initialCapacity if 
> possible.
> i



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