HBASE-22354 master never sets abortRequested, and thus abort timeout doesn't work for it

Signed-off-by: Peter Somogyi <psomogyi@apache.org>
This commit is contained in:
Sergey Shelukhin 2019-05-02 18:08:02 -07:00 committed by Peter Somogyi
parent 61f4cd7406
commit 7269aa3743
2 changed files with 6 additions and 1 deletions

View File

@ -2850,6 +2850,7 @@ public class HMaster extends HRegionServer implements MasterServices {
if (isAborted() || isStopped()) { if (isAborted() || isStopped()) {
return; return;
} }
setAbortRequested();
if (cpHost != null) { if (cpHost != null) {
// HBASE-4014: dump a list of loaded coprocessors. // HBASE-4014: dump a list of loaded coprocessors.
LOG.error(HBaseMarkers.FATAL, "Master server abort: loaded coprocessors are: " + LOG.error(HBaseMarkers.FATAL, "Master server abort: loaded coprocessors are: " +

View File

@ -2377,7 +2377,7 @@ public class HRegionServer extends HasThread implements
} else { } else {
LOG.error(HBaseMarkers.FATAL, msg); LOG.error(HBaseMarkers.FATAL, msg);
} }
this.abortRequested = true; setAbortRequested();
// HBASE-4014: show list of coprocessors that were loaded to help debug // HBASE-4014: show list of coprocessors that were loaded to help debug
// regionserver crashes.Note that we're implicitly using // regionserver crashes.Note that we're implicitly using
// java.util.HashSet's toString() method to print the coprocessor names. // java.util.HashSet's toString() method to print the coprocessor names.
@ -2410,6 +2410,10 @@ public class HRegionServer extends HasThread implements
stop(reason, true, null); stop(reason, true, null);
} }
protected final void setAbortRequested() {
this.abortRequested = true;
}
/** /**
* @see HRegionServer#abort(String, Throwable) * @see HRegionServer#abort(String, Throwable)
*/ */