You are viewing a plain text version of this content. The canonical link for it is here.
Posted to axis-cvs@ws.apache.org by da...@apache.org on 2006/12/05 14:30:27 UTC

svn commit: r482644 - /webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/engine/SOAPMessageBodyBasedDispatcher.java

Author: davidillsley
Date: Tue Dec  5 05:30:26 2006
New Revision: 482644

URL: http://svn.apache.org/viewvc?view=rev&rev=482644
Log:
Trunk fox for AXIS2-1829
The SOAPMessageBodyBasedDispatcher uses instance variables to temporarily store the
service and operation names. If the same instance is invoked simultaneously from
different threads (allowed by the handler model) then the results would be unpredictable.

I will attach the patch to JIRA for review for the 1.1 branch

Modified:
    webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/engine/SOAPMessageBodyBasedDispatcher.java

Modified: webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/engine/SOAPMessageBodyBasedDispatcher.java
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/engine/SOAPMessageBodyBasedDispatcher.java?view=diff&rev=482644&r1=482643&r2=482644
==============================================================================
--- webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/engine/SOAPMessageBodyBasedDispatcher.java (original)
+++ webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/engine/SOAPMessageBodyBasedDispatcher.java Tue Dec  5 05:30:26 2006
@@ -41,12 +41,12 @@
      */
     public static final String NAME = "SOAPMessageBodyBasedDispatcher";
     private static final Log log = LogFactory.getLog(SOAPMessageBodyBasedDispatcher.class);
-    String serviceName = null;
-    QName operationName = null;
     private static final boolean isDebugEnabled = log.isDebugEnabled();
 
     public AxisOperation findOperation(AxisService service, MessageContext messageContext)
             throws AxisFault {
+        QName operationName = null;
+        
         OMElement bodyFirstChild = messageContext.getEnvelope().getBody().getFirstElement();
 
         if (bodyFirstChild == null) {
@@ -62,8 +62,6 @@
 
         AxisOperation axisOperation = service.getOperation(operationName);
 
-
-
         if (axisOperation == null) {
             axisOperation = service.getOperationByMessageName(bodyFirstChild.getLocalName());
         }
@@ -75,6 +73,8 @@
      * @see org.apache.axis2.engine.AbstractDispatcher#findService(org.apache.axis2.context.MessageContext)
      */
     public AxisService findService(MessageContext messageContext) throws AxisFault {
+        String serviceName = null;
+        
         OMElement bodyFirstChild = messageContext.getEnvelope().getBody().getFirstElement();
 
         if (bodyFirstChild != null) {
@@ -90,10 +90,6 @@
                 }
                 String[] values = Utils.parseRequestURLForServiceAndOperation(filePart,
                         messageContext.getConfigurationContext().getServiceContextPath());
-
-                if (values[1] != null) {
-                    operationName = new QName(values[1]);
-                }
 
                 if (values[0] != null) {
                     serviceName = values[0];



---------------------------------------------------------------------
To unsubscribe, e-mail: axis-cvs-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-cvs-help@ws.apache.org