[jboss-cvs] JBossCache/tests/functional/org/jboss/cache/jmx ...

Brian Stansberry brian.stansberry at jboss.com
Wed May 23 23:56:33 EDT 2007


  User: bstansberry
  Date: 07/05/23 23:56:33

  Modified:    tests/functional/org/jboss/cache/jmx 
                        LegacyConfigurationTest.java
  Log:
  Support old versions of renamed attributes
  Dependency inject MultiplexerService rather than doing JMX lookup
  
  Revision  Changes    Path
  1.2       +5 -4      JBossCache/tests/functional/org/jboss/cache/jmx/LegacyConfigurationTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LegacyConfigurationTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/jmx/LegacyConfigurationTest.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- LegacyConfigurationTest.java	23 May 2007 20:23:25 -0000	1.1
  +++ LegacyConfigurationTest.java	24 May 2007 03:56:33 -0000	1.2
  @@ -47,6 +47,7 @@
   import org.jboss.cache.xml.XmlHelper;
   import org.jgroups.ChannelFactory;
   import org.jgroups.JChannelFactory;
  +import org.jgroups.jmx.JChannelFactoryMBean;
   import org.w3c.dom.Element;
   
   import javax.management.MBeanServerInvocationHandler;
  @@ -62,7 +63,7 @@
    * Test of the CacheLegacyJmxWrapper.
    *
    * @author <a href="brian.stansberry at jboss.com">Brian Stansberry</a>
  - * @version $Revision: 1.1 $
  + * @version $Revision: 1.2 $
    */
   public class LegacyConfigurationTest extends CacheJmxWrapperTestBase
   {
  @@ -74,7 +75,7 @@
         wrapper = (CacheJmxWrapperMBean) MBeanServerInvocationHandler.newProxyInstance(mBeanServer, mBeanName, CacheJmxWrapperMBean.class, false);
   
         wrapper.setBuddyReplicationConfig(getBuddyReplicationConfig());
  -      wrapper.setCacheLoaderConfiguration(getCacheLoaderConfig());
  +      wrapper.setCacheLoaderConfig(getCacheLoaderConfig());
         wrapper.setCacheMode("REPL_SYNC");
         wrapper.setClusterName("LocalTest");
         wrapper.setClusterConfig(getClusterConfig());
  @@ -150,7 +151,7 @@
         Properties props = blc.getBuddyLocatorProperties();
         assertEquals("BR props", "2", props.get("numBuddies"));
   
  -      assertEquals("CacheLoaderConfig", getCacheLoaderConfig().toString(), wrapper.getCacheLoaderConfiguration().toString());
  +      assertEquals("CacheLoaderConfig", getCacheLoaderConfig().toString(), wrapper.getCacheLoaderConfig().toString());
         CacheLoaderConfig clc = c.getCacheLoaderConfig();
         assertEquals("CL passivation", false, clc.isPassivation());
         assertEquals("CL passivation", true, clc.isShared());
  @@ -247,7 +248,7 @@
         ObjectName on = new ObjectName("jgroups:service=Mux");
         mBeanServer.registerMBean(new org.jgroups.jmx.JChannelFactory(factory), on);
   
  -      wrapper.setMultiplexerService(on);
  +      wrapper.setMultiplexerService((JChannelFactoryMBean) MBeanServerInvocationHandler.newProxyInstance(mBeanServer, on, JChannelFactoryMBean.class, false));
   
         wrapper.start();
   
  
  
  



More information about the jboss-cvs-commits mailing list