cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From a.@apache.org
Subject svn commit: r1309068 - in /cxf/trunk/rt/ws/rm/src/main/java/org/apache/cxf/ws/rm: Destination.java persistence/jdbc/RMTxStore.java
Date Tue, 03 Apr 2012 17:44:47 GMT
Author: ay
Date: Tue Apr  3 17:44:46 2012
New Revision: 1309068

URL: http://svn.apache.org/viewvc?rev=1309068&view=rev
Log:
utilize the existing rmstore methods for sequence only updates

Modified:
    cxf/trunk/rt/ws/rm/src/main/java/org/apache/cxf/ws/rm/Destination.java
    cxf/trunk/rt/ws/rm/src/main/java/org/apache/cxf/ws/rm/persistence/jdbc/RMTxStore.java

Modified: cxf/trunk/rt/ws/rm/src/main/java/org/apache/cxf/ws/rm/Destination.java
URL: http://svn.apache.org/viewvc/cxf/trunk/rt/ws/rm/src/main/java/org/apache/cxf/ws/rm/Destination.java?rev=1309068&r1=1309067&r2=1309068&view=diff
==============================================================================
--- cxf/trunk/rt/ws/rm/src/main/java/org/apache/cxf/ws/rm/Destination.java (original)
+++ cxf/trunk/rt/ws/rm/src/main/java/org/apache/cxf/ws/rm/Destination.java Tue Apr  3 17:44:46
2012
@@ -146,13 +146,12 @@ public class Destination extends Abstrac
 
         RMStore store = getReliableEndpoint().getManager().getStore();
         if (null != store) {
-            CachedOutputStream saved = null;
+            RMMessage msg = null;
             if (!MessageUtils.isTrue(message.getContextualProperty(Message.ROBUST_ONEWAY)))
{
-                saved = (CachedOutputStream)message.get(RMMessageConstants.SAVED_CONTENT);
+                msg = new RMMessage();
+                msg.setContent((CachedOutputStream)message.get(RMMessageConstants.SAVED_CONTENT));
+                msg.setMessageNumber(sequenceType.getMessageNumber());
             }
-            RMMessage msg = new RMMessage();
-            msg.setMessageNumber(sequenceType.getMessageNumber());
-            msg.setContent(saved);
             store.persistIncoming(seq, msg);
         }
 

Modified: cxf/trunk/rt/ws/rm/src/main/java/org/apache/cxf/ws/rm/persistence/jdbc/RMTxStore.java
URL: http://svn.apache.org/viewvc/cxf/trunk/rt/ws/rm/src/main/java/org/apache/cxf/ws/rm/persistence/jdbc/RMTxStore.java?rev=1309068&r1=1309067&r2=1309068&view=diff
==============================================================================
--- cxf/trunk/rt/ws/rm/src/main/java/org/apache/cxf/ws/rm/persistence/jdbc/RMTxStore.java
(original)
+++ cxf/trunk/rt/ws/rm/src/main/java/org/apache/cxf/ws/rm/persistence/jdbc/RMTxStore.java
Tue Apr  3 17:44:46 2012
@@ -480,7 +480,7 @@ public class RMTxStore implements RMStor
             
             updateDestinationSequence(seq);
             
-            if (msg.getCachedOutputStream() != null) {
+            if (msg != null && msg.getCachedOutputStream() != null) {
                 storeMessage(seq.getIdentifier(), msg, false);
             }
             
@@ -500,7 +500,7 @@ public class RMTxStore implements RMStor
             
             updateSourceSequence(seq);
             
-            if (msg.getCachedOutputStream() != null) {
+            if (msg != null && msg.getCachedOutputStream() != null) {
                 storeMessage(seq.getIdentifier(), msg, true);
             }
             



Mime
View raw message