Examples of TransactionLog


Examples of org.apache.geronimo.transaction.manager.TransactionLog

        if (defaultTransactionTimeoutSeconds == null) {
            defaultTransactionTimeoutSeconds = (int) TimeUnit.SECONDS.convert(defaultTransactionTimeout.getTime(), defaultTransactionTimeout.getUnit());
        }

        XidFactory xidFactory = null;
        TransactionLog txLog = null;
        if (txRecovery) {
            SystemInstance.get().setComponent(XAResourceWrapper.class, new GeronimoXAResourceWrapper());
           
            xidFactory = new XidFactoryImpl(tmId == null ? DEFAULT_TM_ID: tmId);
            txLog = new HOWLLog(bufferClassName == null ? "org.objectweb.howl.log.BlockLogBuffer" : bufferClassName,
View Full Code Here

Examples of org.apache.geronimo.transaction.manager.TransactionLog

    }

    protected abstract String getResultFileName();

    public long testTransactionLog(int workers, int xidCount) throws Exception {
        TransactionLog transactionLog = createTransactionLog();

        xid = new XidImpl2(new byte[Xid.MAXGTRIDSIZE]);
        //TODO Supply an actual list
        names = Collections.EMPTY_LIST;
View Full Code Here

Examples of org.apache.geronimo.transaction.manager.TransactionLog

        if (defaultTransactionTimeoutSeconds == null) {
            defaultTransactionTimeoutSeconds = (int) TimeUnit.SECONDS.convert(defaultTransactionTimeout.getTime(), defaultTransactionTimeout.getUnit());
        }

        XidFactory xidFactory = null;
        TransactionLog txLog = null;
        if (txRecovery) {
            SystemInstance.get().setComponent(XAResourceWrapper.class, new GeronimoXAResourceWrapper());
           
            xidFactory = new XidFactoryImpl(tmId == null ? DEFAULT_TM_ID: tmId);
            txLog = new HOWLLog(bufferClassName == null ? "org.apache.howl.log.BlockLogBuffer" : bufferClassName,
View Full Code Here

Examples of org.apache.geronimo.transaction.manager.TransactionLog

    }

    protected abstract String getResultFileName();

    public long testTransactionLog(int workers, int xidCount) throws Exception {
        TransactionLog transactionLog = createTransactionLog();

        xid = new XidImpl2(new byte[Xid.MAXGTRIDSIZE]);
        //TODO Supply an actual list
        names = Collections.EMPTY_LIST;
View Full Code Here

Examples of org.apache.geronimo.transaction.manager.TransactionLog

    }

    protected abstract String getResultFileName();

    public long testTransactionLog(int workers, int xidCount) throws Exception {
        TransactionLog transactionLog = createTransactionLog();

        xid = new XidImpl2(new byte[Xid.MAXGTRIDSIZE]);
        //TODO Supply an actual list
        names = Collections.EMPTY_LIST;
View Full Code Here

Examples of org.apache.geronimo.transaction.manager.TransactionLog

        if (defaultTransactionTimeoutSeconds == null) {
            defaultTransactionTimeoutSeconds = (int) TimeUnit.SECONDS.convert(defaultTransactionTimeout.getTime(), defaultTransactionTimeout.getUnit());
        }

        XidFactory xidFactory = null;
        TransactionLog txLog = null;
        if (txRecovery) {
            SystemInstance.get().setComponent(XAResourceWrapper.class, new GeronimoXAResourceWrapper());
           
            xidFactory = new XidFactoryImpl(tmId == null ? DEFAULT_TM_ID: tmId);
            txLog = new HOWLLog(bufferClassName == null ? "org.apache.howl.log.BlockLogBuffer" : bufferClassName,
View Full Code Here

Examples of org.apache.qpid.server.store.TransactionLog

        _state = TransactionState.ABORTED;
    }

    public static TransactionLog createTestTransactionLog(final MockStoreTransaction storeTransaction)
    {
        return new TransactionLog()
        {
            public void configureTransactionLog(String name, TransactionLogRecoveryHandler recoveryHandler,
                    Configuration storeConfiguration, LogSubject logSubject) throws Exception
            {
            }
View Full Code Here

Examples of org.apache.qpid.server.store.TransactionLog

                public String getResourceName()
                {
                    return queueName.asString();
                }
            };
            TransactionLog log = (TransactionLog) store;
            TransactionLog.Transaction txn = log.newTransaction();
            txn.enqueueMessage(mockQueue, messageId);
            txn.commitTran();
        }
        finally
        {
View Full Code Here

Examples of org.apache.qpid.server.store.TransactionLog

     * in the TransactionLog interface implemented by the store, and verifying the
     * behaviour using BDB implementation methods.
     */
    public void testTranCommit() throws Exception
    {
        TransactionLog log = getVirtualHost().getTransactionLog();

        BDBMessageStore bdbStore = assertBDBStore(log);

        final AMQShortString mockQueueName = new AMQShortString("queueName");
       
        TransactionLogResource mockQueue = new TransactionLogResource()
        {
            public String getResourceName()
            {
                return mockQueueName.asString();
            }
        };
       
        TransactionLog.Transaction txn = log.newTransaction();
       
        txn.enqueueMessage(mockQueue, 1L);
        txn.enqueueMessage(mockQueue, 5L);
        txn.commitTran();

View Full Code Here

Examples of org.apache.qpid.server.store.TransactionLog

     * implemented by the store, and verifying the behaviour using BDB
     * implementation methods.
     */
    public void testTranRollbackBeforeCommit() throws Exception
    {
        TransactionLog log = getVirtualHost().getTransactionLog();

        BDBMessageStore bdbStore = assertBDBStore(log);

        final AMQShortString mockQueueName = new AMQShortString("queueName");
       
        TransactionLogResource mockQueue = new TransactionLogResource()
        {
            public String getResourceName()
            {
                return mockQueueName.asString();
            }
        };
       
        TransactionLog.Transaction txn = log.newTransaction();
       
        txn.enqueueMessage(mockQueue, 21L);
        txn.abortTran();
       
        txn = log.newTransaction();
        txn.enqueueMessage(mockQueue, 22L);
        txn.enqueueMessage(mockQueue, 23L);
        txn.commitTran();

        List<Long> enqueuedIds = bdbStore.getEnqueuedMessages(mockQueueName);
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.