Package org.jboss.test.messaging.tools.container

Examples of org.jboss.test.messaging.tools.container.LocalTestServer


      if (servers[i] == null)
      {
         log.info("Server not already created, so creating...");
         if (isLocal())
         {
            servers[i] = new ServerHolder(new LocalTestServer(i), false);
         }
         else
         {
            // Need to spawn a new server - we DON'T use start-rmi-server any more, so we know if the servers[i] is null
            // the server is not there - killing a server sets servers[i] to null
View Full Code Here


     
      Connection conn = null;

      try
      {
         localServer = new LocalTestServer();

         localServer.start("all", true);
         localServer.deployQueue("Queue", null, false);

         // lookup the connection factory and the queue which we'll send to the client VM via a
View Full Code Here

      if (servers[i] == null)
      {
        log.info("Server not already created, so creating...");
         if (isLocal())
         {
            servers[i] = new ServerHolder(new LocalTestServer(i), false);
         }
         else
         {
           //Need to spawn a new server - we DON'T use start-rmi-server any more, so we know if the servers[i] is null
           //the server is not there - killing a server sets servers[i] to null
View Full Code Here

      testStartupOnlyAttribute("DefaultTopicJNDIContext", "/mytopics", "/othertopics");
   }
  
   public void testCannotSetNegativeServerPeerID() throws Exception
   {
      LocalTestServer server = new LocalTestServer();
      ServiceAttributeOverrides overrides = new ServiceAttributeOverrides();
      // Can't use server.getServerPeerObjectName() here since it's not known to the server yet.
      overrides.put(ServiceContainer.SERVER_PEER_OBJECT_NAME, "ServerPeerID", "-10");
     
      try
      {
         server.start("all", overrides, false, true);
         fail("Should have thrown an exception when setting ServerPeerID to a negative value");
      }
      catch (RuntimeMBeanException rmbe)
      {
         assertTrue(rmbe.getCause() instanceof IllegalArgumentException);
      }
      finally
      {
        server.stop();
      }
   }
View Full Code Here

      testStartupOnlyAttribute("DefaultTopicJNDIContext", "/mytopics", "/othertopics");
   }
  
   public void testCannotSetNegativeServerPeerID() throws Exception
   {
      LocalTestServer server = new LocalTestServer();
      ServiceAttributeOverrides overrides = new ServiceAttributeOverrides();
      // Can't use server.getServerPeerObjectName() here since it's not known to the server yet.
      overrides.put(ServiceContainer.SERVER_PEER_OBJECT_NAME, "ServerPeerID", "-10");
     
      try
      {
         server.start("all", overrides, false, true);
         fail("Should have thrown an exception when setting ServerPeerID to a negative value");
      }
      catch (RuntimeMBeanException rmbe)
      {
         assertTrue(rmbe.getCause() instanceof IllegalArgumentException);
      }
      finally
      {
        server.stop();
      }
   }
View Full Code Here

      }
   }
  
   public void testServerPeerIDLimit() throws Exception
   {
      LocalTestServer server = new LocalTestServer();
      ServiceAttributeOverrides overrides = new ServiceAttributeOverrides();
      // Can't use server.getServerPeerObjectName() here since it's not known to the server yet.
      overrides.put(ServiceContainer.SERVER_PEER_OBJECT_NAME, "ServerPeerID", "65535");
     
      try
      {
         server.start("all", overrides, false, true);
      }
      catch (RuntimeMBeanException rmbe)
      {
         fail("Large ServerPeerID should be allowed (0 - 65535)");
      }
      finally
      {
         server.stop();
      }
   }
View Full Code Here

      if (servers[i] == null)
      {
         log.info("Server not already created, so creating...");
         if (isLocal())
         {
            servers[i] = new ServerHolder(new LocalTestServer(i), false);
         }
         else
         {
            // Need to spawn a new server - we DON'T use start-rmi-server any more, so we know if the servers[i] is null
            // the server is not there - killing a server sets servers[i] to null
View Full Code Here

      if (servers[i] == null)
      {
         log.info("Server not already created, so creating...");
         if (isLocal())
         {
            servers[i] = new ServerHolder(new LocalTestServer(i), false);
         }
         else
         {
            // Need to spawn a new server - we DON'T use start-rmi-server any more, so we know if the servers[i] is null
            // the server is not there - killing a server sets servers[i] to null
View Full Code Here

      if (servers[i] == null)
      {
         log.info("Server not already created, so creating...");
         if (isLocal())
         {
            servers[i] = new ServerHolder(new LocalTestServer(i), false);
         }
         else
         {
            // Need to spawn a new server - we DON'T use start-rmi-server any more, so we know if the servers[i] is null
            // the server is not there - killing a server sets servers[i] to null
View Full Code Here

     ServerManagement.kill(1);
    
      ServerManagement.stop();
     
      // Start the local server
      localServer = new LocalTestServer();
     
      // Start all the services locally
      localServer.start("all", true);

      // This crash test is relying on a precise value of LeaseInterval, so we don't rely on
View Full Code Here

TOP

Related Classes of org.jboss.test.messaging.tools.container.LocalTestServer

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.