summaryrefslogtreecommitdiffstats
path: root/sca-java-2.x/trunk/modules/binding-jms/src/main/java/org/apache
diff options
context:
space:
mode:
authorantelder <antelder@13f79535-47bb-0310-9956-ffa450edef68>2012-01-24 09:24:13 +0000
committerantelder <antelder@13f79535-47bb-0310-9956-ffa450edef68>2012-01-24 09:24:13 +0000
commit87a97b4fa63dcfeea35782a1620f41edec438e36 (patch)
treea9d146235585605127d5dea3c83862aa5111e65d /sca-java-2.x/trunk/modules/binding-jms/src/main/java/org/apache
parent740d7810a5bf7c3adb810f577a4d340e961b0dbc (diff)
TUSCANY-4008: Apply patch from Jennifer A Thompson to fix JMS binding operationProperties 'selectedOperation' element not selecting the correct operation
git-svn-id: http://svn.us.apache.org/repos/asf/tuscany@1235180 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'sca-java-2.x/trunk/modules/binding-jms/src/main/java/org/apache')
-rw-r--r--sca-java-2.x/trunk/modules/binding-jms/src/main/java/org/apache/tuscany/sca/binding/jms/JMSBinding.java9
-rw-r--r--sca-java-2.x/trunk/modules/binding-jms/src/main/java/org/apache/tuscany/sca/binding/jms/JMSBindingProcessor.java1
2 files changed, 10 insertions, 0 deletions
diff --git a/sca-java-2.x/trunk/modules/binding-jms/src/main/java/org/apache/tuscany/sca/binding/jms/JMSBinding.java b/sca-java-2.x/trunk/modules/binding-jms/src/main/java/org/apache/tuscany/sca/binding/jms/JMSBinding.java
index 1abfd4e8b3..d8e7b24a36 100644
--- a/sca-java-2.x/trunk/modules/binding-jms/src/main/java/org/apache/tuscany/sca/binding/jms/JMSBinding.java
+++ b/sca-java-2.x/trunk/modules/binding-jms/src/main/java/org/apache/tuscany/sca/binding/jms/JMSBinding.java
@@ -131,6 +131,7 @@ public class JMSBinding implements Binding, PolicySubject, OperationsConfigurato
private Map<String, Object> properties = new HashMap<String, Object>();
private Map<String, Map<String, Object>> operationProperties = new HashMap<String, Map<String,Object>>();
private Map<String, String> nativeOperationNames = new HashMap<String, String>();
+ private Map<String, String> nativeOperationNamesToOpName = new HashMap<String, String>();
private Map<String, String> operationJMSTypes = new HashMap<String, String>();
private Map<String, String> operationJMSCorrelationIds = new HashMap<String, String>();
private Map<String, Boolean> operationJMSDeliveryModes = new HashMap<String, Boolean>();
@@ -667,6 +668,14 @@ public class JMSBinding implements Binding, PolicySubject, OperationsConfigurato
public Map<String, String> getNativeOperationNames() {
return nativeOperationNames;
}
+
+ public void setNativeOperationNameToOpName(String nativeOpName, String opName) {
+ this.nativeOperationNamesToOpName.put(nativeOpName, opName);
+ }
+
+ public String getOpNameFromNativeOperationName(String nativeOpName) {
+ return nativeOperationNamesToOpName.get(nativeOpName);
+ }
public String getOperationJMSType(String opName) {
if (operationPropertiesBinding != null && operationPropertiesBinding.getOperationJMSType(opName) != null) {
diff --git a/sca-java-2.x/trunk/modules/binding-jms/src/main/java/org/apache/tuscany/sca/binding/jms/JMSBindingProcessor.java b/sca-java-2.x/trunk/modules/binding-jms/src/main/java/org/apache/tuscany/sca/binding/jms/JMSBindingProcessor.java
index 676d9b750b..40a1c27980 100644
--- a/sca-java-2.x/trunk/modules/binding-jms/src/main/java/org/apache/tuscany/sca/binding/jms/JMSBindingProcessor.java
+++ b/sca-java-2.x/trunk/modules/binding-jms/src/main/java/org/apache/tuscany/sca/binding/jms/JMSBindingProcessor.java
@@ -846,6 +846,7 @@ public class JMSBindingProcessor extends BaseStAXArtifactProcessor implements St
String nativeOpName = reader.getAttributeValue(null, "selectedOperation"); // optional
if (nativeOpName != null && nativeOpName.length() > 0) {
jmsBinding.setNativeOperationName(opName, nativeOpName);
+ jmsBinding.setNativeOperationNameToOpName(nativeOpName, opName);
}
Map<String, BindingProperty> props = new HashMap<String, BindingProperty>();