Author: dims
Date: Wed Feb 27 18:19:43 2008
New Revision: 631820

URL: http://svn.apache.org/viewvc?rev=631820&view=rev
Log:
[PERF] Analysis by David Strite. HandlerInvokerUtils.invokeOutboundHandlers() 
has a shortcut to exit 
if the handlers list is null. Adding an additional check if the handler list is 
empty and adding the 
same checks at the beginning of invokeInboundHandlers(), result in speedup of 
throughput when no 
handlers are used.


Modified:
    
webservices/axis2/trunk/java/modules/jaxws/src/org/apache/axis2/jaxws/handler/HandlerInvokerUtils.java

Modified: 
webservices/axis2/trunk/java/modules/jaxws/src/org/apache/axis2/jaxws/handler/HandlerInvokerUtils.java
URL: 
http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/jaxws/src/org/apache/axis2/jaxws/handler/HandlerInvokerUtils.java?rev=631820&r1=631819&r2=631820&view=diff
==============================================================================
--- 
webservices/axis2/trunk/java/modules/jaxws/src/org/apache/axis2/jaxws/handler/HandlerInvokerUtils.java
 (original)
+++ 
webservices/axis2/trunk/java/modules/jaxws/src/org/apache/axis2/jaxws/handler/HandlerInvokerUtils.java
 Wed Feb 27 18:19:43 2008
@@ -34,6 +34,9 @@
     public static boolean invokeInboundHandlers(MEPContext mepMessageCtx, 
List<Handler> handlers,
                                                 HandlerChainProcessor.MEP mep, 
boolean isOneWay) {
 
+        if (handlers == null || handlers.isEmpty())
+            return true;
+
         String bindingProto = null;
         if (mep.equals(HandlerChainProcessor.MEP.REQUEST)) // inbound request; 
must be on the server
             bindingProto = mepMessageCtx.getEndpointDesc().getBindingType();
@@ -91,7 +94,7 @@
     public static boolean invokeOutboundHandlers(MEPContext mepMessageCtx, 
List<Handler> handlers,
                                                  HandlerChainProcessor.MEP 
mep, boolean isOneWay) {
 
-        if (handlers == null)
+        if (handlers == null || handlers.isEmpty())
             return true;
 
         String bindingProto = null;



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to