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

Leonardo Uribe updated MYFACES-2156:
------------------------------------

       Resolution: Fixed
    Fix Version/s: 1.2.7-SNAPSHOT
           Status: Resolved  (was: Patch Available)

Solution committed, it uses a ConcurrentHashMap to hold the families and a 
Flat3Map to hold renderers (because usually a family does not contain too much 
elements).

> Performance improvement in HtmlRenderKitImpl
> --------------------------------------------
>
>                 Key: MYFACES-2156
>                 URL: https://issues.apache.org/jira/browse/MYFACES-2156
>             Project: MyFaces Core
>          Issue Type: Improvement
>    Affects Versions: 1.1.6
>            Reporter: Philipp Schoepf
>            Assignee: Leonardo Uribe
>            Priority: Minor
>             Fix For: 1.2.7-SNAPSHOT
>
>         Attachments: MYFACES-2156.patch
>
>
> we did some profiling in our project and found out that HtmlRenderKitImpl 
> creates some amount of transient object garbage when getRenderer is called:
> Self   8005   0,00   7,92           0     2894448   
> J:org/apache/myfaces/renderkit/html/HtmlRenderKitImpl.getRenderer(Ljava/lang/String;Ljava/lang/String;)Ljavax/faces/render/Renderer;
>    Child  24015   0,00   4,69           0     1714064   
> J:java/lang/StringBuffer.append(Ljava/lang/String;)Ljava/lang/StringBuffer;
> The above values were recorded with just 2 request to a page with many 
> components - 2.8MB of transient objects were created by 8005 calls to 
> getRenderer.
> I assume that this is due to the "keying" currenlty implemented which always 
> creates a concatinated string. I guess using a Map<String, Map<String, 
> Renderer>> doubleMap could improve the performance here since string creation 
> for keying would not be nessary.
> Might also touch 1.2 and 2.0.

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

Reply via email to