HBASE-23207 Log a region open journal (#751)

Signed-off-by: Abhishek Singh Chouhan <achouhan@apache.org>
This commit is contained in:
Andrew Purtell 2019-10-23 17:17:06 -07:00
parent ce65db36c4
commit f0999a16ee
No known key found for this signature in database
GPG Key ID: 8597754DD5365CCD
1 changed files with 6 additions and 1 deletions

View File

@ -889,6 +889,7 @@ public class HRegion implements HeapSize, PropagatingConfigurationObserver, Regi
}
MonitoredTask status = TaskMonitor.get().createStatus("Initializing region " + this);
status.enableStatusJournal(true);
long nextSeqId = -1;
try {
nextSeqId = initializeRegionInternals(reporter, status);
@ -900,6 +901,10 @@ public class HRegion implements HeapSize, PropagatingConfigurationObserver, Regi
status.abort("Exception during region " + getRegionInfo().getRegionNameAsString() +
" initialization.");
}
if (LOG.isDebugEnabled()) {
LOG.debug("Region open journal:\n" + status.prettyPrintJournal());
}
status.cleanup();
}
}
@ -1488,7 +1493,7 @@ public class HRegion implements HeapSize, PropagatingConfigurationObserver, Regi
MonitoredTask status = TaskMonitor.get().createStatus(
"Closing region " + this +
(abort ? " due to abort" : ""));
status.enableStatusJournal(false);
status.enableStatusJournal(true);
status.setStatus("Waiting for close lock");
try {
synchronized (closeLock) {