[jboss-cvs] JBossCache/src/org/jboss/cache/interceptors ...
Manik Surtani
msurtani at jboss.com
Tue Nov 14 09:17:12 EST 2006
User: msurtani
Date: 06/11/14 09:17:12
Modified: src/org/jboss/cache/interceptors EvictionInterceptor.java
Log:
Merged eviction.Region and Region, eviction.RegionManager and RegionManager (lots of changes, now needs v. thorough testing)
Revision Changes Path
1.8 +6 -6 JBossCache/src/org/jboss/cache/interceptors/EvictionInterceptor.java
(In the diff below, changes in quantity of whitespace are not shown.)
Index: EvictionInterceptor.java
===================================================================
RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/EvictionInterceptor.java,v
retrieving revision 1.7
retrieving revision 1.8
diff -u -b -r1.7 -r1.8
--- EvictionInterceptor.java 12 Oct 2006 03:39:59 -0000 1.7
+++ EvictionInterceptor.java 14 Nov 2006 14:17:12 -0000 1.8
@@ -11,10 +11,10 @@
import org.apache.commons.logging.LogFactory;
import org.jboss.cache.CacheSPI;
import org.jboss.cache.Fqn;
+import org.jboss.cache.RegionManager;
+import org.jboss.cache.Region;
import org.jboss.cache.eviction.EvictedEventNode;
import org.jboss.cache.eviction.NodeEventType;
-import org.jboss.cache.eviction.Region;
-import org.jboss.cache.eviction.RegionManager;
import org.jboss.cache.marshall.MethodDeclarations;
import org.jboss.cache.marshall.MethodCall;
@@ -27,7 +27,7 @@
* This interceptor is used to handle eviction events.
*
* @author Daniel Huang
- * @version $Revision: 1.7 $
+ * @version $Revision: 1.8 $
*/
public class EvictionInterceptor extends Interceptor
{
@@ -75,7 +75,7 @@
public void setCache(CacheSPI cache)
{
super.setCache(cache);
- this.regionManager = cache.getEvictionRegionManager();
+ this.regionManager = cache.getRegionManager();
}
public Object invoke(MethodCall m) throws Throwable
@@ -134,12 +134,12 @@
protected boolean canIgnoreEvent(Fqn fqn, NodeEventType type)
{
- return regionManager.getRegion(fqn).getEvictionPolicy().canIgnoreEvent(fqn, type);
+ return regionManager.getRegion(fqn, true).getEvictionPolicy().canIgnoreEvent(fqn, type);
}
protected void doEventUpdatesOnRegionManager(EvictedEventNode event)
{
- Region region = regionManager.getRegion(event.getFqn());
+ Region region = regionManager.getRegion(event.getFqn(), true);
region.putNodeEvent(event);
if (log.isTraceEnabled())
More information about the jboss-cvs-commits
mailing list