synapse-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From asan...@apache.org
Subject svn commit: r544142 - in /webservices/synapse/branches/1.0/modules/core/src/main/java/org/apache/synapse: core/axis2/Axis2FlexibleMEPClient.java mediators/builtin/RMSequenceMediator.java
Date Mon, 04 Jun 2007 12:31:50 GMT
Author: asankha
Date: Mon Jun  4 05:31:48 2007
New Revision: 544142

URL: http://svn.apache.org/viewvc?view=rev&rev=544142
Log:
support final sandesha2 jar that expects us to set an offer when making new rm operations

Modified:
    webservices/synapse/branches/1.0/modules/core/src/main/java/org/apache/synapse/core/axis2/Axis2FlexibleMEPClient.java
    webservices/synapse/branches/1.0/modules/core/src/main/java/org/apache/synapse/mediators/builtin/RMSequenceMediator.java

Modified: webservices/synapse/branches/1.0/modules/core/src/main/java/org/apache/synapse/core/axis2/Axis2FlexibleMEPClient.java
URL: http://svn.apache.org/viewvc/webservices/synapse/branches/1.0/modules/core/src/main/java/org/apache/synapse/core/axis2/Axis2FlexibleMEPClient.java?view=diff&rev=544142&r1=544141&r2=544142
==============================================================================
--- webservices/synapse/branches/1.0/modules/core/src/main/java/org/apache/synapse/core/axis2/Axis2FlexibleMEPClient.java
(original)
+++ webservices/synapse/branches/1.0/modules/core/src/main/java/org/apache/synapse/core/axis2/Axis2FlexibleMEPClient.java
Mon Jun  4 05:31:48 2007
@@ -56,6 +56,7 @@
 import org.apache.synapse.statistics.impl.EndPointStatisticsStack;
 import org.apache.synapse.endpoints.utils.EndpointDefinition;
 import org.apache.rampart.handler.WSSHandlerConstants;
+import org.apache.sandesha2.client.SandeshaClientConstants;
 
 /**
  * This is a simple client that handles both in only and in out
@@ -297,6 +298,10 @@
         if(oriOptions.getProperty(Constants.SANDESHA_SEQUENCE_KEY) != null) {
             targetOptions.setProperty(Constants.SANDESHA_SEQUENCE_KEY, 
                     oriOptions.getProperty(Constants.SANDESHA_SEQUENCE_KEY));
+        }
+        if(oriOptions.getProperty(SandeshaClientConstants.OFFERED_SEQUENCE_ID) != null) {
+            targetOptions.setProperty(SandeshaClientConstants.OFFERED_SEQUENCE_ID,
+                    oriOptions.getProperty(SandeshaClientConstants.OFFERED_SEQUENCE_ID));
         }
     }
     

Modified: webservices/synapse/branches/1.0/modules/core/src/main/java/org/apache/synapse/mediators/builtin/RMSequenceMediator.java
URL: http://svn.apache.org/viewvc/webservices/synapse/branches/1.0/modules/core/src/main/java/org/apache/synapse/mediators/builtin/RMSequenceMediator.java?view=diff&rev=544142&r1=544141&r2=544142
==============================================================================
--- webservices/synapse/branches/1.0/modules/core/src/main/java/org/apache/synapse/mediators/builtin/RMSequenceMediator.java
(original)
+++ webservices/synapse/branches/1.0/modules/core/src/main/java/org/apache/synapse/mediators/builtin/RMSequenceMediator.java
Mon Jun  4 05:31:48 2007
@@ -35,6 +35,7 @@
 import org.apache.synapse.config.Entry;
 import org.apache.synapse.core.axis2.Axis2MessageContext;
 import org.apache.synapse.mediators.AbstractMediator;
+import org.apache.sandesha2.client.SandeshaClientConstants;
 import org.jaxen.JaxenException;
 
 public class RMSequenceMediator extends AbstractMediator {
@@ -85,6 +86,8 @@
             orgMessageCtx.getOptions().setProperty(
                 Constants.SANDESHA_SEQUENCE_KEY, sequenceID);
             orgMessageCtx.getOptions().setProperty(
+                SandeshaClientConstants.OFFERED_SEQUENCE_ID, UUIDGenerator.getUUID());
+            orgMessageCtx.getOptions().setProperty(
                 Constants.SANDESHA_LAST_MESSAGE, "true");
             return true;
         }
@@ -97,6 +100,11 @@
         boolean lastMessage = isLastMessage(smc);
         if (log.isDebugEnabled()) {
             log.debug("Is this message the last message in sequence: " + lastMessage);
+        }
+
+        if (!sequenceMap.containsKey(correlationValue)) {
+            orgMessageCtx.getOptions().setProperty(
+                SandeshaClientConstants.OFFERED_SEQUENCE_ID, UUIDGenerator.getUUID());  
    
         }
 
         String sequenceID = retrieveSequenceID(correlationValue);



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


Mime
View raw message