From fe350c06cb12d14e87d4060d5fc9cee97ed31987 Mon Sep 17 00:00:00 2001 From: "Boslet, Cory" Date: Wed, 15 Jan 2020 16:05:12 -0500 Subject: Use the timeout from the heat template instead of Use the timeout from the heat template instead of hardcode WIP Added custom uuid to vf adapter delete rest request Added and fixed compilations errors due to interface change added logic to check that the timeout is less than 120 Set the cust model uuid in bpmn so its avaiable to adapter. Added to use timeout from heat template for network. Updated unit test to account for new param change to method. Fixed and added missing param to deletevf in vnfadapterrestv2 Fixed failing junits due to adding model cust id to request Issue-ID: SO-2601 Signed-off-by: Benjamin, Max (mb388a) Change-Id: I6ac276f37d4b6423501fb07fe081828ea3bed235 --- .../client/adapter/vnf/mapper/VnfAdapterVfModuleObjectMapper.java | 4 ++++ .../VnfAndVfModuleMapper/vnfAdapterDeleteVfModuleRequest.json | 7 ++++--- 2 files changed, 8 insertions(+), 3 deletions(-) (limited to 'bpmn/so-bpmn-tasks') diff --git a/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/client/adapter/vnf/mapper/VnfAdapterVfModuleObjectMapper.java b/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/client/adapter/vnf/mapper/VnfAdapterVfModuleObjectMapper.java index 9857adbd09..bc618e17de 100644 --- a/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/client/adapter/vnf/mapper/VnfAdapterVfModuleObjectMapper.java +++ b/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/client/adapter/vnf/mapper/VnfAdapterVfModuleObjectMapper.java @@ -879,6 +879,10 @@ public class VnfAdapterVfModuleObjectMapper { deleteVfModuleRequest.setTenantId(cloudRegion.getTenantId()); deleteVfModuleRequest.setVnfId(genericVnf.getVnfId()); deleteVfModuleRequest.setVfModuleId(vfModule.getVfModuleId()); + if (vfModule.getModelInfoVfModule() != null) { + deleteVfModuleRequest + .setModelCustomizationUuid(vfModule.getModelInfoVfModule().getModelCustomizationUUID()); + } if (!StringUtils.isEmpty(vfModule.getHeatStackId())) { deleteVfModuleRequest.setVfModuleStackId(vfModule.getHeatStackId());// DoDVfMod_heatStackId } else { diff --git a/bpmn/so-bpmn-tasks/src/test/resources/__files/BuildingBlocks/VnfAndVfModuleMapper/vnfAdapterDeleteVfModuleRequest.json b/bpmn/so-bpmn-tasks/src/test/resources/__files/BuildingBlocks/VnfAndVfModuleMapper/vnfAdapterDeleteVfModuleRequest.json index 1d2e7d090f..9a3922650f 100644 --- a/bpmn/so-bpmn-tasks/src/test/resources/__files/BuildingBlocks/VnfAndVfModuleMapper/vnfAdapterDeleteVfModuleRequest.json +++ b/bpmn/so-bpmn-tasks/src/test/resources/__files/BuildingBlocks/VnfAndVfModuleMapper/vnfAdapterDeleteVfModuleRequest.json @@ -1,12 +1,13 @@ -{ +{ "cloudSiteId" : "cloudRegionId", - "tenantId" : "tenantId", + "tenantId" : "tenantId", "vnfId" : "vnfId", "vfModuleId" : "vfModuleId", "vfModuleStackId" : "vfModuleName", "skipAAI" : true, + "modelCustomizationUuid": "vfModuleModelCustomizationUuid", "msoRequest" : { "requestId" : "requestId", - "serviceInstanceId" : "serviceInstanceId" + "serviceInstanceId" : "serviceInstanceId" } } \ No newline at end of file -- cgit 1.2.3-korg