Follow-up on ALF-765 by upgrading EHCache to 2.0.0

- Fixed CacheTest to avoid disk flushes (configuration issues)
 - Allows Cache statistics to be turned off (done)
 - Added explicit switch to LruMemoryStore (raised https://jira.terracotta.org/jira/browse/EHC-652)
 - Removed EHCache usage within TransactionalCache (replaced with LruMap and Set)
 - Even with 'statistics=false' the EHCache code still messes about too much, but it's much better
 - TODO: Leave ripping out of ehcache-transactional.xml until DAO synch


git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@19324 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Derek Hulley
2010-03-17 04:53:04 +00:00
parent 4c8f94071c
commit 733cd6e02d
8 changed files with 354 additions and 148 deletions

View File

@@ -43,6 +43,13 @@ import org.springframework.core.io.Resource;
*/
public class EhCacheManagerFactoryBean implements FactoryBean, InitializingBean, DisposableBean
{
static
{
// https://jira.terracotta.org/jira/browse/EHC-652
// Force old-style LruMemoryStore
System.setProperty("net.sf.ehcache.use.classic.lru", "true");
}
protected final Log logger = LogFactory.getLog(EhCacheManagerFactoryBean.class);
private Resource configLocation;