[jboss-cvs] JBossCache/src/org/jboss/cache ...

Brian Stansberry brian.stansberry at jboss.com
Wed Dec 20 23:40:07 EST 2006


  User: bstansberry
  Date: 06/12/20 23:40:07

  Modified:    src/org/jboss/cache  Tag: Branch_JBossCache_1_4_0
                        TreeCache.java
  Log:
  [JBCACHE-913] Notify eviction policies of nodes added via state transfer
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.195.2.38 +15 -2     JBossCache/src/org/jboss/cache/TreeCache.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TreeCache.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/TreeCache.java,v
  retrieving revision 1.195.2.37
  retrieving revision 1.195.2.38
  diff -u -b -r1.195.2.37 -r1.195.2.38
  --- TreeCache.java	20 Dec 2006 04:55:39 -0000	1.195.2.37
  +++ TreeCache.java	21 Dec 2006 04:40:07 -0000	1.195.2.38
  @@ -15,6 +15,7 @@
   import org.jboss.cache.buddyreplication.BuddyNotInitException;
   import org.jboss.cache.config.CacheLoaderConfig;
   import org.jboss.cache.config.Option;
  +import org.jboss.cache.eviction.EvictedEventNode;
   import org.jboss.cache.eviction.EvictionPolicy;
   import org.jboss.cache.factories.InterceptorChainFactory;
   import org.jboss.cache.factories.NodeFactory;
  @@ -99,7 +100,7 @@
    * @author <a href="mailto:manik at jboss.org">Manik Surtani (manik at jboss.org)</a>
    * @author Brian Stansberry
    * @author Daniel Huang (dhuang at jboss.org)
  - * @version $Id: TreeCache.java,v 1.195.2.37 2006/12/20 04:55:39 bstansberry Exp $
  + * @version $Id: TreeCache.java,v 1.195.2.38 2006/12/21 04:40:07 bstansberry Exp $
    *          <p/>
    * @see <a href="http://labs.jboss.com/portal/jbosscache/docs">JBossCache doc</a>
    */
  @@ -6078,7 +6079,19 @@
         Map children;
   
         if (curr == null) return;
  -      notifyNodeCreated(curr.getFqn());
  +      Fqn fqn = curr.getFqn();
  +      notifyNodeCreated(fqn);
  +      
  +      // JBCACHE-913
  +      if (evictionRegionManager_ != null)
  +      {
  +         org.jboss.cache.eviction.Region region = evictionRegionManager_.getRegion(fqn);
  +         if (region != null)
  +         {
  +            region.putNodeEvent(new EvictedEventNode(fqn, EvictedEventNode.ADD_NODE_EVENT));
  +         }
  +      }
  +      
         if ((children = curr.getChildren()) != null)
         {
            for (Iterator it = children.values().iterator(); it.hasNext();)
  
  
  



More information about the jboss-cvs-commits mailing list