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

Manik Surtani msurtani at jboss.com
Thu Jan 4 00:35:41 EST 2007


  User: msurtani
  Date: 07/01/04 00:35:41

  Modified:    src/org/jboss/cache/loader/tcp  TcpCacheServer.java
  Log:
  Major changes around nodes, and the way they interact with the interceptor stack.
  Also removed redundant methods in NodeSPI and removed the need for casting to NodeSPI in most cases.
  
  Revision  Changes    Path
  1.24      +9 -9      JBossCache/src/org/jboss/cache/loader/tcp/TcpCacheServer.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TcpCacheServer.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/loader/tcp/TcpCacheServer.java,v
  retrieving revision 1.23
  retrieving revision 1.24
  diff -u -b -r1.23 -r1.24
  --- TcpCacheServer.java	30 Dec 2006 19:48:48 -0000	1.23
  +++ TcpCacheServer.java	4 Jan 2007 05:35:41 -0000	1.24
  @@ -6,7 +6,7 @@
   import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.Modification;
  -import org.jboss.cache.Node;
  +import org.jboss.cache.NodeSPI;
   import org.jboss.cache.factories.XmlConfigurationParser;
   import org.jboss.cache.jmx.JmxUtil;
   import org.jboss.cache.loader.DelegatingCacheLoader;
  @@ -36,7 +36,7 @@
    * TCP-IP based CacheServer, configure TcpDelegatingCacheLoader with host and port of this server
    *
    * @author Bela Ban
  - * @version $Id: TcpCacheServer.java,v 1.23 2006/12/30 19:48:48 msurtani Exp $
  + * @version $Id: TcpCacheServer.java,v 1.24 2007/01/04 05:35:41 msurtani Exp $
    */
   public class TcpCacheServer implements TcpCacheServerMBean
   {
  @@ -113,7 +113,7 @@
   
      public void setCache(CacheImpl cache)
      {
  -//public void setCache(TreeCacheMBean cache) {
  +      //public void setCache(TreeCacheMBean cache) {
         this.cache = cache;
      }
   
  @@ -141,7 +141,7 @@
         }
   
         if (cache == null)
  -      { // still not set
  +      {// still not set
            if (config != null)
            {
               cache = new CacheImpl();
  @@ -311,7 +311,7 @@
            int op;
            Fqn fqn;
            Object key, val, retval;
  -         Node n;
  +         NodeSPI n;
            boolean flag;
   
            while (t != null && Thread.currentThread().equals(t))
  @@ -335,7 +335,7 @@
                     case DelegatingCacheLoader.delegateGetChildrenNames:
                        fqn = (Fqn) input.readObject();
                        Set children = c.getChildrenNames(fqn);
  -                     output.writeObject(children);  // this may be null - that's okay
  +                     output.writeObject(children);// this may be null - that's okay
                        break;
                     case DelegatingCacheLoader.delegateGetKey:
                        fqn = (Fqn) input.readObject();
  @@ -345,13 +345,13 @@
                        break;
                     case DelegatingCacheLoader.delegateGet:
                        fqn = (Fqn) input.readObject();
  -                     n = c.get(fqn);
  +                     n = (NodeSPI) c.get(fqn);
                        if (n == null)
  -                     { // node doesn't exist - return null
  +                     {// node doesn't exist - return null
                           output.writeObject(n);
                           break;
                        }
  -                     Map map = n.getData();
  +                     Map map = n.getDataDirect();
                        if (map == null) map = new HashMap();
                        output.writeObject(map);
                        break;
  
  
  



More information about the jboss-cvs-commits mailing list