Skip to content

Commit

Permalink
Fix long shutdown time in spring by catching error from db source tha…
Browse files Browse the repository at this point in the history
…t was already closed
  • Loading branch information
cupuyc committed Mar 6, 2017
1 parent d9f2435 commit 07fa571
Showing 1 changed file with 7 additions and 1 deletion.
Expand Up @@ -397,7 +397,13 @@ public void close() {
try {
nodeManagerTasksTimer.cancel();
if (PERSIST) {
dbWrite();
try {
dbWrite();
} catch (Throwable e) { // IllegalAccessError is expected
// NOTE: logback stops context right after shutdown initiated. It is problematic to see log output
// System out could help
logger.warn("Problem during NodeManager persist in close: " + e.getMessage());
}
}
} catch (Exception e) {
logger.warn("Problems canceling nodeManagerTasksTimer", e);
Expand Down

0 comments on commit 07fa571

Please sign in to comment.