aboutsummaryrefslogtreecommitdiffstats
path: root/bpmn/MSOCommonBPMN
diff options
context:
space:
mode:
Diffstat (limited to 'bpmn/MSOCommonBPMN')
-rw-r--r--bpmn/MSOCommonBPMN/pom.xml4
-rw-r--r--bpmn/MSOCommonBPMN/src/main/java/org/onap/so/bpmn/servicedecomposition/tasks/BBInputSetup.java14
-rw-r--r--bpmn/MSOCommonBPMN/src/test/groovy/org/onap/so/bpmn/common/scripts/SDNCAdapterTest.groovy7
-rw-r--r--bpmn/MSOCommonBPMN/src/test/resources/logback-test.xml2
4 files changed, 18 insertions, 9 deletions
diff --git a/bpmn/MSOCommonBPMN/pom.xml b/bpmn/MSOCommonBPMN/pom.xml
index c051aac9b8..d5c9f05a27 100644
--- a/bpmn/MSOCommonBPMN/pom.xml
+++ b/bpmn/MSOCommonBPMN/pom.xml
@@ -5,7 +5,7 @@
<parent>
<groupId>org.onap.so</groupId>
<artifactId>bpmn</artifactId>
- <version>1.8.0-SNAPSHOT</version>
+ <version>1.9.0-SNAPSHOT</version>
</parent>
<artifactId>MSOCommonBPMN</artifactId>
<name>MSOCommonBPMN</name>
@@ -163,7 +163,7 @@
<dependency>
<groupId>commons-beanutils</groupId>
<artifactId>commons-beanutils</artifactId>
- </dependency>
+ </dependency>
<dependency>
<!-- Needed for InMemoryH2Test -->
<groupId>com.h2database</groupId>
diff --git a/bpmn/MSOCommonBPMN/src/main/java/org/onap/so/bpmn/servicedecomposition/tasks/BBInputSetup.java b/bpmn/MSOCommonBPMN/src/main/java/org/onap/so/bpmn/servicedecomposition/tasks/BBInputSetup.java
index 5cbadd6b75..83d1f5249f 100644
--- a/bpmn/MSOCommonBPMN/src/main/java/org/onap/so/bpmn/servicedecomposition/tasks/BBInputSetup.java
+++ b/bpmn/MSOCommonBPMN/src/main/java/org/onap/so/bpmn/servicedecomposition/tasks/BBInputSetup.java
@@ -1054,8 +1054,18 @@ public class BBInputSetup implements JavaDelegate {
if (requestDetails.getOwningEntity() != null)
owningEntity = mapperLayer.mapRequestOwningEntity(requestDetails.getOwningEntity());
- Service service =
- bbInputSetupUtils.getCatalogServiceByModelUUID(requestDetails.getModelInfo().getModelVersionId());
+ String modelVersionId = requestDetails.getModelInfo().getModelVersionId();
+
+ if (ModelType.vnf == requestDetails.getModelInfo().getModelType()) {
+ for (RelatedInstanceList relatedInstanceList : requestDetails.getRelatedInstanceList()) {
+ if (ModelType.service == relatedInstanceList.getRelatedInstance().getModelInfo().getModelType()) {
+ modelVersionId = relatedInstanceList.getRelatedInstance().getModelInfo().getModelVersionId();
+ break;
+ }
+ }
+ }
+
+ Service service = bbInputSetupUtils.getCatalogServiceByModelUUID(modelVersionId);
if (service == null) {
service = bbInputSetupUtils.getCatalogServiceByModelVersionAndModelInvariantUUID(
requestDetails.getModelInfo().getModelVersion(),
diff --git a/bpmn/MSOCommonBPMN/src/test/groovy/org/onap/so/bpmn/common/scripts/SDNCAdapterTest.groovy b/bpmn/MSOCommonBPMN/src/test/groovy/org/onap/so/bpmn/common/scripts/SDNCAdapterTest.groovy
index 3438c7957c..235b6219d1 100644
--- a/bpmn/MSOCommonBPMN/src/test/groovy/org/onap/so/bpmn/common/scripts/SDNCAdapterTest.groovy
+++ b/bpmn/MSOCommonBPMN/src/test/groovy/org/onap/so/bpmn/common/scripts/SDNCAdapterTest.groovy
@@ -22,7 +22,6 @@ package org.onap.so.bpmn.common.scripts
import static org.mockito.Mockito.*
-
import org.camunda.bpm.engine.ProcessEngineServices
import org.camunda.bpm.engine.RepositoryService
import org.camunda.bpm.engine.impl.persistence.entity.ExecutionEntity
@@ -48,10 +47,10 @@ public class SDNCAdapterTest {
}
- String workflowResponse = """<sdncadapterworkflow:SDNCAdapterWorkflowResponse xmlns:sdncadapterworkflow="http://org.onap/so/workflow/schema/v1"
+ String workflowResponse = """<sdncadapterworkflow:SDNCAdapterWorkflowResponse xmlns="com:att:sdnctl:l3api"
+ xmlns:sdncadapterworkflow="http://org.onap/so/workflow/schema/v1"
xmlns:tag0="http://org.onap/workflow/sdnc/adapter/schema/v1"
- xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xmlns="com:att:sdnctl:l3api">
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<sdncadapterworkflow:response-data>
<tag0:CallbackHeader>
<tag0:RequestId>testRequestId</tag0:RequestId>
diff --git a/bpmn/MSOCommonBPMN/src/test/resources/logback-test.xml b/bpmn/MSOCommonBPMN/src/test/resources/logback-test.xml
index 9088d1a844..90f73dc419 100644
--- a/bpmn/MSOCommonBPMN/src/test/resources/logback-test.xml
+++ b/bpmn/MSOCommonBPMN/src/test/resources/logback-test.xml
@@ -24,7 +24,7 @@
<root level="WARN">
<appender-ref ref="STDOUT" />
</root>
-
+ <logger name="org.reflections" level="ERROR" />
<logger name="wiremock.org" level="ERROR" />
</configuration> \ No newline at end of file