com.sleepycat.je.log
Class StatsFileReader

java.lang.Object
  extended by com.sleepycat.je.log.FileReader
      extended by com.sleepycat.je.log.DumpFileReader
          extended by com.sleepycat.je.log.StatsFileReader

public class StatsFileReader
extends DumpFileReader

The StatsFileReader generates stats about the log entries read, such as the count of each type of entry, the number of bytes, minimum and maximum sized log entry.


Nested Class Summary
(package private) static class StatsFileReader.CheckpointCounter
           
(package private) static class StatsFileReader.EntryInfo
           
(package private) static class StatsFileReader.LogEntryTypeComparator
           
 
Field Summary
 
Fields inherited from class com.sleepycat.je.log.DumpFileReader
targetTxnIds, verbose
 
Fields inherited from class com.sleepycat.je.log.FileReader
anticipateChecksumErrors, cksumValidator, currentEntryChecksum, currentEntryOffset, currentEntryPrevOffset, currentEntrySize, currentEntryTypeNum, currentEntryTypeVersion, env, eof, fileManager, nextEntryOffset, readBufferFileEnd, readBufferFileNum, readBufferFileStart, startLsn
 
Constructor Summary
StatsFileReader(EnvironmentImpl env, int readBufferSize, long startLsn, long finishLsn, String entryTypes, String txnIds, boolean verbose)
          Create this reader to start at a given LSN.
 
Method Summary
protected  boolean processEntry(ByteBuffer entryBuffer)
          This reader collects stats about the log entry.
 void summarize()
           
 
Methods inherited from class com.sleepycat.je.log.DumpFileReader
isTargetEntry
 
Methods inherited from class com.sleepycat.je.log.FileReader
getLastLsn, getNRepeatIteratorReads, getNumRead, initStartingPosition, readNextEntry, resyncReader
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

StatsFileReader

public StatsFileReader(EnvironmentImpl env,
                       int readBufferSize,
                       long startLsn,
                       long finishLsn,
                       String entryTypes,
                       String txnIds,
                       boolean verbose)
                throws IOException,
                       DatabaseException
Create this reader to start at a given LSN.

Throws:
IOException
DatabaseException
Method Detail

processEntry

protected boolean processEntry(ByteBuffer entryBuffer)
                        throws DatabaseException
This reader collects stats about the log entry.

Specified by:
processEntry in class FileReader
Returns:
true if this entry should be returned
Throws:
DatabaseException

summarize

public void summarize()
Overrides:
summarize in class DumpFileReader


Copyright 2004-2005 Sleepycat, Inc. All Rights Reserved.