@Override public String debug() throws Exception { reclaimer.scan(getDataFiles()); StringBuilder builder = new StringBuilder(); for (JournalFile file : filesRepository.getDataFiles()) { builder.append("DataFile:" + file + " posCounter = " + file.getPosCount() + " reclaimStatus = " + file.isCanReclaim() + " live size = " + file.getLiveSize() + "\n"); if (file instanceof JournalFileImpl) { builder.append(((JournalFileImpl) file).debug()); } } for (JournalFile file : filesRepository.getFreeFiles()) { builder.append("FreeFile:" + file + "\n"); } if (currentFile != null) { builder.append("CurrentFile:" + currentFile + " posCounter = " + currentFile.getPosCount() + "\n"); if (currentFile instanceof JournalFileImpl) { builder.append(((JournalFileImpl) currentFile).debug()); } } else { builder.append("CurrentFile: No current file at this point!"); } return builder.toString(); }
@Override public String debug() throws Exception { reclaimer.scan(getDataFiles()); StringBuilder builder = new StringBuilder(); for (JournalFile file : filesRepository.getDataFiles()) { builder.append("DataFile:" + file + " posCounter = " + file.getPosCount() + " reclaimStatus = " + file.isCanReclaim() + " live size = " + file.getLiveSize() + "\n"); if (file instanceof JournalFileImpl) { builder.append(((JournalFileImpl) file).debug()); } } for (JournalFile file : filesRepository.getFreeFiles()) { builder.append("FreeFile:" + file + "\n"); } if (currentFile != null) { builder.append("CurrentFile:" + currentFile + " posCounter = " + currentFile.getPosCount() + "\n"); if (currentFile instanceof JournalFileImpl) { builder.append(((JournalFileImpl) currentFile).debug()); } } else { builder.append("CurrentFile: No current file at this point!"); } return builder.toString(); }