From 50e551de64f8a910f483270df1c16eccb4616f9a Mon Sep 17 00:00:00 2001 From: Greg Wilkins Date: Thu, 19 Jan 2012 23:11:27 +1100 Subject: [PATCH] 368992: improved logging --- .../java/org/eclipse/jetty/servlets/ProxyServlet.java | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/jetty-servlets/src/main/java/org/eclipse/jetty/servlets/ProxyServlet.java b/jetty-servlets/src/main/java/org/eclipse/jetty/servlets/ProxyServlet.java index 2b7ee1252ff..782d16765b1 100644 --- a/jetty-servlets/src/main/java/org/eclipse/jetty/servlets/ProxyServlet.java +++ b/jetty-servlets/src/main/java/org/eclipse/jetty/servlets/ProxyServlet.java @@ -739,8 +739,14 @@ public class ProxyServlet implements Servlet */ protected void handleOnException(Throwable ex, HttpServletRequest request, HttpServletResponse response) { - _log.warn(ex.toString()); - _log.debug(ex); + if (ex instanceof IOException) + { + _log.warn(ex.toString()); + _log.debug(ex); + } + else + _log.warn(ex); + if (!response.isCommitted()) { response.setStatus(HttpServletResponse.SC_INTERNAL_SERVER_ERROR);