From 7e07ec7ad55c3fc23cd7db9f785be8dcdbcdbe9a Mon Sep 17 00:00:00 2001 From: Hans Bakker Date: Sun, 26 Jun 2011 03:11:17 +0000 Subject: [PATCH] improve log messages (add domainname) git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1139703 13f79535-47bb-0310-9956-ffa450edef68 --- .../webapp/src/org/ofbiz/webapp/control/ContextFilter.java | 2 +- .../webapp/src/org/ofbiz/webapp/control/ControlServlet.java | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/framework/webapp/src/org/ofbiz/webapp/control/ContextFilter.java b/framework/webapp/src/org/ofbiz/webapp/control/ContextFilter.java index c4543c24bd..b123d5e898 100644 --- a/framework/webapp/src/org/ofbiz/webapp/control/ContextFilter.java +++ b/framework/webapp/src/org/ofbiz/webapp/control/ContextFilter.java @@ -207,7 +207,7 @@ public class ContextFilter implements Filter { allowList.add("/"); // No path is allowed. allowList.add(""); // No path is allowed. - if (debug) Debug.log("[Request]: " + httpRequest.getRequestURI(), module); + if (debug) Debug.log("[Domain]: " + httpRequest.getServerName() + " [Request]: " + httpRequest.getRequestURI(), module); requestPath = httpRequest.getServletPath(); if (requestPath == null) requestPath = ""; diff --git a/framework/webapp/src/org/ofbiz/webapp/control/ControlServlet.java b/framework/webapp/src/org/ofbiz/webapp/control/ControlServlet.java index 8bbc2213b7..a578a38795 100644 --- a/framework/webapp/src/org/ofbiz/webapp/control/ControlServlet.java +++ b/framework/webapp/src/org/ofbiz/webapp/control/ControlServlet.java @@ -138,7 +138,7 @@ public class ControlServlet extends HttpServlet { if (Debug.timingOn()) { timer = new UtilTimer(); timer.setLog(true); - timer.timerString("[" + rname + "] Request Begun, encoding=[" + charset + "]", module); + timer.timerString("[" + rname + "(Domain:" + request.getServerName() + ")] Request Begun, encoding=[" + charset + "]", module); } // Setup the CONTROL_PATH for JSP dispatching. @@ -321,7 +321,7 @@ public class ControlServlet extends HttpServlet { Debug.logError(t, "Error in ControlServlet saving ServerHit/Bin information; the output was successful, but can't save this tracking information. The error was: " + t.toString(), module); } } - if (Debug.timingOn()) timer.timerString("[" + rname + "] Request Done", module); + if (Debug.timingOn()) timer.timerString("[" + rname + "(Domain:" + request.getServerName() + ")] Request Done", module); // sanity check 2: make sure there are no user or session infos in the delegator, ie clear the thread GenericDelegator.clearUserIdentifierStack();