diff --git a/zuul-core/src/main/java/com/netflix/zuul/filters/ZuulServletFilter.java b/zuul-core/src/main/java/com/netflix/zuul/filters/ZuulServletFilter.java index 682f922e8a..947e3aa51e 100644 --- a/zuul-core/src/main/java/com/netflix/zuul/filters/ZuulServletFilter.java +++ b/zuul-core/src/main/java/com/netflix/zuul/filters/ZuulServletFilter.java @@ -26,6 +26,8 @@ import org.mockito.Mock; import org.mockito.MockitoAnnotations; import org.mockito.runners.MockitoJUnitRunner; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; import javax.servlet.*; import javax.servlet.http.HttpServletRequest; @@ -49,6 +51,8 @@ */ public class ZuulServletFilter implements Filter { + private static Logger LOG = LoggerFactory.getLogger(ZuulServletFilter.class); + private ZuulRunner zuulRunner; public void init(FilterConfig filterConfig) throws ServletException { @@ -109,7 +113,7 @@ void init(HttpServletRequest servletRequest, HttpServletResponse servletResponse void error(ZuulException e) { RequestContext.getCurrentContext().setThrowable(e); zuulRunner.error(); - e.printStackTrace(); + LOG.error(e.getMessage(), e); } public void destroy() {