private void preblow() { this.dirHolder.incrementTotalOplogSize(this.maxOplogSize); final OplogFile olf = getOLF(); try { olf.raf.setLength(this.maxOplogSize); olf.raf.seek(0); } catch (IOException ignore) { // TODO: need a warning since this can impact perf. // I don't think I need any of this. If setLength throws then // the file is still ok. } }
private void writeProductVersionRecord(Version version, OplogFile olf) throws IOException { this.opState.initialize(version.ordinal()); writeOpLogBytes(olf, false, true); olf.currSize += getOpStateSize(); this.dirHolder.incrementTotalOplogSize(getOpStateSize()); }
/** * Write the RVV record for the given regions. * * @param olf the oplog to write to * @param diskRegions the set of disk regions we should write the RVV of * @param writeGCRVV true to write write the GC RVV */ private void writeRVVRecord(OplogFile olf, Map<Long, AbstractDiskRegion> diskRegions, boolean writeGCRVV) throws IOException { this.opState = new OpState(); this.opState.initialize(diskRegions, writeGCRVV); writeOpLogBytes(olf, false, true); // fix for bug 41928 olf.currSize += getOpStateSize(); this.dirHolder.incrementTotalOplogSize(getOpStateSize()); }
private void writeDiskStoreRecord(OplogFile olf, OPLOG_TYPE type) throws IOException { this.opState = new OpState(); this.opState.initialize(type); writeOpLogBytes(olf, false, true); olf.currSize += getOpStateSize(); this.dirHolder.incrementTotalOplogSize(getOpStateSize()); clearOpState(); this.opState.initialize(getParent().getDiskStoreID()); writeOpLogBytes(olf, false, true); // fix for bug 41928 olf.currSize += getOpStateSize(); this.dirHolder.incrementTotalOplogSize(getOpStateSize()); }
/** * Write a OPLOG_NEW_ENTRY_BASE_ID to this oplog. Must be called before any OPLOG_NEW_ENTRY_0ID * records are written to this oplog. */ private boolean writeNewEntryBaseRecord(boolean async) throws IOException { if (this.wroteNewEntryBase) return false; this.wroteNewEntryBase = true; long newEntryBase = getOplogSet().getOplogEntryId(); OpState saved = this.opState; try { this.opState = new OpState(); this.opState.initialize(newEntryBase); writeOpLogBytes(this.crf, async, false/* no need to flush this record */); this.dirHolder.incrementTotalOplogSize(getOpStateSize()); } finally { this.opState = saved; } return true; }
this.dirHolder.incrementTotalOplogSize(byteCount);
this.dirHolder.incrementTotalOplogSize(byteCount);
getOplogId()); this.dirHolder.incrementTotalOplogSize(adjustment);
logger.trace("Oplog::basicRemove:Released ByteBuffer for Disk ID = {}", id); this.dirHolder.incrementTotalOplogSize(adjustment);
this.dirHolder.incrementTotalOplogSize(adjustment); this.incTotalCount();
this.dirHolder.incrementTotalOplogSize(dataLength); incTotalCount();
this.dirHolder.incrementTotalOplogSize(adjustment); this.incTotalCount();