[jboss-cvs] JBossCache/tests/interop/org/jboss/cache/interop ...

Manik Surtani msurtani at jboss.com
Thu Jul 20 12:52:46 EDT 2006


  User: msurtani
  Date: 06/07/20 12:52:46

  Modified:    tests/interop/org/jboss/cache/interop  Main.java
  Log:
  migrated to new configurators
  
  Revision  Changes    Path
  1.3       +45 -48    JBossCache/tests/interop/org/jboss/cache/interop/Main.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Main.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/interop/org/jboss/cache/interop/Main.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- Main.java	21 Feb 2006 01:37:47 -0000	1.2
  +++ Main.java	20 Jul 2006 16:52:46 -0000	1.3
  @@ -22,6 +22,11 @@
   
   package org.jboss.cache.interop;
   
  +import org.apache.commons.logging.Log;
  +import org.apache.commons.logging.LogFactory;
  +import org.jboss.cache.TreeCache;
  +import org.jboss.cache.factories.XmlConfigurationParser;
  +
   import java.io.BufferedInputStream;
   import java.io.ObjectInputStream;
   import java.io.ObjectOutputStream;
  @@ -29,12 +34,6 @@
   import java.net.ServerSocket;
   import java.net.Socket;
   
  -import org.apache.commons.logging.Log;
  -import org.apache.commons.logging.LogFactory;
  -import org.jboss.cache.PropertyConfigurator;
  -import org.jboss.cache.TreeCache;
  -import org.jboss.cache.TreeCacheMBean;
  -
   /**
    * Starts a JBossCache instance and then listens on a socket for
    * a call from {@link Shutdown}.
  @@ -52,7 +51,7 @@
      private int listenerPort_ = 11111;
      private String bindAddressString_;
      private ServerSocket srvSock_;
  -   private TreeCacheMBean cache_;
  +   private TreeCache cache_;
      private Thread listenerThread_;
      private boolean stopped;
      
  @@ -172,9 +171,7 @@
         if (cache_ == null)
         {
            cache_ = new TreeCache();
  -         PropertyConfigurator config = new PropertyConfigurator();
  -         config.configure(cache_, configFile_);
  -         
  +         cache_.setConfiguration(new XmlConfigurationParser().parseFile(configFile_));
            cache_.create();
            cache_.start();
            
  
  
  



More information about the jboss-cvs-commits mailing list