On 4/13/2011 2:46 PM, Jeanne Waldman wrote:
I like it too. It doesn't roll of the tongue, but I can't think of
something simpler and better.
You could try a slight variation "MAX_SKINS_CACHED".
Prakash Udupa wrote, On 4/13/2011 2:36 PM PT:
I think configurators are less likely to understand what a 'STYLE
PROVIDER' means. So I like the simpler name Blake proposed
'org.apache.myfaces.trinidad.skin.MAX_CACHED_SKINS'.
Thanks,
Prakash
On 4/13/2011 3:52 PM, Blake Sullivan wrote:
On 4/13/11 1:13 PM, Jeanne Waldman wrote:
Hi,
For this issue, TRINIDAD-2026
<https://issues.apache.org/jira/browse/TRINIDAD-2026>memory leak in
skinstyleprovider, I use a least-recently-used-map instead of a
HashMap so I can limit the number of skins that I cache.
This is useful if an application is built so that they have many
skins, like if they have a skin per user, so that the numbe of
cached skins doesn't keep growing and growing.
I default to size 20, but this is also configurable via a web.xml
context-parameter.
Here are some proposed names:
org.apache.myfaces.trinidad.skin.NUMBER_OF_SKINS_CACHE_SIZE
org.apache.myfaces.trinidad.skin.SKIN_STYLE_PROVIDER_CACHE_SIZE
org.apache.myfaces.trinidad.skin.SKIN_STYLE_PROVIDER_LRU_CACHE_SIZE
in the patch it is
org.apache.myfaces.trinidad.skin.SKIN_STYLE_PROVIDER_CACHE_SIZE, so
if I don't hear any objections, this is what I will use.
Thanks,
Jeanne
How about org.apache.myfaces.trinidad.skin.MAX_CACHED_SKINS?
SKIN_STYLE_PROVIDER_CACHE_SIZE is more specific and more technically
correct, though.
-- Blake Sullivan