Package org.apache.activemq.util

Examples of org.apache.activemq.util.ServiceStopper.throwFirstException()


                    // Release the started Latch since another thread could be
                    // stuck waiting for it to start up.
                    startedLatch.countDown();
                    startedLatch.countDown();
                    localStartedLatch.countDown();
                    ss.throwFirstException();
                }
            }
            LOG.info(configuration.getBrokerName() + " bridge to " + remoteBrokerName + " stopped");
        }
    }
View Full Code Here


        MDC.remove("activemq.broker");

        // and clear start date
        startDate = null;

        stopper.throwFirstException();
    }

    public boolean checkQueueSize(String queueName) {
        long count = 0;
        long queueSize = 0;
View Full Code Here

    @Override
    public void stop() throws Exception {
        ServiceStopper ss = new ServiceStopper();
        ss.stop(discoveryAgent);
        ss.stop(next);
        ss.throwFirstException();
    }

    public void onServiceAdd(DiscoveryEvent event) {
        String url = event.getServiceName();
        if (url != null) {
View Full Code Here

        }
        shuttingDown.set(true);
        ServiceStopper ss = new ServiceStopper();
        ss.stop(localTransport);
        ss.stop(remoteTransport);
        ss.throwFirstException();
    }

}
View Full Code Here

        }
        for (Iterator<ProxyConnection> iter = connections.iterator(); iter.hasNext();) {
            LOG.info("Connector stopped: Stopping proxy.");
            ss.stop(iter.next());
        }
        ss.throwFirstException();
        LOG.info("Proxy Connector " + getName() + " Stopped");
    }

    // Properties
    // -------------------------------------------------------------------------
View Full Code Here

        for (TransportConnection connection : connections) {
            ss.stop(connection);
        }
        server = null;
        ss.throwFirstException();
        LOG.info("Connector " + getName() + " Stopped");
    }

    // Implementation methods
    // -------------------------------------------------------------------------
View Full Code Here

    public void stop() throws Exception {
        started = false;
        this.scheduler.cancel(purgeInactiveDestinationsTask);
        ServiceStopper ss = new ServiceStopper();
        doStop(ss);
        ss.throwFirstException();
        // clear the state
        clientIdSet.clear();
        connections.clear();
        destinations.clear();
        brokerInfos.clear();
View Full Code Here

                    // stuck waiting for it to start up.
                    startedLatch.countDown();
                    startedLatch.countDown();
                    localStartedLatch.countDown();

                    ss.throwFirstException();
                }
            }

            if (LOG.isInfoEnabled()) {
                LOG.info(configuration.getBrokerName() + " bridge to " + remoteBrokerName + " stopped");
View Full Code Here

            remoteBroker.oneway(new ShutdownInfo());
        } finally {
            ServiceStopper ss = new ServiceStopper();
            ss.stop(localBroker);
            ss.stop(remoteBroker);
            ss.throwFirstException();
        }
    }

    public void serviceRemoteException(Throwable error) {
        LOG.info("Unexpected remote exception: " + error);
View Full Code Here

    public void stop() throws Exception {
        started = false;
        this.scheduler.cancel(purgeInactiveDestinationsTask);
        ServiceStopper ss = new ServiceStopper();
        doStop(ss);
        ss.throwFirstException();
        // clear the state
        clientIdSet.clear();
        connections.clear();
        destinations.clear();
        brokerInfos.clear();
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.