You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@myfaces.apache.org by "Jeanne Waldman (JIRA)" <de...@myfaces.apache.org> on 2011/02/09 02:47:57 UTC

[jira] Created: (TRINIDAD-2032) perf: save memory by sharing selector objects in filesystemstylecache

perf: save memory by sharing selector objects in filesystemstylecache
---------------------------------------------------------------------

                 Key: TRINIDAD-2032
                 URL: https://issues.apache.org/jira/browse/TRINIDAD-2032
             Project: MyFaces Trinidad
          Issue Type: Improvement
          Components: Skinning
            Reporter: Jeanne Waldman
            Assignee: Jeanne Waldman


We can save memory if we store Selectors in a <Selector, Selector> map at the
FileSystemStyleCache level, and reuse where we can.

The implementation will be  similar to what we did in TRINIDAD-2025 where we reused
Style objects. Selector objects are only 16 bytes each, but each
FileSystemStyleCache$StylesImpl instance creates about 4500 of them for our complicated skin.

Before Selector sharing:
FSSC$Entry about 335K each of retained size.
FSSC$StylesImpl about 214K each of retained size

run a page in 3 diff browsers, and we have 13402 Selector objects, total 214K
retained size

After Selector sharing:
FSSC$Entry about 263K each of retained size.
FSSC$StylesImpl about 142K each of retained size
run a page in 3 diff browsers, and we have 4533 Selector objects using 72.5K
Retained Size

-- 
This message is automatically generated by JIRA.
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Resolved: (TRINIDAD-2032) perf: save memory by sharing selector objects in filesystemstylecache

Posted by "Jeanne Waldman (JIRA)" <de...@myfaces.apache.org>.
     [ https://issues.apache.org/jira/browse/TRINIDAD-2032?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Jeanne Waldman resolved TRINIDAD-2032.
--------------------------------------

       Resolution: Fixed
    Fix Version/s: 2.0.0-beta-2

> perf: save memory by sharing selector objects in filesystemstylecache
> ---------------------------------------------------------------------
>
>                 Key: TRINIDAD-2032
>                 URL: https://issues.apache.org/jira/browse/TRINIDAD-2032
>             Project: MyFaces Trinidad
>          Issue Type: Improvement
>          Components: Skinning
>            Reporter: Jeanne Waldman
>            Assignee: Jeanne Waldman
>             Fix For: 2.0.0-beta-2
>
>
> We can save memory if we store Selectors in a <Selector, Selector> map at the
> FileSystemStyleCache level, and reuse where we can.
> The implementation will be  similar to what we did in TRINIDAD-2025 where we reused
> Style objects. Selector objects are only 16 bytes each, but each
> FileSystemStyleCache$StylesImpl instance creates about 4500 of them for our complicated skin.
> Before Selector sharing:
> FSSC$Entry about 335K each of retained size.
> FSSC$StylesImpl about 214K each of retained size
> run a page in 3 diff browsers, and we have 13402 Selector objects, total 214K
> retained size
> After Selector sharing:
> FSSC$Entry about 263K each of retained size.
> FSSC$StylesImpl about 142K each of retained size
> run a page in 3 diff browsers, and we have 4533 Selector objects using 72.5K
> Retained Size

-- 
This message is automatically generated by JIRA.
-
For more information on JIRA, see: http://www.atlassian.com/software/jira