From d4fcf46dedd6a52429e537c6f188a0b15d734a47 Mon Sep 17 00:00:00 2001 From: Diederik Muylwyk Date: Thu, 13 Jul 2017 18:29:12 -0400 Subject: [PATCH] Removed annoying stacktrace from logs for failed conformance statements. (#692) * Removed annoying stacktrace from logs for failed conformance statements. * Minor tweak for consistency with slf4j. --- .../src/main/java/ca/uhn/fhir/to/BaseController.java | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/hapi-fhir-testpage-overlay/src/main/java/ca/uhn/fhir/to/BaseController.java b/hapi-fhir-testpage-overlay/src/main/java/ca/uhn/fhir/to/BaseController.java index 422086f283a..07b25b527d9 100644 --- a/hapi-fhir-testpage-overlay/src/main/java/ca/uhn/fhir/to/BaseController.java +++ b/hapi-fhir-testpage-overlay/src/main/java/ca/uhn/fhir/to/BaseController.java @@ -320,7 +320,7 @@ public class BaseController { try { conformance = (Conformance) client.conformance(); } catch (Exception e) { - ourLog.warn("Failed to load conformance statement", e); + ourLog.warn("Failed to load conformance statement, error was: {}", e.toString()); theModel.put("errorMsg", toDisplayError("Failed to load conformance statement, error was: " + e.toString(), e)); conformance = new Conformance(); } @@ -380,7 +380,7 @@ public class BaseController { try { conformance = (ca.uhn.fhir.model.dstu2.resource.Conformance) client.conformance(); } catch (Exception e) { - ourLog.warn("Failed to load conformance statement", e); + ourLog.warn("Failed to load conformance statement, error was: {}", e.toString()); theModel.put("errorMsg", toDisplayError("Failed to load conformance statement, error was: " + e.toString(), e)); conformance = new ca.uhn.fhir.model.dstu2.resource.Conformance(); } @@ -440,7 +440,7 @@ public class BaseController { try { capabilityStatement = client.fetchConformance().ofType(org.hl7.fhir.dstu3.model.CapabilityStatement.class).execute(); } catch (Exception ex) { - ourLog.warn("Failed to load conformance statement", ex); + ourLog.warn("Failed to load conformance statement, error was: {}", ex.toString()); theModel.put("errorMsg", toDisplayError("Failed to load conformance statement, error was: " + ex.toString(), ex)); }