Fixed vnfTopoOperation vnf-id return in response 47/63047/2
authorshashikanth.vh <shashikanth.vh@huawei.com>
Mon, 27 Aug 2018 11:11:22 +0000 (16:41 +0530)
committerShashikanth VH <shashikanth.vh@huawei.com>
Mon, 27 Aug 2018 12:57:52 +0000 (12:57 +0000)
Fixed issue vnfTopologyOperation, vnf-id not returning in response when vnf-id
is not provided as part of input

Change-Id: Iaa3b1387a45c60c27e3fdf1120e127648323e352
Issue-ID: SDNC-434
Signed-off-by: shashikanth.vh <shashikanth.vh@huawei.com>
generic-resource-api/provider/src/main/java/org/onap/sdnc/northbound/GenericResourceApiProvider.java

index 8609b60..d29e674 100644 (file)
@@ -869,6 +869,9 @@ public class GenericResourceApiProvider implements AutoCloseable, GENERICRESOURC
             responseObject.setMessage(respProps.getProperty(ERROR_MESSAGE_PARAM));
             responseObject.setStatusCode(respProps.getProperty(ERROR_CODE_PARAM));
             ackFinal = respProps.getProperty(ACK_FINAL_PARAM, "Y");
+            if (vnfId == null) {
+                vnfId = respProps.getProperty("vnfId");
+            }
             serviceObjectPath = respProps.getProperty(SERVICE_OBJECT_PATH_PARAM);
             vnfObjectPath = respProps.getProperty(VNF_OBJECT_PATH_PARAM);
         }