[Jboss-cvs] JBossAS SVN: r56494 - branches/JBoss_4_0_0_Case10829/cluster/src/main/org/jboss/ha/jndi

jboss-cvs-commits at lists.jboss.org jboss-cvs-commits at lists.jboss.org
Fri Sep 1 01:21:58 EDT 2006


Author: scott.stark at jboss.org
Date: 2006-09-01 01:21:55 -0400 (Fri, 01 Sep 2006)
New Revision: 56494

Modified:
   branches/JBoss_4_0_0_Case10829/cluster/src/main/org/jboss/ha/jndi/DetachedHANamingService.java
Log:
Add trace level logging around the invoke method

Modified: branches/JBoss_4_0_0_Case10829/cluster/src/main/org/jboss/ha/jndi/DetachedHANamingService.java
===================================================================
--- branches/JBoss_4_0_0_Case10829/cluster/src/main/org/jboss/ha/jndi/DetachedHANamingService.java	2006-09-01 05:03:24 UTC (rev 56493)
+++ branches/JBoss_4_0_0_Case10829/cluster/src/main/org/jboss/ha/jndi/DetachedHANamingService.java	2006-09-01 05:21:55 UTC (rev 56494)
@@ -9,6 +9,7 @@
 import java.lang.reflect.InvocationTargetException;
 import java.lang.reflect.Method;
 import java.lang.reflect.UndeclaredThrowableException;
+import java.util.Arrays;
 import java.util.HashMap;
 import java.util.Set;
 import java.util.Map;
@@ -293,8 +294,14 @@
       Method method = invocation.getMethod();
       Object[] args = invocation.getArguments();
       Object value = null;
+      boolean trace = log.isTraceEnabled();
       try
       {
+         if( trace )
+         {
+            Object argsl = args == null ? null : Arrays.asList(args);
+            log.trace("Begin invoke, method: "+method+", args: "+argsl);
+         }
          value = method.invoke(theServer, args);
       }
       catch(InvocationTargetException e)
@@ -305,7 +312,8 @@
          else
             throw new UndeclaredThrowableException(t, method.toString());
       }
-
+      if( trace )
+         log.trace("End invoke, method: "+method+", value: "+value);
       return value;
    }
 




More information about the jboss-cvs-commits mailing list