myfaces-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Scott O'Bryan <darkar...@gmail.com>
Subject Re: [Trinidad][API] web.xml context-param for skin cache size
Date Thu, 14 Apr 2011 19:13:27 GMT
2 for me

On 04/14/2011 12:23 PM, Blake Sullivan wrote:
> I vote for 2.
>
> -- Blake Sullivan
>
> On 4/14/11 11:22 AM, Jeanne Waldman wrote:
>> Here are some more options combined with the old top vote getters
>>
>> (1) MAX_CACHED_SKINS
>> (2) MAX_SKINS_CACHED
>> (3) MAX_SKINS_IN_CACHE
>> (4) SKIN_MAX_CACHE_SIZE
>>
>> Still, my vote is Pavitra's take on Blake's, (2). It is the maximum 
>> number of skins that we cache, hence MAX_SKINS_CACHED
>>
>> Jeanne
>>
>> Pavitra Subramaniam wrote, On 4/13/2011 3:37 PM PT:
>>> 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
>>>>>>
>


Mime
View raw message