Author: jleroux
Date: Thu Aug 22 14:18:27 2019
New Revision: 1865685
URL:
http://svn.apache.org/viewvc?rev=1865685&view=revLog:
Improved: Add the component name in " Request Begun/Done" lines in log
(OFBIZ-11153)
It's sometimes useful to know from which component a request has been sent,
eg to differentiate main requests, but not only.
Modified:
ofbiz/ofbiz-framework/trunk/framework/webapp/src/main/java/org/apache/ofbiz/webapp/control/ControlServlet.java
Modified: ofbiz/ofbiz-framework/trunk/framework/webapp/src/main/java/org/apache/ofbiz/webapp/control/ControlServlet.java
URL:
http://svn.apache.org/viewvc/ofbiz/ofbiz-framework/trunk/framework/webapp/src/main/java/org/apache/ofbiz/webapp/control/ControlServlet.java?rev=1865685&r1=1865684&r2=1865685&view=diff==============================================================================
--- ofbiz/ofbiz-framework/trunk/framework/webapp/src/main/java/org/apache/ofbiz/webapp/control/ControlServlet.java (original)
+++ ofbiz/ofbiz-framework/trunk/framework/webapp/src/main/java/org/apache/ofbiz/webapp/control/ControlServlet.java Thu Aug 22 14:18:27 2019
@@ -18,12 +18,11 @@
*******************************************************************************/
package org.apache.ofbiz.webapp.control;
-import freemarker.template.Template;
import java.io.IOException;
import java.util.Enumeration;
-
import java.util.HashMap;
import java.util.Map;
+
import javax.servlet.RequestDispatcher;
import javax.servlet.ServletContext;
import javax.servlet.ServletException;
@@ -53,6 +52,7 @@ import org.apache.ofbiz.webapp.stats.Vis
import org.apache.ofbiz.widget.renderer.VisualTheme;
import freemarker.ext.servlet.ServletContextHashModel;
+import freemarker.template.Template;
/**
* ControlServlet.java - Master servlet for the web application.
@@ -128,7 +128,7 @@ public class ControlServlet extends Http
if (Debug.timingOn()) {
timer = new UtilTimer();
timer.setLog(true);
- timer.timerString("[" + rname + "(Domain:" + request.getScheme() + "://" + request.getServerName() + ")] Request Begun, encoding=[" + charset + "]", module);
+ timer.timerString("[" + webappName + "::" + rname + " (Domain:" + request.getScheme() + "://" + request.getServerName() + ")] Request Begun, encoding=[" + charset + "]", module);
}
// Setup the CONTROL_PATH for JSP dispatching.
@@ -341,7 +341,7 @@ public class ControlServlet extends Http
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 + "(Domain:" + request.getScheme() + "://" + request.getServerName() + ")] Request Done", module);
+ if (Debug.timingOn()) timer.timerString("[" + webappName + "::" + rname + " (Domain:" + request.getScheme() + "://" + 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();