myfaces-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Krashan Brahmanjara (Issue Comment Edited) (JIRA)" <...@myfaces.apache.org>
Subject [jira] [Issue Comment Edited] (MYFACES-3528) CLONE - Performance Improvements
Date Fri, 20 Apr 2012 11:36:41 GMT

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

Krashan Brahmanjara edited comment on MYFACES-3528 at 4/20/12 11:35 AM:
------------------------------------------------------------------------

Merged improvements from MYFACES-1749
                
      was (Author: krokodylowy3):
    Merged improvements MYFACES-1749
                  
> CLONE - Performance Improvements
> --------------------------------
>
>                 Key: MYFACES-3528
>                 URL: https://issues.apache.org/jira/browse/MYFACES-3528
>             Project: MyFaces Core
>          Issue Type: Improvement
>            Reporter: Krashan Brahmanjara
>            Assignee: Martin Marinschek
>             Fix For: 1.2.2
>
>         Attachments: ApplicationImpl.java, _ComponentAttributesMap.java
>
>
> Last week I did some JMeter testing, profiling and code checking on MyFaces to try increase
the overall performance. Here are my suggestions for improvement:
> *) _ComponentAttributesMap
> I introduced a cache for maps with component attributes. This cache avoids rebuilding
the map for every instance of the same component class. It is implemented using a WeakHashMap
to allow the GC to remove entries that are not referenced in any instance.
> *) UIComponentBase
> Made a few changes in isIdValid as it is called quite often. The new id is now checked
against the old id and if it is the same it is assumed as valid (avoids checking chars). Additionally
I use isLetterOrDigit() and access string chars directly insted of fetching an array first.
> *) ImplicitObjectResolver
> I replaced List with Map to avoid iteration over lists.
> *) HtmlResponseWriterImpl
> Use new method of HTMLEncoder for char[]
> *) HTMLEncoder
> Improved performance of encode mthod and added a new one that takes a char[] und directly
writes to a writer.
> *) UnicodeEncoder
> Replaced StringBuffer with StringBuilder.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Mime
View raw message