Examples of JMSServerManagerImpl


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

         final HornetQServer server = HornetQServers.newHornetQServer(conf, false);

         Hashtable<String, String> env = new Hashtable<String, String>();
         env.put("java.naming.factory.initial", "org.jnp.interfaces.NamingContextFactory");
         env.put("java.naming.factory.url.pkgs", "org.jboss.naming:org.jnp.interfaces");
         JMSServerManager serverManager = new JMSServerManagerImpl(server);
         serverManager.setContext(new InitialContext(env));
         serverManager.start();

         System.out.println("Server started, ready to start client test");

         // create the reader before printing OK so that if the test is quick
         // we will still capture the STOP message sent by the client
View Full Code Here

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

        //
    }

    public synchronized void start(StartContext context) throws StartException {
        try {
            final JMSServerManager jmsServer = new JMSServerManagerImpl(hornetQServer.getValue(), new AS7BindingRegistry(context.getController().getServiceContainer()));

            try {
                // FIXME - we also need the TCCL here in case the JMSServerManager starts the HornetQServer
                final ClassLoader loader = getClass().getClassLoader();
                SecurityActions.setContextClassLoader(loader);
                jmsServer.start();
            } finally {
                SecurityActions.setContextClassLoader(null);
            }
            this.jmsServer = jmsServer;
        } catch (Exception e) {
View Full Code Here

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

      Configuration config = new ConfigurationImpl();
      config.setFileDeploymentEnabled(false);
      config.setSecurityEnabled(false);
      config.getAcceptorConfigurations().add(new TransportConfiguration(InVMAcceptorFactory.class.getName()));
      InVMContext context = new InVMContext();
      jmsServer = new JMSServerManagerImpl(HornetQServers.newHornetQServer(config, false));
      jmsServer.setContext(context);
      jmsServer.start();

      jmsServer.createQueue(false, JMSBridgeImplTest.SOURCE, null, true, "/queue/" + JMSBridgeImplTest.SOURCE);
      jmsServer.createQueue(false, JMSBridgeImplTest.TARGET, null, true, "/queue/" + JMSBridgeImplTest.TARGET);
View Full Code Here

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

      cfConfig.setRetryInterval(1000);
      cfConfig.setRetryIntervalMultiplier(1.0);
      cfConfig.setReconnectAttempts(-1);
      cfConfig.setFailoverOnServerShutdown(true);
      configuration.getConnectionFactoryConfigurations().add(cfConfig);
      serverManager = new JMSServerManagerImpl(server, configuration);
      serverManager.start();

      listener = new Listener();

      exceptionLatch = new CountDownLatch(1);
View Full Code Here

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

      conf.getAcceptorConfigurations().add(new TransportConfiguration(INVM_ACCEPTOR_FACTORY));
      conf.getConnectorConfigurations().put("invm", new TransportConfiguration(INVM_CONNECTOR_FACTORY));

      server = HornetQServers.newHornetQServer(conf, mbeanServer, 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.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.createConnectionFactoryWithoutHA(JMSFactoryType.CF, new TransportConfiguration("org.hornetq.core.remoting.impl.invm.InVMConnectorFactory"));
      cf.setBlockOnDurableSend(true);
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

      JMSConfiguration jmsConfig = new JMSConfigurationImpl();
      jmsConfig.getQueueConfigurations()
               .add(new JMSQueueConfigurationImpl(getQueueName(), null, false, getQueueName()));
      jmsConfig.getTopicConfigurations().add(new TopicConfigurationImpl(getTopicName(), getTopicName()));
      server = new JMSServerManagerImpl(hornetQServer, jmsConfig);
      server.setContext(new InVMContext());
      return server;
   }
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.