[hibernate-issues] [Hibernate-JIRA] Commented: (HV-479) Implement an eviction strategy for BeanMetaDataCache
Hardy Ferentschik (JIRA)
noreply at atlassian.com
Wed Feb 1 14:57:10 EST 2012
[ https://hibernate.onjira.com/browse/HV-479?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=45337#comment-45337 ]
Hardy Ferentschik commented on HV-479:
--------------------------------------
Added _SoftLimitMRUCache_ to HV. At the moment I am not exposing strong and soft ref count for configuration, but it could be done - https://github.com/hferentschik/hibernate-validator/tree/HV-479
Thoughts?
> Implement an eviction strategy for BeanMetaDataCache
> ----------------------------------------------------
>
> Key: HV-479
> URL: https://hibernate.onjira.com/browse/HV-479
> Project: Hibernate Validator
> Issue Type: Improvement
> Components: engine
> Reporter: Gunnar Morling
> Assignee: Hardy Ferentschik
> Fix For: 4.3.0.Alpha1
>
>
> In {{BeanMetaDataCache}} we have a map from {{Class}} to {{BeanMetaDataImpl}}. Currently there is no eviction strategy for this cache meaning entries will never be removed once they were added to the cache and the {{ValidatorFactoryImpl}} holding the cache exists.
> In particular this means that the concerned class objects never can be garbage-collected. This might cause problems in long-running applications (especially as there is typically one long-living {{ValidatorFactory}} instance per application). Maybe {{WeakHashMap}} or similar might be useful here.
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira
More information about the hibernate-issues
mailing list