Permalink
Browse files

Removing some noise from the logs

  • Loading branch information...
1 parent 4de65e0 commit 796f61ee379f507031190a5e4fe15f404d434c09 @joakime joakime committed Aug 23, 2011
@@ -8,27 +8,21 @@
import org.eclipse.jetty.server.Request;
import org.eclipse.jetty.server.handler.HandlerWrapper;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
import org.slf4j.MDC;
public class MDCHandler extends HandlerWrapper
{
- private static final Logger LOG = LoggerFactory.getLogger(MDCHandler.class);
-
@Override
public void handle(String target, Request baseRequest, HttpServletRequest request, HttpServletResponse response) throws IOException, ServletException
{
try
{
- LOG.info("Start");
MDC.put("host",request.getServerName());
super.handle(target,baseRequest,request,response);
}
finally
{
MDC.clear();
- LOG.info("Finally");
}
}
}

0 comments on commit 796f61e

Please sign in to comment.