From a95005030698acf9def8849f44e1649d0bcf00d8 Mon Sep 17 00:00:00 2001 From: Alexey Sandler Date: Mon, 16 Sep 2019 13:37:01 +0300 Subject: Add cloud-region and nf-role as an optional search criteria Issue-ID: VID-596 Signed-off-by: Alexey Sandler Change-Id: I72d9c2c9dc3f39fcc3c87e083ac230d20135e979 --- .../src/main/java/org/onap/vid/aai/AaiClient.java | 34 +++- .../java/org/onap/vid/aai/AaiClientInterface.java | 2 +- .../org/onap/vid/controller/AaiController2.java | 3 +- .../test/java/org/onap/vid/aai/AaiClientTest.java | 38 +++- ...fs-fromServiceInstance-filterByCloudRegion.json | 189 ++++++++++++++++++ .../vnfs-fromServiceInstance-filterNfRole.json | 216 +++++++++++++++++++++ 6 files changed, 465 insertions(+), 17 deletions(-) create mode 100644 vid-app-common/src/test/resources/payload_jsons/changeManagement/vnfs-fromServiceInstance-filterByCloudRegion.json create mode 100644 vid-app-common/src/test/resources/payload_jsons/changeManagement/vnfs-fromServiceInstance-filterNfRole.json diff --git a/vid-app-common/src/main/java/org/onap/vid/aai/AaiClient.java b/vid-app-common/src/main/java/org/onap/vid/aai/AaiClient.java index c82f5485e..644309d95 100644 --- a/vid-app-common/src/main/java/org/onap/vid/aai/AaiClient.java +++ b/vid-app-common/src/main/java/org/onap/vid/aai/AaiClient.java @@ -289,7 +289,7 @@ public class AaiClient implements AaiClientInterface { } @Override - public AaiResponse getVnfsByParamsForChangeManagement(String subscriberId, String serviceType, @Nullable String nfRole, + public AaiResponse getVnfsByParamsForChangeManagement(String subscriberId, String serviceType, @Nullable String nfRole, @Nullable String cloudRegion) { String payloadAsString = ""; ResponseWithRequestInfo response; @@ -302,19 +302,43 @@ public class AaiClient implements AaiClientInterface { ExceptionUtils.rethrow(e); } response = doAaiPut(QUERY_FORMAT_SIMPLE, payloadAsString, false, false); - AaiResponseWithRequestInfo aaiResponse = processAaiResponse(response, JsonNode.class, false); + AaiResponseWithRequestInfo aaiResponse = processAaiResponse(response, AaiGetVnfResponse.class, false); verifyAaiResponseValidityOrThrowExc(aaiResponse, aaiResponse.getAaiResponse().getHttpCode()); return aaiResponse.getAaiResponse(); } private ImmutableMap getMapForAAIQueryByParams(String subscriberId, String serviceType, @Nullable String nfRole, @Nullable String cloudRegion) { - String nfRoleParam = nfRole != null ? "?nfRole=" + nfRole : ""; - String query = "query/vnfs-fromServiceInstance-filter" + nfRoleParam; + // in a case cloudRegion is null using query/vnfs-fromServiceInstance-filter, + // otherwise using query/vnfs-fromServiceInstance-filterByCloudRegion + if (nfRole != null){ + if (cloudRegion != null){ + return ImmutableMap.of( + "start", ImmutableList + .of("/business/customers/customer/" + subscriberId + "/service-subscriptions/service-subscription/" + serviceType + "/service-instances"), + "query", "query/vnfs-fromServiceInstance-filterByCloudRegion?nfRole=" + nfRole + "&cloudRegionID=" + cloudRegion + "" + ); + }else { + return ImmutableMap.of( + "start", ImmutableList + .of("/business/customers/customer/" + subscriberId + "/service-subscriptions/service-subscription/" + serviceType + "/service-instances"), + "query", "query/vnfs-fromServiceInstance-filter?nfRole=" + nfRole + "" + ); + } + } + + if (cloudRegion != null){ + return ImmutableMap.of( + "start", ImmutableList + .of("/business/customers/customer/" + subscriberId + "/service-subscriptions/service-subscription/" + serviceType + "/service-instances"), + "query", "query/vnfs-fromServiceInstance-filterByCloudRegion?cloudRegionID=" + cloudRegion + "" + ); + } + return ImmutableMap.of( "start", ImmutableList .of("/business/customers/customer/" + subscriberId + "/service-subscriptions/service-subscription/" + serviceType + "/service-instances"), - "query", query + "query", "query/vnfs-fromServiceInstance-filter" ); } diff --git a/vid-app-common/src/main/java/org/onap/vid/aai/AaiClientInterface.java b/vid-app-common/src/main/java/org/onap/vid/aai/AaiClientInterface.java index 8c3c66d17..af5429c28 100644 --- a/vid-app-common/src/main/java/org/onap/vid/aai/AaiClientInterface.java +++ b/vid-app-common/src/main/java/org/onap/vid/aai/AaiClientInterface.java @@ -103,5 +103,5 @@ public interface AaiClientInterface extends ProbeInterface { Map getCloudRegionAndTenantByVnfId(String vnfId); - AaiResponse getVnfsByParamsForChangeManagement(String subscriberId, String serviceType, String nfRole, String cloudRegion); + AaiResponse getVnfsByParamsForChangeManagement(String subscriberId, String serviceType, String nfRole, String cloudRegion); } diff --git a/vid-app-common/src/main/java/org/onap/vid/controller/AaiController2.java b/vid-app-common/src/main/java/org/onap/vid/controller/AaiController2.java index d1f7a97b5..6431282e7 100644 --- a/vid-app-common/src/main/java/org/onap/vid/controller/AaiController2.java +++ b/vid-app-common/src/main/java/org/onap/vid/controller/AaiController2.java @@ -25,6 +25,7 @@ import java.util.stream.Collectors; import javax.servlet.http.HttpServletRequest; import org.apache.commons.lang3.StringUtils; import org.onap.vid.aai.AaiClientInterface; +import org.onap.vid.aai.AaiGetVnfResponse; import org.onap.vid.aai.model.AaiGetTenatns.GetTenantsResponse; import org.onap.vid.aai.model.ModelVer; import org.onap.vid.aai.model.Permissions; @@ -134,7 +135,7 @@ public class AaiController2 extends VidRestrictedBaseController { } @GetMapping(value = "/get_vnf_data_by_globalid_and_service_type/{globalCustomerId}/{serviceType}") - public Object getVnfDataByGlobalIdAndServiceType( + public AaiGetVnfResponse getVnfDataByGlobalIdAndServiceType( @PathVariable("globalCustomerId") String globalCustomerId, @PathVariable("serviceType") String serviceType, @RequestParam(name="nfRole", required = false) String nfRole, diff --git a/vid-app-common/src/test/java/org/onap/vid/aai/AaiClientTest.java b/vid-app-common/src/test/java/org/onap/vid/aai/AaiClientTest.java index 9629e4634..8cb3a5024 100644 --- a/vid-app-common/src/test/java/org/onap/vid/aai/AaiClientTest.java +++ b/vid-app-common/src/test/java/org/onap/vid/aai/AaiClientTest.java @@ -137,21 +137,39 @@ public class AaiClientTest { }; } - @Test - public void testAaiPutCustomQueryByParams() { - String globalCustomerId = "globalCustomerId1-360-as988q"; - String serviceType = "TEST1-360"; - String nfRole = "test360"; + private static String nfRoleOnly = "{\"start\":[\"/business/customers/customer/globalCustomerId1-360-as988q/service-subscriptions/service-subscription/TEST1-360/service-instances\"],\"query\":\"query/vnfs-fromServiceInstance-filter?nfRole=test360\"}"; + private static String nfRoleAndCloudRegion = "{\"start\":[\"/business/customers/customer/globalCustomerId1-360-as988q/service-subscriptions/service-subscription/TEST1-360/service-instances\"],\"query\":\"query/vnfs-fromServiceInstance-filterByCloudRegion?nfRole=test360&cloudRegionID=cloudRegion-1\"}"; + private static String cloudRegionOnly = "{\"start\":[\"/business/customers/customer/globalCustomerId1-360-as988q/service-subscriptions/service-subscription/TEST1-360/service-instances\"],\"query\":\"query/vnfs-fromServiceInstance-filterByCloudRegion?cloudRegionID=cloudRegion-1\"}"; + private static String withoutNfroleAndCloudRegion = "{\"start\":[\"/business/customers/customer/globalCustomerId1-360-as988q/service-subscriptions/service-subscription/TEST1-360/service-instances\"],\"query\":\"query/vnfs-fromServiceInstance-filter\"}"; + + private static String responseJsonNfRole = "/payload_jsons/changeManagement/vnfs-fromServiceInstance-filterNfRole.json"; + private static String responseJsonCloudRegion ="/payload_jsons/changeManagement/vnfs-fromServiceInstance-filterByCloudRegion.json"; + + + @DataProvider + public static Object[][] aaiPutCustomQueryData() { + return new Object[][] { + {"globalCustomerId1-360-as988q", "TEST1-360", "test360", null, nfRoleOnly, responseJsonNfRole, "908419144", 200}, + {"globalCustomerId1-360-as988q", "TEST1-360", null, "cloudRegion-1", cloudRegionOnly, responseJsonCloudRegion, "1165906024", 200}, + {"globalCustomerId1-360-as988q", "TEST1-360", "test360", "cloudRegion-1", nfRoleAndCloudRegion, + responseJsonCloudRegion, "1165906024", 200}, + {"globalCustomerId1-360-as988q", "TEST1-360", null, null, withoutNfroleAndCloudRegion, responseJsonNfRole, "908419144", 200}, + }; + } + + @Test(dataProvider = "aaiPutCustomQueryData") + public void testAaiPutCustomQueryByParams(String globalCustomerId, String serviceType, String nfRole, String cloudRegion, String expectedPayload, String responseBody, String expectedId, int responseHttpCode) { String queryFormat = "query?format=simple"; final ResponseWithRequestInfo mockedResponseWithRequestInfo = mockedResponseWithRequestInfo(Response.Status.OK, - TestUtils.readFileAsString("/payload_jsons/changeManagement/get_vnf_data_by_globalid_and_service_type_reduced_response.json"), + TestUtils.readFileAsString(responseBody), "query?format=simple&Mock=True", HttpMethod.PUT); - when(aaiClientMock.getVnfsByParamsForChangeManagement(anyString(), anyString(),anyString(), nullable(String.class))).thenCallRealMethod(); when(aaiClientMock.doAaiPut(eq(queryFormat), anyString(), anyBoolean(), anyBoolean())).thenReturn(mockedResponseWithRequestInfo); - AaiResponse response = aaiClientMock.getVnfsByParamsForChangeManagement(globalCustomerId, serviceType, nfRole, null); - verify(aaiClientMock).doAaiPut(anyString(), anyString(),anyBoolean(),anyBoolean()); - response.toString(); + when(aaiClientMock.getVnfsByParamsForChangeManagement(anyString(), anyString(), nullable(String.class), nullable(String.class))).thenCallRealMethod(); + AaiResponse response = aaiClientMock.getVnfsByParamsForChangeManagement(globalCustomerId, serviceType, nfRole, cloudRegion); + verify(aaiClientMock).doAaiPut(eq(queryFormat), eq(expectedPayload), eq(false), eq(false)); + assertEquals(response.getHttpCode(), responseHttpCode); + assertEquals(response.getT().getResults().get(0).id, expectedId); } @Test(dataProvider = "logicalLinkData") diff --git a/vid-app-common/src/test/resources/payload_jsons/changeManagement/vnfs-fromServiceInstance-filterByCloudRegion.json b/vid-app-common/src/test/resources/payload_jsons/changeManagement/vnfs-fromServiceInstance-filterByCloudRegion.json new file mode 100644 index 000000000..ac20d9142 --- /dev/null +++ b/vid-app-common/src/test/resources/payload_jsons/changeManagement/vnfs-fromServiceInstance-filterByCloudRegion.json @@ -0,0 +1,189 @@ +{ + "results": [ + { + "id": "1165906024", + "node-type": "service-instance", + "url": "/aai/v17/business/customers/customer/globalCustomerId1-360-as988q/service-subscriptions/service-subscription/TEST1-360/service-instances/service-instance/serviceInstanceID1-360-as988q", + "properties": { + "service-instance-id": "serviceInstanceID1-360-as988q", + "service-instance-name": "EUd8Test", + "service-type": "xBoJHJbWTest", + "service-role": "sc7OWTest", + "environment-context": "O7OVp5Test", + "workload-context": "VmnxNeJIgWq7HTest", + "model-invariant-id": "modelInvariantValue2-360-as988q", + "model-version-id": "modelVersionKey2-360-as988q", + "widget-model-id": "HT7KA2FoRKH3cTest", + "widget-model-version": "CsGp5Test", + "bandwidth-total": "1Yijkk1Test", + "vhn-portal-url": "40PzTest", + "service-instance-location-id": "zcAaHJTAt5Hj8Test", + "resource-version": "1563819746503", + "selflink": "mZP2EVvwwHnlTest", + "orchestration-status": "6QvhzNgLudLBTest" + }, + "related-to": [ + { + "id": "848404488", + "relationship-label": "org.onap.relationships.inventory.ComposedOf", + "node-type": "generic-vnf", + "url": "/aai/v17/network/generic-vnfs/generic-vnf/test-gvnf2-360-as988q" + }, + { + "id": "890142720", + "relationship-label": "org.onap.relationships.inventory.ComposedOf", + "node-type": "generic-vnf", + "url": "/aai/v17/network/generic-vnfs/generic-vnf/test-gvnf1-360-as988q" + }, + { + "id": "439140528", + "relationship-label": "org.onap.relationships.inventory.BelongsTo", + "node-type": "service-subscription", + "url": "/aai/v17/business/customers/customer/globalCustomerId1-360-as988q/service-subscriptions/service-subscription/TEST1-360" + } + ] + }, + { + "id": "439132336", + "node-type": "model-ver", + "url": "/aai/v17/service-design-and-creation/models/model/modelInvariantValue2-360-as988q/model-vers/model-ver/modelVersionKey2-360-as988q", + "properties": { + "model-version-id": "modelVersionKey2-360-as988q", + "model-name": "vnfc8", + "model-version": "1.1", + "resource-version": "1563819746176" + }, + "related-to": [ { + "id": "908283976", + "relationship-label": "org.onap.relationships.inventory.BelongsTo", + "node-type": "model", + "url": "/aai/v17/service-design-and-creation/models/model/modelInvariantValue2-360-as988q" + }] + }, + { + "id": "908283976", + "node-type": "model", + "url": "/aai/v17/service-design-and-creation/models/model/modelInvariantValue2-360-as988q", + "properties": { + "model-invariant-id": "modelInvariantValue2-360-as988q", + "model-type": "widget3", + "resource-version": "1563819745871" + }, + "related-to": [ { + "id": "439132336", + "relationship-label": "org.onap.relationships.inventory.BelongsTo", + "node-type": "model-ver", + "url": "/aai/v17/service-design-and-creation/models/model/modelInvariantValue2-360-as988q/model-vers/model-ver/modelVersionKey2-360-as988q" + }] + }, + { + "id": "890142720", + "node-type": "generic-vnf", + "url": "/aai/v17/network/generic-vnfs/generic-vnf/test-gvnf1-360-as988q", + "properties": { + "vnf-id": "test-gvnf1-360-as988q", + "vnf-name": "test-name-gvnf-360", + "vnf-type": "SW", + "service-id": "d7bb0a21-66f2-4e6d-87d9-9ef3ced63ae4", + "equipment-role": "UCPE", + "orchestration-status": "created", + "ipv4-oam-address": "12.80.1.18", + "nm-lan-v6-address": "2001:1890:e00e:fffe::33c4", + "in-maint": false, + "is-closed-loop-disabled": false, + "resource-version": "1563819747496", + "model-invariant-id": "modelInvariantValue-360-as988q", + "model-version-id": "modelVersionKey-360-as988q", + "nf-role": "test360" + }, + "related-to": [ + { + "id": "1165906024", + "relationship-label": "org.onap.relationships.inventory.ComposedOf", + "node-type": "service-instance", + "url": "/aai/v17/business/customers/customer/globalCustomerId1-360-as988q/service-subscriptions/service-subscription/TEST1-360/service-instances/service-instance/serviceInstanceID1-360-as988q" + }, + { + "id": "848400392", + "relationship-label": "tosca.relationships.HostedOn", + "node-type": "vserver", + "url": "/aai/v17/cloud-infrastructure/cloud-regions/cloud-region/cloudOwnerKeyValue1-360-as988q/cloudRegionIdKeyValue1-360-as988q/tenants/tenant/tenantID1-360-as988q/vservers/vserver/vserver1-360-test-as988q" + } + ] + }, + { + "id": "1054167104", + "node-type": "model-ver", + "url": "/aai/v17/service-design-and-creation/models/model/modelInvariantValue-360-as988q/model-vers/model-ver/modelVersionKey-360-as988q", + "properties": { + "model-version-id": "modelVersionKey-360-as988q", + "model-name": "vnfc8", + "model-version": "1.1", + "resource-version": "1563819745556" + }, + "related-to": [ { + "id": "1054163008", + "relationship-label": "org.onap.relationships.inventory.BelongsTo", + "node-type": "model", + "url": "/aai/v17/service-design-and-creation/models/model/modelInvariantValue-360-as988q" + }] + }, + { + "id": "1054163008", + "node-type": "model", + "url": "/aai/v17/service-design-and-creation/models/model/modelInvariantValue-360-as988q", + "properties": { + "model-invariant-id": "modelInvariantValue-360-as988q", + "model-type": "service", + "resource-version": "1563819745252" + }, + "related-to": [ { + "id": "1054167104", + "relationship-label": "org.onap.relationships.inventory.BelongsTo", + "node-type": "model-ver", + "url": "/aai/v17/service-design-and-creation/models/model/modelInvariantValue-360-as988q/model-vers/model-ver/modelVersionKey-360-as988q" + }] + }, + { + "id": "521560160", + "node-type": "tenant", + "url": "/aai/v17/cloud-infrastructure/cloud-regions/cloud-region/cloudOwnerKeyValue1-360-as988q/cloudRegionIdKeyValue1-360-as988q/tenants/tenant/tenantID1-360-as988q", + "properties": { + "tenant-id": "tenantID1-360-as988q", + "tenant-name": "tenant-name1-360-as988q", + "resource-version": "1563819744626" + }, + "related-to": [ + { + "id": "848400392", + "relationship-label": "org.onap.relationships.inventory.BelongsTo", + "node-type": "vserver", + "url": "/aai/v17/cloud-infrastructure/cloud-regions/cloud-region/cloudOwnerKeyValue1-360-as988q/cloudRegionIdKeyValue1-360-as988q/tenants/tenant/tenantID1-360-as988q/vservers/vserver/vserver1-360-test-as988q" + }, + { + "id": "1165901928", + "relationship-label": "org.onap.relationships.inventory.BelongsTo", + "node-type": "cloud-region", + "url": "/aai/v17/cloud-infrastructure/cloud-regions/cloud-region/cloudOwnerKeyValue1-360-as988q/cloudRegionIdKeyValue1-360-as988q" + } + ] + }, + { + "id": "1165901928", + "node-type": "cloud-region", + "url": "/aai/v17/cloud-infrastructure/cloud-regions/cloud-region/cloudOwnerKeyValue1-360-as988q/cloudRegionIdKeyValue1-360-as988q", + "properties": { + "cloud-owner": "cloudOwnerKeyValue1-360-as988q", + "cloud-region-id": "cloudRegionIdKeyValue1-360-as988q", + "resource-version": "1563819744324", + "orchestration-disabled": false, + "in-maint": false + }, + "related-to": [ { + "id": "521560160", + "relationship-label": "org.onap.relationships.inventory.BelongsTo", + "node-type": "tenant", + "url": "/aai/v17/cloud-infrastructure/cloud-regions/cloud-region/cloudOwnerKeyValue1-360-as988q/cloudRegionIdKeyValue1-360-as988q/tenants/tenant/tenantID1-360-as988q" + }] + } +]} \ No newline at end of file diff --git a/vid-app-common/src/test/resources/payload_jsons/changeManagement/vnfs-fromServiceInstance-filterNfRole.json b/vid-app-common/src/test/resources/payload_jsons/changeManagement/vnfs-fromServiceInstance-filterNfRole.json new file mode 100644 index 000000000..6cbb7594f --- /dev/null +++ b/vid-app-common/src/test/resources/payload_jsons/changeManagement/vnfs-fromServiceInstance-filterNfRole.json @@ -0,0 +1,216 @@ +{ + "results": [ + { + "id": "908419144", + "node-type": "service-instance", + "url": "/aai/v17/business/customers/customer/globalCustomerId1-369-as988q/service-subscriptions/service-subscription/TEST1-369/service-instances/service-instance/serviceInstanceID1-369-as988q", + "properties": { + "service-instance-id": "serviceInstanceID1-369-as988q", + "service-instance-name": "EUd8Test", + "service-type": "xBoJHJbWTest", + "service-role": "sc7OWTest", + "environment-context": "O7OVp5Test", + "workload-context": "VmnxNeJIgWq7HTest", + "model-invariant-id": "modelInvariantValue2-369-as988q", + "model-version-id": "modelVersionKey2-369-as988q", + "widget-model-id": "HT7KA2FoRKH3cTest", + "widget-model-version": "CsGp5Test", + "bandwidth-total": "1Yijkk1Test", + "vhn-portal-url": "40PzTest", + "service-instance-location-id": "zcAaHJTAt5Hj8Test", + "resource-version": "1563820653329", + "selflink": "mZP2EVvwwHnlTest", + "orchestration-status": "6QvhzNgLudLBTest" + }, + "related-to": [ + { + "id": "439189680", + "relationship-label": "org.onap.relationships.inventory.ComposedOf", + "node-type": "generic-vnf", + "url": "/aai/v17/network/generic-vnfs/generic-vnf/test-gvnf2-369-as988q" + }, + { + "id": "1166020712", + "relationship-label": "org.onap.relationships.inventory.ComposedOf", + "node-type": "generic-vnf", + "url": "/aai/v17/network/generic-vnfs/generic-vnf/test-gvnf1-369-as988q" + }, + { + "id": "1166016616", + "relationship-label": "org.onap.relationships.inventory.BelongsTo", + "node-type": "service-subscription", + "url": "/aai/v17/business/customers/customer/globalCustomerId1-369-as988q/service-subscriptions/service-subscription/TEST1-369" + } + ] + }, + { + "id": "890175488", + "node-type": "model-ver", + "url": "/aai/v17/service-design-and-creation/models/model/modelInvariantValue2-369-as988q/model-vers/model-ver/modelVersionKey2-369-as988q", + "properties": { + "model-version-id": "modelVersionKey2-369-as988q", + "model-name": "vnfc8", + "model-version": "1.1", + "resource-version": "1563820653007" + }, + "related-to": [ { + "id": "908415048", + "relationship-label": "org.onap.relationships.inventory.BelongsTo", + "node-type": "model", + "url": "/aai/v17/service-design-and-creation/models/model/modelInvariantValue2-369-as988q" + }] + }, + { + "id": "908415048", + "node-type": "model", + "url": "/aai/v17/service-design-and-creation/models/model/modelInvariantValue2-369-as988q", + "properties": { + "model-invariant-id": "modelInvariantValue2-369-as988q", + "model-type": "widget3", + "resource-version": "1563820652703" + }, + "related-to": [ { + "id": "890175488", + "relationship-label": "org.onap.relationships.inventory.BelongsTo", + "node-type": "model-ver", + "url": "/aai/v17/service-design-and-creation/models/model/modelInvariantValue2-369-as988q/model-vers/model-ver/modelVersionKey2-369-as988q" + }] + }, + { + "id": "439189680", + "node-type": "generic-vnf", + "url": "/aai/v17/network/generic-vnfs/generic-vnf/test-gvnf2-369-as988q", + "properties": { + "vnf-id": "test-gvnf2-369-as988q", + "vnf-name": "test-name2-gvnf-369", + "vnf-type": "SW", + "service-id": "d7bb0a21-66f2-4e6d-87d9-9ef3ced63ae4", + "equipment-role": "UCPE", + "orchestration-status": "created", + "ipv4-oam-address": "12.80.1.18", + "nm-lan-v6-address": "2001:1890:e00e:fffe::33c4", + "in-maint": false, + "is-closed-loop-disabled": false, + "resource-version": "1563820654611", + "model-invariant-id": "modelInvariantValue-369-as988q", + "model-version-id": "modelVersionKey-369-as988q", + "nf-role": "test360" + }, + "related-to": [ { + "id": "908419144", + "relationship-label": "org.onap.relationships.inventory.ComposedOf", + "node-type": "service-instance", + "url": "/aai/v17/business/customers/customer/globalCustomerId1-369-as988q/service-subscriptions/service-subscription/TEST1-369/service-instances/service-instance/serviceInstanceID1-369-as988q" + }] + }, + { + "id": "1166012520", + "node-type": "model-ver", + "url": "/aai/v17/service-design-and-creation/models/model/modelInvariantValue-369-as988q/model-vers/model-ver/modelVersionKey-369-as988q", + "properties": { + "model-version-id": "modelVersionKey-369-as988q", + "model-name": "vnfc8", + "model-version": "1.1", + "resource-version": "1563820652380" + }, + "related-to": [ { + "id": "1166008424", + "relationship-label": "org.onap.relationships.inventory.BelongsTo", + "node-type": "model", + "url": "/aai/v17/service-design-and-creation/models/model/modelInvariantValue-369-as988q" + }] + }, + { + "id": "1166008424", + "node-type": "model", + "url": "/aai/v17/service-design-and-creation/models/model/modelInvariantValue-369-as988q", + "properties": { + "model-invariant-id": "modelInvariantValue-369-as988q", + "model-type": "service", + "resource-version": "1563820652072" + }, + "related-to": [ { + "id": "1166012520", + "relationship-label": "org.onap.relationships.inventory.BelongsTo", + "node-type": "model-ver", + "url": "/aai/v17/service-design-and-creation/models/model/modelInvariantValue-369-as988q/model-vers/model-ver/modelVersionKey-369-as988q" + }] + }, + { + "id": "1166020712", + "node-type": "generic-vnf", + "url": "/aai/v17/network/generic-vnfs/generic-vnf/test-gvnf1-369-as988q", + "properties": { + "vnf-id": "test-gvnf1-369-as988q", + "vnf-name": "test-name-gvnf-369", + "vnf-type": "SW", + "service-id": "d7bb0a21-66f2-4e6d-87d9-9ef3ced63ae4", + "equipment-role": "UCPE", + "orchestration-status": "created", + "ipv4-oam-address": "12.80.1.18", + "nm-lan-v6-address": "2001:1890:e00e:fffe::33c4", + "in-maint": false, + "is-closed-loop-disabled": false, + "resource-version": "1563820654296", + "model-invariant-id": "modelInvariantValue-369-as988q", + "model-version-id": "modelVersionKey-369-as988q", + "nf-role": "test360" + }, + "related-to": [ + { + "id": "908419144", + "relationship-label": "org.onap.relationships.inventory.ComposedOf", + "node-type": "service-instance", + "url": "/aai/v17/business/customers/customer/globalCustomerId1-369-as988q/service-subscriptions/service-subscription/TEST1-369/service-instances/service-instance/serviceInstanceID1-369-as988q" + }, + { + "id": "848445448", + "relationship-label": "tosca.relationships.HostedOn", + "node-type": "vserver", + "url": "/aai/v17/cloud-infrastructure/cloud-regions/cloud-region/cloudOwnerKeyValue1-369-as988q/cloudRegionIdKeyValue1-369-as988q/tenants/tenant/tenantID1-369-as988q/vservers/vserver/vserver1-369-test-as988q" + } + ] + }, + { + "id": "908410952", + "node-type": "tenant", + "url": "/aai/v17/cloud-infrastructure/cloud-regions/cloud-region/cloudOwnerKeyValue1-369-as988q/cloudRegionIdKeyValue1-369-as988q/tenants/tenant/tenantID1-369-as988q", + "properties": { + "tenant-id": "tenantID1-369-as988q", + "tenant-name": "tenant-name1-369-as988q", + "resource-version": "1563820651384" + }, + "related-to": [ + { + "id": "848445448", + "relationship-label": "org.onap.relationships.inventory.BelongsTo", + "node-type": "vserver", + "url": "/aai/v17/cloud-infrastructure/cloud-regions/cloud-region/cloudOwnerKeyValue1-369-as988q/cloudRegionIdKeyValue1-369-as988q/tenants/tenant/tenantID1-369-as988q/vservers/vserver/vserver1-369-test-as988q" + }, + { + "id": "1166004328", + "relationship-label": "org.onap.relationships.inventory.BelongsTo", + "node-type": "cloud-region", + "url": "/aai/v17/cloud-infrastructure/cloud-regions/cloud-region/cloudOwnerKeyValue1-369-as988q/cloudRegionIdKeyValue1-369-as988q" + } + ] + }, + { + "id": "1166004328", + "node-type": "cloud-region", + "url": "/aai/v17/cloud-infrastructure/cloud-regions/cloud-region/cloudOwnerKeyValue1-369-as988q/cloudRegionIdKeyValue1-369-as988q", + "properties": { + "cloud-owner": "cloudOwnerKeyValue1-369-as988q", + "cloud-region-id": "cloudRegionIdKeyValue1-369-as988q", + "resource-version": "1563820651058", + "orchestration-disabled": false, + "in-maint": false + }, + "related-to": [ { + "id": "908410952", + "relationship-label": "org.onap.relationships.inventory.BelongsTo", + "node-type": "tenant", + "url": "/aai/v17/cloud-infrastructure/cloud-regions/cloud-region/cloudOwnerKeyValue1-369-as988q/cloudRegionIdKeyValue1-369-as988q/tenants/tenant/tenantID1-369-as988q" + }] + } +]} \ No newline at end of file -- cgit 1.2.3-korg