Package com.sleepycat.je.rep.txn

Examples of com.sleepycat.je.rep.txn.MasterTxn


            throw phase1Exception;
        }

        private void phase2() {
            try {
                txn = new MasterTxn(repImpl, NO_ACK, repImpl.getNameIdPair());
                phase2Body();
                txn.commit();
                txn = null;
            } catch (DatabaseException e) {
                LoggerUtils.severe(logger, repImpl,
View Full Code Here


                TransactionConfig txnConfig = new TransactionConfig();
                txnConfig.setDurability(new Durability(SyncPolicy.SYNC,
                                                       SyncPolicy.SYNC,
                                                       ReplicaAckPolicy.NONE));
                txnConfig.setConsistencyPolicy(NO_CONSISTENCY);
                txn = new MasterTxn(this,
                                    txnConfig,
                                    getNameIdPair());

                /* Database should not exist yet, create it now */
                DatabaseConfig dbConfig = new DatabaseConfig();
View Full Code Here

            long txnId = wireRecord.getCommitTxnId();

            if (txnId != 0) {
                /* A commit log entry */
                MasterTxn ackTxn = repNode.getFeederTxns().getAckTxn(txnId);
                if (ackTxn != null) {
                    ackTxn.stampRepWriteTime();
                    long messageTransferMs = ackTxn.messageTransferMs();
                    totalTransferDelay  += messageTransferMs;
                    if (messageTransferMs > TRANSFER_LOGGING_THRESHOLD_MS) {
                        LoggerUtils.info(logger, threadRepImpl,
                                         (String.format
                                          ("Feeder for: %s, Txn: %,d " +
                                           " log to rep stream time %,dms." +
                                           " Total transfer time: %,dms.",
                                           replicaNameIdPair.getName(),
                                           txnId, messageTransferMs,
                                           totalTransferDelay)));
                    }
                }
                SyncPolicy replicaSync =
                    (ackTxn != null) ?
                    ackTxn.getCommitDurability().getReplicaSync() :

                    /*
                     * Replica is catching up. Specify the weakest and leave it
                     * up to the replica.
                     */
 
View Full Code Here

TOP

Related Classes of com.sleepycat.je.rep.txn.MasterTxn

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.