Examples of TxnFuzzyCkpLogRecord


Examples of org.chaidb.db.log.logrecord.TxnFuzzyCkpLogRecord

                case LogRecord.LOG_TXN_FUZZY_CHECKPOINT://V3.1 fuzzy checkpoint
                    countCkp++;
                    if (countCkp == 1) {
                        this.txnManager.setLastCkp(cursorLsn);
                    } else if (countCkp == 2) {
                        TxnFuzzyCkpLogRecord fuzzyCkpLog = (TxnFuzzyCkpLogRecord) cursorLogRecord;
                        /* V3.1, if no active txn while doing fuzzy checkpoint,
                            smallestLsn is equals to current checkpoint log lsn,if
                            has active txns,it's euqals to smallest first_lsn of all
                            active txns. */
                        smallestLsn = fuzzyCkpLog.getSmallestLsn();
                    }
                    break;
                default:
                    //Adding TxnRegopLogRecord to redostack,and do its redo function for release txn resource of btree.
                    if (cursorLogRecord.getType() == LogRecord.LOG_TXN_REGOP) {
View Full Code Here

Examples of org.chaidb.db.log.logrecord.TxnFuzzyCkpLogRecord

    the log buffer to disk.*/
        lastCkp = txnManager.getLastCkp();

        try {
            if (flags == TransactionManager.DB_SHUTDOWN) {
                ckpLsn = new TxnFuzzyCkpLogRecord(lastCkp, new Date().getTime(), TxnCkpLogRecord.SHUTDOWN_CHECKPOINT, smallestLsn).log();
            } else {
                ckpLsn = new TxnFuzzyCkpLogRecord(lastCkp, new Date().getTime(), TxnCkpLogRecord.FUZZY_CHECKPOINT, smallestLsn).log();
            }
        } catch (ChaiDBException e) {
            logger.error(e);

            String details = "Log failed at LSN [" + new Integer(ckpLsn.getFileId()).toString() + " " + new Integer(ckpLsn.getOffset()).toString() + "].";
View Full Code Here

Examples of org.chaidb.db.log.logrecord.TxnFuzzyCkpLogRecord

            throw new ChaiDBException(ErrorCode.DB_SERVER_SHUTDOWN, detail);
        }

//        saveBTreeFileName(data.getBTreeFileName());

        TxnFuzzyCkpLogRecord lr = (TxnFuzzyCkpLogRecord) data;
        if (lr.getSmallestLsn() == null) {
            lr.setSmallestLsn(curLsn);
        }
        if (lr.getFlag() == TxnCkpLogRecord.SHUTDOWN_CHECKPOINT) {
            shutDown = true;
        }

        Lsn lastLsn = _put(data, null);
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.