From 8741752cf0129eff7a389abf4df78d707c472766 Mon Sep 17 00:00:00 2001 From: Jonathan Cobb Date: Fri, 18 Sep 2020 10:58:15 -0400 Subject: [PATCH] show stack of oome, not thread --- .../util/system/OutOfMemoryErrorUncaughtExceptionHandler.java | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/main/java/org/cobbzilla/util/system/OutOfMemoryErrorUncaughtExceptionHandler.java b/src/main/java/org/cobbzilla/util/system/OutOfMemoryErrorUncaughtExceptionHandler.java index 2f132c3..236d1c3 100644 --- a/src/main/java/org/cobbzilla/util/system/OutOfMemoryErrorUncaughtExceptionHandler.java +++ b/src/main/java/org/cobbzilla/util/system/OutOfMemoryErrorUncaughtExceptionHandler.java @@ -4,7 +4,6 @@ import lombok.AllArgsConstructor; import lombok.extern.slf4j.Slf4j; import static org.cobbzilla.util.daemon.ZillaRuntime.shortError; -import static org.cobbzilla.util.daemon.ZillaRuntime.stacktrace; @AllArgsConstructor @Slf4j public class OutOfMemoryErrorUncaughtExceptionHandler implements Thread.UncaughtExceptionHandler { @@ -18,7 +17,7 @@ public class OutOfMemoryErrorUncaughtExceptionHandler implements Thread.Uncaught @Override public void uncaughtException(Thread t, Throwable e) { if (e instanceof OutOfMemoryError) { try { - log.error("!!!!! OutOfMemoryError: calling System.exit("+status+") from: " + stacktrace(t)); + log.error("!!!!! OutOfMemoryError: calling System.exit("+status+")", e); } catch (Throwable ignored) {} System.exit(status); } else {