Package org.mule.util.journal.queue

Examples of org.mule.util.journal.queue.LocalTxQueueTransactionRecoverer


        Serializable value = persistentTransactionContext.poll(inQueue, 100000);
        assertThat(inQueue.poll(10), IsNull.nullValue());
        assertThat(value, notNullValue());
        txLog.close();
        txLog = new LocalTxQueueTransactionJournal(temporaryFolder.getRoot().getAbsolutePath(), muleContext);
        LocalTxQueueTransactionRecoverer queueTransactionRecoverer = new LocalTxQueueTransactionRecoverer(txLog, createQueueProvider(inQueue));
        queueTransactionRecoverer.recover();
        Serializable muleEvent = inQueue.poll(10);
        assertThat(muleEvent, notNullValue());
        assertThat(testEvent.equals(muleEvent), is(true));
    }
View Full Code Here


        MuleEvent testEvent = getTestEvent(MESSAGE_CONTENT);
        inQueue.offer(testEvent, 0, 10);
        persistentTransactionContext.poll(inQueue, 10);
        txLog.close();
        txLog = new LocalTxQueueTransactionJournal(temporaryFolder.getRoot().getAbsolutePath(), muleContext);
        LocalTxQueueTransactionRecoverer queueTransactionRecoverer = new LocalTxQueueTransactionRecoverer(txLog, createQueueProvider(inQueue));
        queueTransactionRecoverer.recover();
        Serializable muleEvent = inQueue.poll(10);
        assertThat(muleEvent, notNullValue());
        assertThat(testEvent.equals(muleEvent), is(true));
        muleEvent = inQueue.poll(10);
        assertThat(muleEvent, IsNull.nullValue());
View Full Code Here

        MuleEvent testEvent = getTestEvent(MESSAGE_CONTENT);
        persistentTransactionContext.offer(outQueue, testEvent, 10);
        assertThat(outQueue.poll(10), IsNull.nullValue());
        txLog.close();
        txLog = new LocalTxQueueTransactionJournal(temporaryFolder.getRoot().getAbsolutePath(), muleContext);
        LocalTxQueueTransactionRecoverer queueTransactionRecoverer = new LocalTxQueueTransactionRecoverer(txLog, createQueueProvider(outQueue));
        queueTransactionRecoverer.recover();
        Serializable muleEvent = outQueue.poll(10);
        assertThat(muleEvent, nullValue());
    }
View Full Code Here

        {
            //expected
        }
        txLog.close();
        txLog = new TestTransactionLogger(temporaryFolder.getRoot().getAbsolutePath(), muleContext);
        LocalTxQueueTransactionRecoverer queueTransactionRecoverer = new LocalTxQueueTransactionRecoverer(txLog, createQueueProvider(outQueue));
        queueTransactionRecoverer.recover();
        Serializable muleEvent = outQueue.poll(10);
        assertThat(muleEvent, nullValue());
    }
View Full Code Here

    @Override
    public void initialise() throws InitialisationException
    {
        String workingDirectory = getMuleContext().getConfiguration().getWorkingDirectory();
        localTxTransactionJournal = new LocalTxQueueTransactionJournal(workingDirectory + File.separator + "queue-tx-log", getMuleContext());
        localTxQueueTransactionRecoverer = new LocalTxQueueTransactionRecoverer(localTxTransactionJournal, this);
        xaTransactionJournal = new XaTxQueueTransactionJournal(workingDirectory + File.separator + "queue-xa-tx-log", getMuleContext());
        xaTransactionRecoverer = new XaTransactionRecoverer(xaTransactionJournal, this);
    }
View Full Code Here

TOP

Related Classes of org.mule.util.journal.queue.LocalTxQueueTransactionRecoverer

Copyright © 2018 www.massapicom. 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.