[jboss-cvs] JBossRemoting/src/main/org/jboss/remoting ...
Tom Elrod
tom.elrod at jboss.com
Wed Aug 2 03:34:54 EDT 2006
User: telrod
Date: 06/08/02 03:34:54
Modified: src/main/org/jboss/remoting ServerInvoker.java
Log:
JBREM-321 - small tuning for logging.
Revision Changes Path
1.44 +14 -10 JBossRemoting/src/main/org/jboss/remoting/ServerInvoker.java
(In the diff below, changes in quantity of whitespace are not shown.)
Index: ServerInvoker.java
===================================================================
RCS file: /cvsroot/jboss/JBossRemoting/src/main/org/jboss/remoting/ServerInvoker.java,v
retrieving revision 1.43
retrieving revision 1.44
diff -u -b -r1.43 -r1.44
--- ServerInvoker.java 19 Jul 2006 16:39:17 -0000 1.43
+++ ServerInvoker.java 2 Aug 2006 07:34:54 -0000 1.44
@@ -58,7 +58,7 @@
*
* @author <a href="mailto:jhaynie at vocalocity.net">Jeff Haynie</a>
* @author <a href="mailto:tom.elrod at jboss.com">Tom Elrod</a>
- * @version $Revision: 1.43 $
+ * @version $Revision: 1.44 $
*/
public abstract class ServerInvoker extends AbstractInvoker implements ServerInvokerMBean
{
@@ -184,6 +184,8 @@
protected ServerSocketFactory serverSocketFactory = null;
+ private boolean isTraceEnabled = false;
+
public ServerInvoker(InvokerLocator locator)
{
super(locator);
@@ -192,6 +194,7 @@
{
configuration.putAll(locator.getParameters());
}
+ isTraceEnabled = log.isTraceEnabled();
}
public ServerInvoker(InvokerLocator locator, Map configuration)
@@ -206,6 +209,7 @@
{
this.configuration.putAll(locator.getParameters());
}
+ isTraceEnabled = log.isTraceEnabled();
}
protected void setup() throws Exception
@@ -830,7 +834,7 @@
InvocationRequest request = null;
InvocationResponse response = null;
- if(log.isTraceEnabled())
+ if(isTraceEnabled)
{
log.trace("server received invocation =>" + invoke);
}
@@ -849,7 +853,7 @@
}
catch(Throwable throwable)
{
- if(log.isTraceEnabled())
+ if(isTraceEnabled)
{
//throwable.printStackTrace();
}
@@ -981,7 +985,7 @@
}
else
{
- if (log.isTraceEnabled())
+ if (isTraceEnabled)
{
log.trace("dispatching invocation: " + invocation + " to subsystem: " + subsystem + " from client: " + clientId);
}
@@ -994,7 +998,7 @@
}
result = handler.invoke(invocation);
}
- if (log.isTraceEnabled())
+ if (isTraceEnabled)
{
log.trace("dispatch invocation, returning back: " + result + " from subsystem: " + subsystem +
" to client: " + clientId);
@@ -1101,7 +1105,7 @@
{
Object result = null;
String methodName = param.getMethodName();
- if(log.isTraceEnabled())
+ if(isTraceEnabled)
{
log.trace("handling InternalInvocation where method name = " + methodName);
}
@@ -1130,7 +1134,7 @@
"or via the Connector's addInvocationHandler() method.");
}
handler.removeListener(callbackHandler);
- if(log.isTraceEnabled())
+ if(isTraceEnabled)
{
log.trace("ServerInvoker (" + this + ") removing server callback handler " + callbackHandler + ".");
}
@@ -1146,7 +1150,7 @@
else if(InternalInvocation.GETCALLBACKS.equals(methodName))
{
ServerInvokerCallbackHandler callbackHandler = getCallbackHandler(invocation);
- if(log.isTraceEnabled())
+ if(isTraceEnabled)
{
log.trace("ServerInvoker (" + this + ") getting callbacks for callback handler " + callbackHandler + ".");
}
@@ -1189,7 +1193,7 @@
else if(InternalInvocation.HANDLECALLBACK.equals(methodName))
{
String sessionId = ServerInvokerCallbackHandler.getId(invocation);
- if(log.isTraceEnabled())
+ if(isTraceEnabled)
{
log.trace("ServerInvoker (" + this + ") is being asked to deliver callback on client callback handler with session id of " + sessionId + ".");
}
@@ -1266,7 +1270,7 @@
callbackHandlers.put(id, callbackHandler);
}
}
- if(log.isTraceEnabled())
+ if(isTraceEnabled)
{
log.trace("ServerInvoker (" + this + ") adding server callback handler " + callbackHandler + " with id of " + id + ".");
}
More information about the jboss-cvs-commits
mailing list