summaryrefslogtreecommitdiffstats
path: root/sca-java-2.x/trunk/modules/implementation-java-runtime
diff options
context:
space:
mode:
Diffstat (limited to 'sca-java-2.x/trunk/modules/implementation-java-runtime')
-rw-r--r--sca-java-2.x/trunk/modules/implementation-java-runtime/src/main/java/org/apache/tuscany/sca/implementation/java/invocation/ResponseDispatchImpl.java9
1 files changed, 8 insertions, 1 deletions
diff --git a/sca-java-2.x/trunk/modules/implementation-java-runtime/src/main/java/org/apache/tuscany/sca/implementation/java/invocation/ResponseDispatchImpl.java b/sca-java-2.x/trunk/modules/implementation-java-runtime/src/main/java/org/apache/tuscany/sca/implementation/java/invocation/ResponseDispatchImpl.java
index 0d56a6ef9d..dc0bb94bde 100644
--- a/sca-java-2.x/trunk/modules/implementation-java-runtime/src/main/java/org/apache/tuscany/sca/implementation/java/invocation/ResponseDispatchImpl.java
+++ b/sca-java-2.x/trunk/modules/implementation-java-runtime/src/main/java/org/apache/tuscany/sca/implementation/java/invocation/ResponseDispatchImpl.java
@@ -63,6 +63,7 @@ public class ResponseDispatchImpl<T> implements ResponseDispatch<T>, Serializabl
*/
private static final long serialVersionUID = 300158355992568592L;
private static String WS_MESSAGE_ID = "WS_MESSAGE_ID";
+ private static String MESSAGE_ID = "MESSAGE_ID";
// A latch used to ensure that the sendResponse() and sendFault() operations are used at most once
// The latch is initialized with the value "false"
@@ -87,7 +88,12 @@ public class ResponseDispatchImpl<T> implements ResponseDispatch<T>, Serializabl
callbackRef = getAsyncCallbackRef( msg );
callbackAddress = msg.getFrom().getCallbackEndpoint().getURI();
- messageID = (String) msg.getHeaders().get(WS_MESSAGE_ID);
+
+ // TODO - why is WS stuff bleeding into general code?
+ messageID = (String) msg.getHeaders().get(MESSAGE_ID);
+ if (messageID == null){
+ messageID = (String) msg.getHeaders().get(WS_MESSAGE_ID);
+ }
} // end constructor
@@ -206,6 +212,7 @@ public class ResponseDispatchImpl<T> implements ResponseDispatch<T>, Serializabl
// Add in the header for the RelatesTo Message ID
msgContext.getHeaders().put(WS_MESSAGE_ID, messageID);
+ msgContext.getHeaders().put(MESSAGE_ID, messageID);
ThreadMessageContext.setMessageContext(msgContext);
} // end method setResponseHeaders