HBASE-18623 Frequent failed to parse at EOF warnings from WALEntryStream

This commit is contained in:
Andrew Purtell 2017-08-18 17:13:51 -07:00
parent 192e87309e
commit 70d48b113e
1 changed files with 5 additions and 3 deletions

View File

@ -233,9 +233,11 @@ public class WALEntryStream implements Iterator<Entry>, Closeable, Iterable<Entr
if (trailerSize < 0) {
if (currentPosition < stat.getLen()) {
final long skippedBytes = stat.getLen() - currentPosition;
LOG.info("Reached the end of WAL file '" + currentPath
+ "'. It was not closed cleanly, so we did not parse " + skippedBytes
+ " bytes of data.");
if (LOG.isDebugEnabled()) {
LOG.debug("Reached the end of WAL file '" + currentPath
+ "'. It was not closed cleanly, so we did not parse " + skippedBytes
+ " bytes of data. This is normally ok.");
}
metrics.incrUncleanlyClosedWALs();
metrics.incrBytesSkippedInUncleanlyClosedWALs(skippedBytes);
}