[
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