cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dsosno...@apache.org
Subject git commit: Only add Sequence to RM protocol message for last message when using RM 1.0 protocol (needed to close the sequence).
Date Wed, 14 May 2014 11:25:58 GMT
Repository: cxf
Updated Branches:
  refs/heads/master 6afbf9c60 -> a2962773c


Only add Sequence to RM protocol message for last message when using RM
1.0 protocol (needed to close the sequence).

Project: http://git-wip-us.apache.org/repos/asf/cxf/repo
Commit: http://git-wip-us.apache.org/repos/asf/cxf/commit/a2962773
Tree: http://git-wip-us.apache.org/repos/asf/cxf/tree/a2962773
Diff: http://git-wip-us.apache.org/repos/asf/cxf/diff/a2962773

Branch: refs/heads/master
Commit: a2962773cbad6c88cb4d651c3199e45b352a5972
Parents: 6afbf9c
Author: dsosnoski <dsosnoski@apache.org>
Authored: Wed May 14 23:15:57 2014 +1200
Committer: dsosnoski <dsosnoski@apache.org>
Committed: Wed May 14 23:17:18 2014 +1200

----------------------------------------------------------------------
 .../java/org/apache/cxf/ws/rm/RMCaptureOutInterceptor.java    | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cxf/blob/a2962773/rt/ws/rm/src/main/java/org/apache/cxf/ws/rm/RMCaptureOutInterceptor.java
----------------------------------------------------------------------
diff --git a/rt/ws/rm/src/main/java/org/apache/cxf/ws/rm/RMCaptureOutInterceptor.java b/rt/ws/rm/src/main/java/org/apache/cxf/ws/rm/RMCaptureOutInterceptor.java
index 2c5e832..daa2012 100644
--- a/rt/ws/rm/src/main/java/org/apache/cxf/ws/rm/RMCaptureOutInterceptor.java
+++ b/rt/ws/rm/src/main/java/org/apache/cxf/ws/rm/RMCaptureOutInterceptor.java
@@ -142,7 +142,12 @@ public class RMCaptureOutInterceptor extends AbstractRMInterceptor<Message>
 {
         }
         
         Map<?, ?> invocationContext = (Map<?, ?>)msg.get(Message.INVOCATION_CONTEXT);
-        if ((isApplicationMessage || (isLastMessage && invocationContext != null))
&& !isPartialResponse) {
+        
+        // special check for closing RM 1.0 sequence with no application message
+        //  need to generate Sequence header for the LastMessage element anyway, in this
case
+        boolean close10 = isLastMessage && RM10Constants.NAMESPACE_URI.equals(rmNamespace)
&& invocationContext != null;
+        
+        if ((isApplicationMessage || close10) && !isPartialResponse) {
             if (LOG.isLoggable(Level.FINE)) {
                 LOG.fine("inbound sequence: " + (null == inSeqId ? "null" : inSeqId.getValue()));
             }


Mime
View raw message