[jboss-user] [JBoss Cache: Core Edition] - Re: Problem with expiration eviction
mircea.markus
do-not-reply at jboss.com
Mon Aug 18 08:30:24 EDT 2008
If you want to specify the eviction melodramatically only (no eviction config in the xml file), you have to do it like this:
| ExpirationConfiguration expirationConfiguration = new ExpirationConfiguration();
| expirationConfiguration.setTimeToLiveSeconds(2);
| EvictionConfig ec = new EvictionConfig();
| List<EvictionRegionConfig> ercs = new ArrayList<EvictionRegionConfig>();
| EvictionRegionConfig erc = new EvictionRegionConfig(fqn, expirationConfiguration);
| ercs.add(erc);
| ec.setEvictionRegionConfigs(ercs);
| admDataCache.getConfiguration().setEvictionConfig(ec);
Re:expirationConfiguration.setTimeToLiveSeconds(10);
This is a bug, and the workaround is to set EXPIRATION_KEY for all elements, as lovelyliatroim suggested.
https://jira.jboss.org/jira/browse/JBCACHE-1399 was created
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4171034#4171034
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4171034
More information about the jboss-user
mailing list