* Pass 2: scavenge the regular (non-dbtree) environment.
*/
private void scavenge(long lastUsedLsn, long nextAvailableLsn)
throws IOException, DatabaseException {
final ScavengerFileReader scavengerReader =
new ScavengerFileReader(envImpl, readBufferSize, lastUsedLsn,
DbLsn.NULL_LSN, nextAvailableLsn) {
protected void processEntryCallback(LogEntry entry,
LogEntryType entryType)
throws DatabaseException {
processRegularEntry(entry, entryType);
}
};
/*
* Note: committed transaction id map has been created already, no
* need to read TXN_COMMITS on this pass.
*/
scavengerReader.setTargetType(LogEntryType.LOG_LN_TRANSACTIONAL);
scavengerReader.setTargetType(LogEntryType.LOG_LN);
scavengerReader.setTargetType
(LogEntryType.LOG_DEL_DUPLN_TRANSACTIONAL);
scavengerReader.setTargetType(LogEntryType.LOG_DEL_DUPLN);
scavengerReader.setDumpCorruptedBounds(dumpCorruptedBounds);
long progressFileNum = -1;
while (scavengerReader.readNextEntry()) {
progressFileNum = reportProgress(progressFileNum,
scavengerReader.getLastLsn());
}
}