ws-axis-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From d...@apache.org
Subject svn commit: r398827 - /webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/engine/Phase.java
Date Tue, 02 May 2006 06:48:56 GMT
Author: dims
Date: Mon May  1 23:48:53 2006
New Revision: 398827

URL: http://svn.apache.org/viewcvs?rev=398827&view=rev
Log:
add a flag for isDebugEnabled.

Modified:
    webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/engine/Phase.java

Modified: webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/engine/Phase.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/engine/Phase.java?rev=398827&r1=398826&r2=398827&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/engine/Phase.java (original)
+++ webservices/axis2/trunk/java/modules/core/src/org/apache/axis2/engine/Phase.java Mon May
 1 23:48:53 2006
@@ -357,7 +357,8 @@
      * @throws org.apache.axis2.AxisFault
      */
     public final void invoke(MessageContext msgctx) throws AxisFault {
-        if (log.isDebugEnabled()) {
+        boolean isDebugEnabled = log.isDebugEnabled();
+        if (isDebugEnabled) {
             log.debug("Checking pre-condition for Phase \"" + phaseName + "\"");
         }
 
@@ -367,14 +368,16 @@
             checkPreconditions(msgctx);
         }
 
-        if (log.isDebugEnabled()) {
+        if (isDebugEnabled) {
             log.debug("Invoking phase \"" + phaseName + "\"");
         }
 
         while (currentIndex < handlers.size()) {
             Handler handler = (Handler) handlers.get(currentIndex);
 
-            log.debug("Invoking Handler '" + handler.getName() + "' in Phase '" + phaseName
+ "'");
+            if (isDebugEnabled) {
+                log.debug("Invoking Handler '" + handler.getName() + "' in Phase '" + phaseName
+ "'");
+            }
             handler.invoke(msgctx);
 
             if (msgctx.isPaused()) {
@@ -385,7 +388,7 @@
             msgctx.setCurrentPhaseIndex(currentIndex);
         }
 
-        if (log.isDebugEnabled()) {
+        if (isDebugEnabled) {
             log.debug("Checking post-conditions for phase \"" + phaseName + "\"");
         }
 



Mime
View raw message