summaryrefslogtreecommitdiffstats
path: root/bpmn/MSOCommonBPMN/src
diff options
context:
space:
mode:
authorsubhash kumar singh <subhash.kumar.singh@huawei.com>2018-11-17 12:45:58 +0530
committersubhash kumar singh <subhash.kumar.singh@huawei.com>2018-11-17 13:25:43 +0530
commitc9bdf8cf227a76d1130c327f6497a455f779955e (patch)
tree956a38fcf470a833050fc1902c2e30713bafd472 /bpmn/MSOCommonBPMN/src
parent351946d6f5ef7954fd7a09a59050d700997826eb (diff)
Fix request resource building
Fix request resource building. Change-Id: I64161359ae1b3d36ef3647382fab615d6afd6647 Issue-ID: SO-689 Signed-off-by: subhash kumar singh <subhash.kumar.singh@huawei.com>
Diffstat (limited to 'bpmn/MSOCommonBPMN/src')
-rw-r--r--bpmn/MSOCommonBPMN/src/main/java/org/onap/so/bpmn/common/resource/ResourceRequestBuilder.java18
1 files changed, 10 insertions, 8 deletions
diff --git a/bpmn/MSOCommonBPMN/src/main/java/org/onap/so/bpmn/common/resource/ResourceRequestBuilder.java b/bpmn/MSOCommonBPMN/src/main/java/org/onap/so/bpmn/common/resource/ResourceRequestBuilder.java
index 1989ca8cf9..b4851ee7a4 100644
--- a/bpmn/MSOCommonBPMN/src/main/java/org/onap/so/bpmn/common/resource/ResourceRequestBuilder.java
+++ b/bpmn/MSOCommonBPMN/src/main/java/org/onap/so/bpmn/common/resource/ResourceRequestBuilder.java
@@ -233,14 +233,16 @@ public class ResourceRequestBuilder {
private static Object getValue(Object value, Map<String, Object> serviceInputs, List<Input> servInputs) {
if(value instanceof Map) {
- Map<String, Object> valueMap = new HashMap<>();
-
- Map<String, Object> propertyMap = (Map<String, Object>)value;
-
- for(String key : propertyMap.keySet()) {
- valueMap.put(key, getValue(propertyMap.get(key), serviceInputs, servInputs));
- }
- return valueMap; // return if the value is nested hashmap
+ // currently this logic handles only one level of nesting.
+// Map<String, Object> valueMap = new HashMap<>();
+//
+// Map<String, Object> propertyMap = (Map<String, Object>)value;
+//
+// for(String key : propertyMap.keySet()) {
+// valueMap.put(key, getValue(propertyMap.get(key), serviceInputs, servInputs));
+// }
+// return valueMap; // return if the value is nested hashmap
+ return ((LinkedHashMap) value).values().toArray()[0];
} else if(value instanceof GetInput) {
String inputName = ((GetInput)value).getInputName();