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/bbobjects/L3Network.java20
-rw-r--r--bpmn/MSOCommonBPMN/src/main/java/org/onap/so/bpmn/servicedecomposition/tasks/BBInputSetup.java14
2 files changed, 31 insertions, 3 deletions
diff --git a/bpmn/MSOCommonBPMN/src/main/java/org/onap/so/bpmn/servicedecomposition/bbobjects/L3Network.java b/bpmn/MSOCommonBPMN/src/main/java/org/onap/so/bpmn/servicedecomposition/bbobjects/L3Network.java
index 6b3ad1d528..554e987fc8 100644
--- a/bpmn/MSOCommonBPMN/src/main/java/org/onap/so/bpmn/servicedecomposition/bbobjects/L3Network.java
+++ b/bpmn/MSOCommonBPMN/src/main/java/org/onap/so/bpmn/servicedecomposition/bbobjects/L3Network.java
@@ -100,6 +100,10 @@ public class L3Network implements Serializable, ShallowCopy<L3Network> {
private List<AggregateRoute> aggregateRoutes = new ArrayList<>();
@JsonProperty("vpn-binding")
private List<VpnBinding> vpnBindings = new ArrayList<>();
+ @JsonProperty("line-of-business")
+ private LineOfBusiness lineOfBusiness;
+ @JsonProperty("platform")
+ private Platform platform;
public ModelInfoNetwork getModelInfoNetwork() {
return modelInfoNetwork;
@@ -313,6 +317,22 @@ public class L3Network implements Serializable, ShallowCopy<L3Network> {
return vpnBindings;
}
+ public LineOfBusiness getLineOfBusiness() {
+ return lineOfBusiness;
+ }
+
+ public void setLineOfBusiness(LineOfBusiness lineOfBusiness) {
+ this.lineOfBusiness = lineOfBusiness;
+ }
+
+ public Platform getPlatform() {
+ return platform;
+ }
+
+ public void setPlatform(Platform platform) {
+ this.platform = platform;
+ }
+
@Override
public boolean equals(final Object other) {
if (!(other instanceof L3Network)) {
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 a5ad64ef55..e7e51bba77 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
@@ -908,7 +908,7 @@ public class BBInputSetup implements JavaDelegate {
if (network == null && (parameter.getBbName().equalsIgnoreCase(AssignFlows.NETWORK_A_LA_CARTE.toString())
|| parameter.getBbName().equalsIgnoreCase(AssignFlows.NETWORK_MACRO.toString()))) {
network = createNetwork(parameter.getLookupKeyMap(), parameter.getInstanceName(), parameter.getResourceId(),
- parameter.getInstanceParams());
+ parameter.getInstanceParams(), parameter);
parameter.getServiceInstance().getNetworks().add(network);
}
if (network != null) {
@@ -917,12 +917,20 @@ public class BBInputSetup implements JavaDelegate {
}
protected L3Network createNetwork(Map<ResourceKey, String> lookupKeyMap, String instanceName, String networkId,
- List<Map<String, String>> instanceParams) {
+ List<Map<String, String>> instanceParams, BBInputSetupParameter parameter) {
lookupKeyMap.put(ResourceKey.NETWORK_ID, networkId);
L3Network network = new L3Network();
network.setNetworkId(networkId);
network.setNetworkName(instanceName);
network.setOrchestrationStatus(OrchestrationStatus.PRECREATED);
+ if (parameter != null) {
+ if (parameter.getLineOfBusiness() != null) {
+ network.setLineOfBusiness(this.mapperLayer.mapRequestLineOfBusiness(parameter.getLineOfBusiness()));
+ }
+ if (parameter.getLineOfBusiness() != null) {
+ network.setPlatform(this.mapperLayer.mapRequestPlatform(parameter.getPlatform()));
+ }
+ }
if (instanceParams != null) {
for (Map<String, String> params : instanceParams) {
network.getCloudParams().putAll(params);
@@ -1277,7 +1285,7 @@ public class BBInputSetup implements JavaDelegate {
if (collectionNetworkResourceCust != null) {
if ((bbName.equalsIgnoreCase(AssignFlows.NETWORK_A_LA_CARTE.toString())
|| bbName.equalsIgnoreCase(AssignFlows.NETWORK_MACRO.toString()))) {
- L3Network network = createNetwork(lookupKeyMap, null, networkId, null);
+ L3Network network = createNetwork(lookupKeyMap, null, networkId, null, null);
serviceInstance.getNetworks().add(network);
return network;
} else {