YARN-3641. NodeManager: stopRecoveryStore() shouldn't be skipped when exceptions happen in stopping NM's sub-services. Contributed by Junping Du

(cherry picked from commit 711d77cc54)

(cherry picked from commit a81ad81461)
(cherry picked from commit aa82b0684554be8d09f6fcd88826f167922280cc)
This commit is contained in:
Jason Lowe 2015-05-13 21:06:47 +00:00 committed by Vinod Kumar Vavilapalli
parent 6c0ad99b9d
commit 778da79e6f
2 changed files with 11 additions and 3 deletions

View File

@ -135,6 +135,9 @@ Release 2.6.1 - UNRELEASED
YARN-3464. Race condition in LocalizerRunner kills localizer before
localizing all resources. (Zhihai Xu via kasha)
YARN-3641. NodeManager: stopRecoveryStore() shouldn't be skipped when
exceptions happen in stopping NM's sub-services. (Junping Du via jlowe)
Release 2.6.0 - 2014-11-18
INCOMPATIBLE CHANGES

View File

@ -269,9 +269,14 @@ public class NodeManager extends CompositeService
if (isStopping.getAndSet(true)) {
return;
}
super.serviceStop();
stopRecoveryStore();
DefaultMetricsSystem.shutdown();
try {
super.serviceStop();
DefaultMetricsSystem.shutdown();
} finally {
// YARN-3641: NM's services stop get failed shouldn't block the
// release of NMLevelDBStore.
stopRecoveryStore();
}
}
public String getName() {