Examples of purge()


Examples of org.apache.activemq.broker.jmx.QueueViewMBean.purge()

    public void testPurgeQueueWithActiveConsumer() throws Exception {
        createProducerAndSendMessages();
        QueueViewMBean proxy = getProxyToQueueViewMBean();
        createConsumer();
        proxy.purge();
        assertEquals("Queue size is not zero, it's " + proxy.getQueueSize(), 0,
                proxy.getQueueSize());
    }

    private QueueViewMBean getProxyToQueueViewMBean()
View Full Code Here

Examples of org.apache.activemq.broker.jmx.QueueViewMBean.purge()

    public void testPurgeLargeQueue() throws Exception {
        applyBrokerSpoolingPolicy();
        createProducerAndSendMessages(NUM_TO_SEND);
        QueueViewMBean proxy = getProxyToQueueViewMBean();
        LOG.info("purging..");
        proxy.purge();
        assertEquals("Queue size is not zero, it's " + proxy.getQueueSize(), 0,
                proxy.getQueueSize());
        assertTrue("cache is disabled, temp store being used", !proxy.isCacheEnabled());
    }
View Full Code Here

Examples of org.apache.activemq.broker.jmx.QueueViewMBean.purge()

        createProducerAndSendMessages(NUM_TO_SEND);
        QueueViewMBean proxy = getProxyToQueueViewMBean();
        createConsumer();
        long start = System.currentTimeMillis();
        LOG.info("purging..");
        proxy.purge();
        LOG.info("purge done: " + (System.currentTimeMillis() - start) + "ms");
        assertEquals("Queue size is not zero, it's " + proxy.getQueueSize(), 0,
                proxy.getQueueSize());
        assertEquals("usage goes to duck", 0, proxy.getMemoryPercentUsage());
    }
View Full Code Here

Examples of org.apache.activemq.broker.jmx.QueueViewMBean.purge()

    return brokers;
  }
 
  public void purgeQueue(ActiveMQDestination destination) throws Exception {
    QueueViewMBean queue = getQueue(destination.getPhysicalName());
    queue.purge();
  }
 
  public ManagementContext getManagementContext() {
    throw new IllegalStateException("not supported");
  }
View Full Code Here

Examples of org.apache.activemq.broker.region.Queue.purge()

    public void purgeQueue(ActiveMQDestination destination) throws Exception {
        Set destinations = getManagedBroker().getQueueRegion().getDestinations(destination);
        for (Iterator i = destinations.iterator(); i.hasNext();) {
            Queue regionQueue = (Queue)i.next();
            regionQueue.purge();
        }
    }
}
View Full Code Here

Examples of org.apache.continuum.purge.ContinuumPurgeManager.purge()

       
        Schedule schedule = (Schedule) jobDetail.getJobDataMap().get( ContinuumSchedulerConstants.SCHEDULE );

        try
        {
            purgeManager.purge( schedule );
        }
        catch ( ContinuumPurgeManagerException e )
        {
            logger.error( "Error purging for job" + jobName + ".", e );
        }
View Full Code Here

Examples of org.apache.cxf.systest.ws.util.MessageFlow.purge()

        mf.verifyPartialResponses(3);       
        mf.purgePartialResponses();
 
        expectedActions = new String[] {RMConstants.getCreateSequenceResponseAction()};
        mf.verifyActionsIgnoringPartialResponses(expectedActions);
        mf.purge();
       
        try {
            Thread.sleep(3 * 1000);
        } catch (InterruptedException ex) {
            // ignore
View Full Code Here

Examples of org.apache.cxf.systest.ws.util.MessageFlow.purge()

        mf.purgePartialResponses();
       
        expectedActions = new String[] {RMConstants.getCreateSequenceResponseAction()};
        mf.verifyActions(expectedActions, false);
       
        mf.purge();
        assertEquals(0, outRecorder.getOutboundMessages().size());
        assertEquals(0, inRecorder.getInboundMessages().size());

        // allow resends to kick in
        // await multiple of 3 resends to avoid shutting down server
View Full Code Here

Examples of org.apache.cxf.systest.ws.util.MessageFlow.purge()

        expectedActions = new String[] {RMConstants.getCreateSequenceResponseAction(),
                                        GREETME_RESPONSE_ACTION,
                                        GREETME_RESPONSE_ACTION};
        mf.verifyActions(expectedActions, false);
        mf.verifyMessageNumbers(new String[] {null, "1", "2"}, false);
        mf.purge();
       

        // one standalone acknowledgement should have been sent from the client and one
        // should have been received from the server
  
View Full Code Here

Examples of org.apache.cxf.systest.ws.util.MessageFlow.purge()

        mf.verifyPartialResponses(3);       
        mf.purgePartialResponses();
 
        expectedActions = new String[] {RMConstants.getCreateSequenceResponseAction()};
        mf.verifyActionsIgnoringPartialResponses(expectedActions);
        mf.purge();
       
        try {
            Thread.sleep(3 * 1000);
        } catch (InterruptedException ex) {
            // ignore
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.