aboutsummaryrefslogtreecommitdiffstats
path: root/bpmn/MSOCommonBPMN/src/main/java
diff options
context:
space:
mode:
Diffstat (limited to 'bpmn/MSOCommonBPMN/src/main/java')
-rw-r--r--bpmn/MSOCommonBPMN/src/main/java/org/onap/so/bpmn/servicedecomposition/generalobjects/RequestContext.java10
-rw-r--r--bpmn/MSOCommonBPMN/src/main/java/org/onap/so/bpmn/servicedecomposition/tasks/BBInputSetup.java15
-rw-r--r--bpmn/MSOCommonBPMN/src/main/java/org/onap/so/bpmn/servicedecomposition/tasks/BBInputSetupParameter.java21
3 files changed, 44 insertions, 2 deletions
diff --git a/bpmn/MSOCommonBPMN/src/main/java/org/onap/so/bpmn/servicedecomposition/generalobjects/RequestContext.java b/bpmn/MSOCommonBPMN/src/main/java/org/onap/so/bpmn/servicedecomposition/generalobjects/RequestContext.java
index 0193469d93..12abec0b77 100644
--- a/bpmn/MSOCommonBPMN/src/main/java/org/onap/so/bpmn/servicedecomposition/generalobjects/RequestContext.java
+++ b/bpmn/MSOCommonBPMN/src/main/java/org/onap/so/bpmn/servicedecomposition/generalobjects/RequestContext.java
@@ -57,6 +57,16 @@ public class RequestContext implements Serializable {
private List<Map<String, String>> configurationParameters = new ArrayList<>();
@JsonProperty("application-id")
private String applicationId;
+ @JsonProperty("is-helm")
+ private Boolean isHelm;
+
+ public Boolean getIsHelm() {
+ return isHelm;
+ }
+
+ public void setIsHelm(Boolean isHelm) {
+ this.isHelm = isHelm;
+ }
public String getServiceURI() {
return serviceURI;
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 a371839244..5a8244266b 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
@@ -193,6 +193,12 @@ public class BBInputSetup implements JavaDelegate {
execution.setVariable(GBB_INPUT_VAR_NAME, outputBB);
execution.setVariable(LOOKUP_KEY_MAP_VAR_NAME, lookupKeyMap);
+ if (outputBB.getRequestContext().getIsHelm()) {
+ execution.setVariable("isHelm", true);
+ } else {
+ execution.setVariable("isHelm", false);
+ }
+
BuildingBlockExecution gBuildingBlockExecution = new DelegateExecutionImpl(execution);
execution.setVariable("gBuildingBlockExecution", gBuildingBlockExecution);
execution.setVariable("RetryCount", 1);
@@ -431,7 +437,8 @@ public class BBInputSetup implements JavaDelegate {
protected void mapCatalogInstanceGroup(InstanceGroup instanceGroup, ModelInfo modelInfo, Service service) {
// @TODO: this will populate the instanceGroup model info.
- // Dependent on MSO-5821 653458 US - MSO - Enhance Catalog DB Schema & Adapter to support VNF Groups
+ // Dependent on MSO-5821 653458 US - MSO - Enhance Catalog DB Schema & Adapter
+ // to support VNF Groups
}
protected void populateConfiguration(BBInputSetupParameter parameter) {
@@ -613,6 +620,10 @@ public class BBInputSetup implements JavaDelegate {
parameter.getServiceModel().getCurrentService(), vnfModelCustomizationUUID);
}
}
+ if (vfModule.getModelInfoVfModule() != null && vfModule.getModelInfoVfModule().getModelName() != null
+ && vfModule.getModelInfoVfModule().getModelName().contains("helm")) {
+ parameter.setIsHelm(true);
+ }
} else {
logger.debug("Related VNF instance Id not found: {}",
parameter.getLookupKeyMap().get(ResourceKey.GENERIC_VNF_ID));
@@ -1018,7 +1029,6 @@ public class BBInputSetup implements JavaDelegate {
if (requestDetails.getOwningEntity() != null)
owningEntity = mapperLayer.mapRequestOwningEntity(requestDetails.getOwningEntity());
-
Service service =
bbInputSetupUtils.getCatalogServiceByModelUUID(requestDetails.getModelInfo().getModelVersionId());
if (service == null) {
@@ -1094,6 +1104,7 @@ public class BBInputSetup implements JavaDelegate {
RequestContext requestContext = mapperLayer.mapRequestContext(parameter.getRequestDetails());
requestContext.setAction(parameter.getRequestAction());
requestContext.setMsoRequestId(parameter.getExecuteBB().getRequestId());
+ requestContext.setIsHelm(parameter.getIsHelm());
org.onap.aai.domain.yang.CloudRegion aaiCloudRegion =
bbInputSetupUtils.getCloudRegion(parameter.getRequestDetails().getCloudConfiguration());
CloudRegion cloudRegion =
diff --git a/bpmn/MSOCommonBPMN/src/main/java/org/onap/so/bpmn/servicedecomposition/tasks/BBInputSetupParameter.java b/bpmn/MSOCommonBPMN/src/main/java/org/onap/so/bpmn/servicedecomposition/tasks/BBInputSetupParameter.java
index 36ac0969ee..1290f2aeef 100644
--- a/bpmn/MSOCommonBPMN/src/main/java/org/onap/so/bpmn/servicedecomposition/tasks/BBInputSetupParameter.java
+++ b/bpmn/MSOCommonBPMN/src/main/java/org/onap/so/bpmn/servicedecomposition/tasks/BBInputSetupParameter.java
@@ -45,6 +45,7 @@ public class BBInputSetupParameter {
private String applicationId;
private boolean isReplace;
private ServiceModel serviceModel;
+ private boolean isHelm;
private BBInputSetupParameter(Builder builder) {
this.cloudConfiguration = builder.cloudConfiguration;
@@ -74,6 +75,7 @@ public class BBInputSetupParameter {
this.applicationId = builder.applicationId;
this.isReplace = builder.isReplace;
this.serviceModel = builder.serviceModel;
+ this.isHelm = builder.isHelm;
}
@@ -331,6 +333,15 @@ public class BBInputSetupParameter {
this.serviceModel = serviceModel;
}
+ protected boolean getIsHelm() {
+ return isHelm;
+ }
+
+
+ protected void setIsHelm(boolean isHelm) {
+ this.isHelm = isHelm;
+ }
+
public static class Builder {
private CloudConfiguration cloudConfiguration;
private ConfigurationResourceKeys configurationResourceKeys;
@@ -359,6 +370,7 @@ public class BBInputSetupParameter {
private String applicationId;
private boolean isReplace;
private ServiceModel serviceModel;
+ private boolean isHelm;
public Builder setCloudConfiguration(CloudConfiguration cloudConfiguration) {
this.cloudConfiguration = cloudConfiguration;
@@ -495,6 +507,15 @@ public class BBInputSetupParameter {
return this;
}
+ protected boolean getIsHelm() {
+ return isHelm;
+ }
+
+
+ protected void setIsHelm(boolean isHelm) {
+ this.isHelm = isHelm;
+ }
+
public BBInputSetupParameter build() {
return new BBInputSetupParameter(this);
}