You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cxf.apache.org by ay...@apache.org on 2012/05/08 14:59:31 UTC
svn commit: r1335492 - in /cxf/branches/2.5.x-fixes: ./
rt/ws/rm/src/main/java/org/apache/cxf/ws/rm/Destination.java
rt/ws/rm/src/main/java/org/apache/cxf/ws/rm/DestinationSequence.java
Author: ay
Date: Tue May 8 12:59:30 2012
New Revision: 1335492
URL: http://svn.apache.org/viewvc?rev=1335492&view=rev
Log:
Merged revisions 1335488 via svn merge from
https://svn.apache.org/repos/asf/cxf/trunk
........
r1335488 | ay | 2012-05-08 14:51:07 +0200 (Tue, 08 May 2012) | 1 line
[CXF-4297] WS-RM destination should update ack-ranges in RMStore before sending out ack
........
Modified:
cxf/branches/2.5.x-fixes/ (props changed)
cxf/branches/2.5.x-fixes/rt/ws/rm/src/main/java/org/apache/cxf/ws/rm/Destination.java
cxf/branches/2.5.x-fixes/rt/ws/rm/src/main/java/org/apache/cxf/ws/rm/DestinationSequence.java
Propchange: cxf/branches/2.5.x-fixes/
('svn:mergeinfo' removed)
Propchange: cxf/branches/2.5.x-fixes/
------------------------------------------------------------------------------
Binary property 'svnmerge-integrated' - no diff available.
Modified: cxf/branches/2.5.x-fixes/rt/ws/rm/src/main/java/org/apache/cxf/ws/rm/Destination.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.5.x-fixes/rt/ws/rm/src/main/java/org/apache/cxf/ws/rm/Destination.java?rev=1335492&r1=1335491&r2=1335492&view=diff
==============================================================================
--- cxf/branches/2.5.x-fixes/rt/ws/rm/src/main/java/org/apache/cxf/ws/rm/Destination.java (original)
+++ cxf/branches/2.5.x-fixes/rt/ws/rm/src/main/java/org/apache/cxf/ws/rm/Destination.java Tue May 8 12:59:30 2012
@@ -29,14 +29,12 @@ import java.util.logging.Logger;
import org.apache.cxf.common.logging.LogUtils;
import org.apache.cxf.endpoint.Endpoint;
import org.apache.cxf.helpers.CastUtils;
-import org.apache.cxf.io.CachedOutputStream;
import org.apache.cxf.message.Exchange;
import org.apache.cxf.message.Message;
import org.apache.cxf.message.MessageImpl;
import org.apache.cxf.message.MessageUtils;
import org.apache.cxf.transport.Conduit;
import org.apache.cxf.ws.addressing.AddressingPropertiesImpl;
-import org.apache.cxf.ws.rm.persistence.RMMessage;
import org.apache.cxf.ws.rm.persistence.RMStore;
import org.apache.cxf.ws.rm.v200702.AckRequestedType;
import org.apache.cxf.ws.rm.v200702.Identifier;
@@ -116,8 +114,9 @@ public class Destination extends Abstrac
if (MessageUtils.isTrue(message.get(RMMessageConstants.DELIVERING_ROBUST_ONEWAY))) {
return;
}
- seq.acknowledge(message);
+ seq.acknowledge(message);
+
if (null != rmps.getCloseSequence()) {
seq.setLastMessageNumber(sequenceType.getMessageNumber());
ackImmediately(seq, message);
@@ -147,17 +146,6 @@ public class Destination extends Abstrac
throw sff.createUnknownSequenceFault(sequenceType.getIdentifier());
}
- RMStore store = getReliableEndpoint().getManager().getStore();
- if (null != store) {
- RMMessage msg = null;
- if (!MessageUtils.isTrue(message.getContextualProperty(Message.ROBUST_ONEWAY))) {
- msg = new RMMessage();
- msg.setContent((CachedOutputStream)message.get(RMMessageConstants.SAVED_CONTENT));
- msg.setMessageNumber(sequenceType.getMessageNumber());
- }
- store.persistIncoming(seq, msg);
- }
-
}
void ackRequested(Message message) throws SequenceFault, RMException {
Modified: cxf/branches/2.5.x-fixes/rt/ws/rm/src/main/java/org/apache/cxf/ws/rm/DestinationSequence.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.5.x-fixes/rt/ws/rm/src/main/java/org/apache/cxf/ws/rm/DestinationSequence.java?rev=1335492&r1=1335491&r2=1335492&view=diff
==============================================================================
--- cxf/branches/2.5.x-fixes/rt/ws/rm/src/main/java/org/apache/cxf/ws/rm/DestinationSequence.java (original)
+++ cxf/branches/2.5.x-fixes/rt/ws/rm/src/main/java/org/apache/cxf/ws/rm/DestinationSequence.java Tue May 8 12:59:30 2012
@@ -33,11 +33,13 @@ import org.apache.cxf.common.logging.Log
import org.apache.cxf.continuations.Continuation;
import org.apache.cxf.continuations.ContinuationProvider;
import org.apache.cxf.continuations.SuspendedInvocationException;
+import org.apache.cxf.io.CachedOutputStream;
import org.apache.cxf.message.Message;
import org.apache.cxf.message.MessageUtils;
import org.apache.cxf.ws.addressing.EndpointReferenceType;
import org.apache.cxf.ws.rm.manager.AcksPolicyType;
import org.apache.cxf.ws.rm.manager.DeliveryAssuranceType;
+import org.apache.cxf.ws.rm.persistence.RMMessage;
import org.apache.cxf.ws.rm.persistence.RMStore;
import org.apache.cxf.ws.rm.policy.RM10PolicyUtils;
import org.apache.cxf.ws.rm.v200702.Identifier;
@@ -163,6 +165,17 @@ public class DestinationSequence extends
}
mergeRanges();
}
+
+ RMStore store = destination.getManager().getStore();
+ if (null != store) {
+ RMMessage msg = null;
+ if (!MessageUtils.isTrue(message.getContextualProperty(Message.ROBUST_ONEWAY))) {
+ msg = new RMMessage();
+ msg.setContent((CachedOutputStream)message.get(RMMessageConstants.SAVED_CONTENT));
+ msg.setMessageNumber(st.getMessageNumber());
+ }
+ store.persistIncoming(this, msg);
+ }
RMAssertion rma = RM10PolicyUtils.getRMAssertion(destination.getManager().getRMAssertion(), message);
long acknowledgementInterval = 0;