Examples of JMSServerManagerImpl


Examples of org.hornetq.jms.server.impl.JMSServerManagerImpl

      conf.getAcceptorConfigurations()
          .add(new TransportConfiguration("org.hornetq.core.remoting.impl.invm.InVMAcceptorFactory"));
      server = HornetQServers.newHornetQServer(conf, mbeanServer, false);
      server.start();

      serverManager = new JMSServerManagerImpl(server);
      serverManager.start();
      serverManager.setContext(new InVMContext());
      serverManager.activated();

      clientID = RandomUtil.randomString();
View Full Code Here

Examples of org.hornetq.jms.server.impl.JMSServerManagerImpl

      HornetQSecurityManager sm = new HornetQSecurityManagerImpl();

      HornetQServer liveServer = new HornetQServerImpl(fc, sm);

      liveJMSServer = new JMSServerManagerImpl(liveServer, "server-start-stop-jms-config1.xml");

      liveJMSServer.setContext(null);

      liveJMSServer.start();
   }
View Full Code Here

Examples of org.hornetq.jms.server.impl.JMSServerManagerImpl

      TopicConfiguration topicConfig = new TopicConfigurationImpl(RandomUtil.randomString(),
                                                                  "/topic/binding1",
                                                                  "/topic/binding2");
      jmsConfiguration.getTopicConfigurations().add(topicConfig);

      JMSServerManager server = new JMSServerManagerImpl(coreServer, jmsConfiguration);
      server.start();

      for (String binding : cfConfig.getBindings())
      {
         Object o = context.lookup(binding);
         Assert.assertNotNull(o);
         Assert.assertTrue(o instanceof ConnectionFactory);
         ConnectionFactory cf = (ConnectionFactory)o;
         Connection connection = cf.createConnection();
         connection.close();
      }

      for (String binding : queueConfig.getBindings())
      {
         Object o = context.lookup(binding);
         Assert.assertNotNull(o);
         Assert.assertTrue(o instanceof Queue);
         Queue queue = (Queue)o;
         Assert.assertEquals(queueConfig.getName(), queue.getQueueName());
      }

      for (String binding : topicConfig.getBindings())
      {
         Object o = context.lookup(binding);
         Assert.assertNotNull(o);
         Assert.assertTrue(o instanceof Topic);
         Topic topic = (Topic)o;
         Assert.assertEquals(topicConfig.getName(), topic.getTopicName());
      }

      server.stop();
   }
View Full Code Here

Examples of org.hornetq.jms.server.impl.JMSServerManagerImpl

      conf.setSecurityEnabled(false);
      conf.setJMXManagementEnabled(true);
      conf.getAcceptorConfigurations()
          .add(new TransportConfiguration("org.hornetq.core.remoting.impl.invm.InVMAcceptorFactory"));
      server = HornetQServers.newHornetQServer(conf, false);
      jmsServer = new JMSServerManagerImpl(server);
      jmsServer.setContext(new NullInitialContext());
      jmsServer.start();
      jmsServer.createQueue(false, ExceptionListenerTest.Q_NAME, null, true, ExceptionListenerTest.Q_NAME);
      cf = (HornetQConnectionFactory) HornetQJMSClient.createConnectionFactory(new TransportConfiguration("org.hornetq.core.remoting.impl.invm.InVMConnectorFactory"));
      cf.setBlockOnDurableSend(true);
View Full Code Here

Examples of org.hornetq.jms.server.impl.JMSServerManagerImpl

      config.getDiscoveryGroupConfigurations().put("mygroup", dcg);
      HornetQServer server = createServer(false, config);

      deploymentManager = new FileDeploymentManager(config.getFileDeployerScanPeriod());

      jmsServer = new JMSServerManagerImpl(server);
      context = new InVMContext();
      jmsServer.setContext(context);
      jmsServer.start();

   }
View Full Code Here

Examples of org.hornetq.jms.server.impl.JMSServerManagerImpl

      conf0.getAcceptorConfigurations()
           .add(new TransportConfiguration("org.hornetq.core.remoting.impl.invm.InVMAcceptorFactory"));
      server0 = HornetQServers.newHornetQServer(conf0, false);

      context0 = new InVMContext();
      jmsServer0 = new JMSServerManagerImpl(server0);
      jmsServer0.setContext(context0);
      jmsServer0.start();

      Configuration conf1 = new ConfigurationImpl();
      conf1.setSecurityEnabled(false);
      params1 = new HashMap<String, Object>();
      params1.put(TransportConstants.SERVER_ID_PROP_NAME, 1);
      conf1.getAcceptorConfigurations()
           .add(new TransportConfiguration("org.hornetq.core.remoting.impl.invm.InVMAcceptorFactory", params1));

      server1 = HornetQServers.newHornetQServer(conf1, false);

      context1 = new InVMContext();

      jmsServer1 = new JMSServerManagerImpl(server1);
      jmsServer1.setContext(context1);
      jmsServer1.start();

      createQueue("sourceQueue", 0);
View Full Code Here

Examples of org.hornetq.jms.server.impl.JMSServerManagerImpl

      conf.getAcceptorConfigurations().add(new TransportConfiguration(NettyAcceptorFactory.class.getName()));
      conf.getConnectorConfigurations().put("netty", new TransportConfiguration(NettyConnectorFactory.class.getName()));

      server = HornetQServers.newHornetQServer(conf, usePersistence());

      jmsServer = new JMSServerManagerImpl(server);
      context = new InVMContext();
      jmsServer.setContext(context);
      jmsServer.start();

      registerConnectionFactory();
View Full Code Here

Examples of org.hornetq.jms.server.impl.JMSServerManagerImpl

      JMSConfigurationImpl jmsconfig = new JMSConfigurationImpl();
      //jmsconfig.getTopicConfigurations().add(new TopicConfigurationImpl("t1", "topic/t1"));
     

      server2 = HornetQServers.newHornetQServer(conf2, false);
      jmsServer2 = new JMSServerManagerImpl(server2, jmsconfig);
      context2 = new InVMContext();
      jmsServer2.setContext(context2);
   }
View Full Code Here

Examples of org.hornetq.jms.server.impl.JMSServerManagerImpl

     
      JMSConfigurationImpl jmsconfig = new JMSConfigurationImpl();
      //jmsconfig.getTopicConfigurations().add(new TopicConfigurationImpl("t1", "topic/t1"));
     
      server1 = HornetQServers.newHornetQServer(conf1, false);
      jmsServer1 = new JMSServerManagerImpl(server1, jmsconfig);
      context1 = new InVMContext();
      jmsServer1.setContext(context1);
   }
View Full Code Here

Examples of org.hornetq.jms.server.impl.JMSServerManagerImpl

      conf.getAcceptorConfigurations().add(new TransportConfiguration(InVMAcceptorFactory.class.getName()));
      conf.setFileDeploymentEnabled(false);
      server = HornetQServers.newHornetQServer(conf, mbeanServer, false);
      server.start();

      serverManager = new JMSServerManagerImpl(server);
      context = new InVMContext();
      serverManager.setContext(context);
      serverManager.start();
      serverManager.activated();
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.