aboutsummaryrefslogtreecommitdiffstats
path: root/adapters/mso-openstack-adapters/src/main/java
diff options
context:
space:
mode:
authorLukasz Muszkieta <lukasz.muszkieta@nokia.com>2020-07-15 15:34:37 +0000
committerGerrit Code Review <gerrit@onap.org>2020-07-15 15:34:37 +0000
commit86270eae84f8178ada7649e4ce431aaf8da4ab81 (patch)
treef9fddd8cf56922c16cc8c052970d99fd8d89ec04 /adapters/mso-openstack-adapters/src/main/java
parentc2289b86be119991c6fabf4ce9c6c69a4fcd4496 (diff)
parentc4e6325326b32a5b09ef7a92fb4a91fd3b31a377 (diff)
Merge "Create vserver if not exists"
Diffstat (limited to 'adapters/mso-openstack-adapters/src/main/java')
-rw-r--r--adapters/mso-openstack-adapters/src/main/java/org/onap/so/heatbridge/HeatBridgeImpl.java4
1 files changed, 2 insertions, 2 deletions
diff --git a/adapters/mso-openstack-adapters/src/main/java/org/onap/so/heatbridge/HeatBridgeImpl.java b/adapters/mso-openstack-adapters/src/main/java/org/onap/so/heatbridge/HeatBridgeImpl.java
index a3d096e627..3f5d25b93f 100644
--- a/adapters/mso-openstack-adapters/src/main/java/org/onap/so/heatbridge/HeatBridgeImpl.java
+++ b/adapters/mso-openstack-adapters/src/main/java/org/onap/so/heatbridge/HeatBridgeImpl.java
@@ -256,8 +256,8 @@ public class HeatBridgeImpl implements HeatBridgeApi {
// Build vserver relationships to: image, flavor, pserver, vf-module
vserver.setRelationshipList(
aaiHelper.getVserverRelationshipList(cloudOwner, cloudRegionId, genericVnfId, vfModuleId, server));
- transaction.create(AAIUriFactory.createResourceUri(AAIObjectType.VSERVER, cloudOwner, cloudRegionId,
- tenantId, vserver.getVserverId()), vserver);
+ transaction.createIfNotExists(AAIUriFactory.createResourceUri(AAIObjectType.VSERVER, cloudOwner,
+ cloudRegionId, tenantId, vserver.getVserverId()), Optional.of(vserver));
});
}