com.sleepycat.je.log
Class VLSNDistributionReader
java.lang.Object
com.sleepycat.je.log.FileReader
com.sleepycat.je.log.DumpFileReader
com.sleepycat.je.log.VLSNDistributionReader
public class VLSNDistributionReader
- extends DumpFileReader
This is a debugging utility which implements the unadvertised DbPrintLog -vd
option, which displays VLSN distribution in a log. Here's a sample of the
output. This is used to analyze log cleaner barrier behavior.
... 3 files
file 0xb6 numRepRecords = 9 firstVLSN = 1,093,392 lastVLSN = 1,093,400
file 0xb7 numRepRecords = 4 firstVLSN = 1,093,401 lastVLSN = 1,093,404
... 3 files
file 0xbb numRepRecords = 1 firstVLSN = 1,093,405 lastVLSN = 1,093,405
file 0xbc numRepRecords = 1 firstVLSN = 1,093,406 lastVLSN = 1,093,406
... 1 files
file 0xbe numRepRecords = 1 firstVLSN = 1,093,407 lastVLSN = 1,093,407
file 0xbf numRepRecords = 2 firstVLSN = 1,093,408 lastVLSN = 1,093,409
file 0xc0 numRepRecords = 7 firstVLSN = 1,093,410 lastVLSN = 1,093,416
... 0 files at end
First file: 0x0
Last file: 0xc0
Fields inherited from class com.sleepycat.je.log.FileReader |
cksumValidator, currentEntryHeader, currentEntryOffset, currentEntryPrevOffset, envImpl, eof, fileManager, forward, logger, nextEntryOffset, startLsn, window |
Constructor Summary |
VLSNDistributionReader(EnvironmentImpl envImpl,
int readBufferSize,
long startLsn,
long finishLsn,
long endOfFileLsn,
boolean verbose,
boolean forwards)
Create this reader to start at a given LSN. |
Method Summary |
protected boolean |
processEntry(ByteBuffer entryBuffer)
Count the number of vlsns in the file, along with the first and last
vlsn. |
void |
summarize(boolean csvFormat)
|
Methods inherited from class com.sleepycat.je.log.FileReader |
entryIsReplicated, getAndResetNReads, getLastEntrySize, getLastLsn, getNRepeatIteratorReads, getNumRead, initStartingPosition, makeWindow, readNextEntry, readNextEntryAllowExceptions, resyncReader, setAlwaysValidateChecksum, setBackwardPosition, setForwardPosition, skipData, skipEntry, threadSafeBufferFlip, threadSafeBufferPosition, threadSafeBufferPosition |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
VLSNDistributionReader
public VLSNDistributionReader(EnvironmentImpl envImpl,
int readBufferSize,
long startLsn,
long finishLsn,
long endOfFileLsn,
boolean verbose,
boolean forwards)
throws DatabaseException
- Create this reader to start at a given LSN.
- Throws:
DatabaseException
processEntry
protected boolean processEntry(ByteBuffer entryBuffer)
- Count the number of vlsns in the file, along with the first and last
vlsn. Display this when the log reader moves to a new file. .
- Specified by:
processEntry
in class FileReader
- Parameters:
entryBuffer
- contains the entry data and is positioned at the
data
- Returns:
- true if this entry should be returned
summarize
public void summarize(boolean csvFormat)
- Overrides:
summarize
in class DumpFileReader
Copyright (c) 2004-2012 Oracle. All rights reserved.