Examples of JMSServerManager


Examples of org.hornetq.jms.server.JMSServerManager

    }

    /** {@inheritDoc} */
    public synchronized void start(final StartContext context) throws StartException {
        context.asynchronous();
        final JMSServerManager jmsManager = jmsServer.getValue();

        executorInjector.getValue().execute(new Runnable() {
            @Override
            public void run() {
                try {
                    jmsManager.createConnectionFactory(false, configuration, configuration.getBindings());
                    context.complete();
                } catch (Throwable e) {
                    context.failed(MESSAGES.failedToCreate(e, "connection-factory"));
                }
            }
View Full Code Here

Examples of org.hornetq.jms.server.JMSServerManager

    /** {@inheritDoc} */
    public synchronized void stop(final StopContext context) {
        // JMS Server Manager uses locking which waits on service completion, use async to prevent starvation
        context.asynchronous();
        final JMSServerManager jmsManager = jmsServer.getValue();

        executorInjector.getValue().execute(new Runnable() {
            @Override
            public void run() {
                try {
                    jmsManager.destroyConnectionFactory(name);
                } catch (Throwable e) {
                    MESSAGING_LOGGER.failedToDestroy("connection-factory", name);
                }
                context.complete();
            }
View Full Code Here

Examples of org.hornetq.jms.server.JMSServerManager

        this.jndi = jndi;
    }

    /** {@inheritDoc} */
    public synchronized void start(final StartContext context) throws StartException {
        final JMSServerManager jmsManager = jmsServer.getValue();

        context.asynchronous();
        executorInjector.getValue().execute(new Runnable() {
            @Override
            public void run() {
                try {
                    jmsManager.createTopic(false, name, jndi);
                    context.complete();
                } catch (Throwable e) {
                    context.failed(MESSAGES.failedToCreate(e, "queue"));
                }
            }
View Full Code Here

Examples of org.hornetq.jms.server.JMSServerManager

        });
    }

    /** {@inheritDoc} */
    public synchronized void stop(final StopContext context) {
        final JMSServerManager jmsManager = jmsServer.getValue();

        // JMS Server Manager uses locking which waits on service completion, use async to prevent starvation
        context.asynchronous();
        executorInjector.getValue().execute(new Runnable() {
            @Override
            public void run() {
                try {
                    jmsManager.removeTopicFromJNDI(name);
                } catch (Throwable e) {
                    MESSAGING_LOGGER.failedToDestroy(e, "jms topic", name);
                }
                context.complete();
            }
View Full Code Here

Examples of org.hornetq.jms.server.JMSServerManager

    /** {@inheritDoc} */
    public synchronized void start(final StartContext context) throws StartException {
        context.asynchronous();

        final JMSServerManager jmsManager = jmsServer.getValue();
        executorInjector.getValue().execute(new Runnable() {
            @Override
            public void run() {
                try {
                    jmsManager.createQueue(false, queueName, selectorString, durable, jndi);
                    context.complete();
                } catch (Throwable e) {
                    context.failed(MESSAGES.failedToCreate(e, "queue"));
                }
            }
View Full Code Here

Examples of org.hornetq.jms.server.JMSServerManager

    /** {@inheritDoc} */
    public synchronized void stop(final StopContext context) {
        // JMS Server Manager uses locking which waits on service completion, use async to prevent starvation
        context.asynchronous();

        final JMSServerManager jmsManager = jmsServer.getValue();
        executorInjector.getValue().execute(new Runnable() {
            @Override
            public void run() {
                try {
                    jmsManager.removeQueueFromJNDI(queueName);
                } catch (Throwable e) {
                    MESSAGING_LOGGER.failedToDestroy(e, "queue", queueName);
                }
                context.complete();
            }
View Full Code Here

Examples of org.hornetq.jms.server.JMSServerManager

    }

    /** {@inheritDoc} */
    public synchronized void start(final StartContext context) throws StartException {
        context.asynchronous();
        final JMSServerManager jmsManager = jmsServer.getValue();

        executorInjector.getValue().execute(new Runnable() {
            @Override
            public void run() {
                try {
                    jmsManager.createConnectionFactory(false, configuration, configuration.getBindings());
                    context.complete();
                } catch (Throwable e) {
                    context.failed(MESSAGES.failedToCreate(e, "connection-factory"));
                }
            }
View Full Code Here

Examples of org.hornetq.jms.server.JMSServerManager

    /** {@inheritDoc} */
    public synchronized void stop(final StopContext context) {
        // JMS Server Manager uses locking which waits on service completion, use async to prevent starvation
        context.asynchronous();
        final JMSServerManager jmsManager = jmsServer.getValue();

        executorInjector.getValue().execute(new Runnable() {
            @Override
            public void run() {
                try {
                    jmsManager.destroyConnectionFactory(name);
                } catch (Throwable e) {
                    MESSAGING_LOGGER.failedToDestroy("connection-factory", name);
                }
                context.complete();
            }
View Full Code Here

Examples of org.hornetq.jms.server.JMSServerManager

        this.jndi = jndi;
    }

    /** {@inheritDoc} */
    public synchronized void start(final StartContext context) throws StartException {
        final JMSServerManager jmsManager = jmsServer.getValue();

        context.asynchronous();
        executorInjector.getValue().execute(new Runnable() {
            @Override
            public void run() {
                try {
                    jmsManager.createTopic(false, name, jndi);
                    context.complete();
                } catch (Throwable e) {
                    context.failed(MESSAGES.failedToCreate(e, "queue"));
                }
            }
View Full Code Here

Examples of org.hornetq.jms.server.JMSServerManager

        });
    }

    /** {@inheritDoc} */
    public synchronized void stop(final StopContext context) {
        final JMSServerManager jmsManager = jmsServer.getValue();

        // JMS Server Manager uses locking which waits on service completion, use async to prevent starvation
        context.asynchronous();
        executorInjector.getValue().execute(new Runnable() {
            @Override
            public void run() {
                try {
                    jmsManager.removeTopicFromJNDI(name);
                } catch (Throwable e) {
                    MESSAGING_LOGGER.failedToDestroy(e, "jms topic", name);
                }
                context.complete();
            }
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.