diff options
author | Hengye <yehui.wang@est.tech> | 2019-03-25 14:32:21 +0000 |
---|---|---|
committer | Hengye <yehui.wang@est.tech> | 2019-03-25 14:32:21 +0000 |
commit | b150aa8197e8a21ab7ad4cf1d91cfa30f56fa3df (patch) | |
tree | 60c296267f496f3b40d838294e8f80b04ceb2607 /models-interactions/model-impl/aai/src/test/resources | |
parent | 2a245ef80e39a101015efb164de53f1753fa5d47 (diff) |
migrate model-impl from drools-applications
migrate controlloop/common/model-impl from drools-applicaitons to
policy/models
Issue-ID: POLICY-1264
Change-Id: Ibe0bb5c49a7b1344f4104b30455f52834041e187
Signed-off-by: Hengye <yehui.wang@est.tech>
Diffstat (limited to 'models-interactions/model-impl/aai/src/test/resources')
12 files changed, 917 insertions, 0 deletions
diff --git a/models-interactions/model-impl/aai/src/test/resources/org/onap/policy/aai/AaiGetResponseError.json b/models-interactions/model-impl/aai/src/test/resources/org/onap/policy/aai/AaiGetResponseError.json new file mode 100644 index 000000000..6751fef5c --- /dev/null +++ b/models-interactions/model-impl/aai/src/test/resources/org/onap/policy/aai/AaiGetResponseError.json @@ -0,0 +1,14 @@ +{ + "requestError": { + "serviceException": { + "messageId": "SVC3001", + "text": "Resource not found for %1 using id %2 (msg=%3) (ec=%4)", + "variables": [ + "GET", + "network/generic-vnfs/generic-vnf/3f02-f878-436b-870c-f0e91e81570d", + "Node Not Found:No Node of type generic-vnf found at: network/generic-vnfs/generic-vnf/3f02-f878-436b-870c-f0e91e81570d", + "ERR.5.4.6114" + ] + } + } +} diff --git a/models-interactions/model-impl/aai/src/test/resources/org/onap/policy/aai/AaiGetVnfResponse.json b/models-interactions/model-impl/aai/src/test/resources/org/onap/policy/aai/AaiGetVnfResponse.json new file mode 100644 index 000000000..faa0e0e1b --- /dev/null +++ b/models-interactions/model-impl/aai/src/test/resources/org/onap/policy/aai/AaiGetVnfResponse.json @@ -0,0 +1,123 @@ +{ + "in-maint": false, + "ipv4-oam-address": "10.0.150.1", + "is-closed-loop-disabled": true, + "model-customization-id": "6c1a5439-3b77-4d8a-bb2b-9fe7006ad671", + "model-invariant-id": "53638a85-361a-437d-8830-4b0d5329225e", + "model-version-id": "a82cd55f-1452-4c36-941a-c9f970a3e67c", + "nf-function": "", + "nf-naming-code": "", + "nf-role": "vLB", + "nf-type": "", + "orchestration-status": "Active", + "prov-status": "PROV", + "relationship-list": { + "relationship": [ + { + "related-link": "/aai/v11/business/customers/customer/Demonstration/service-subscriptions/service-subscription/vLB/service-instances/service-instance/b66d24cc-feca-4fdc-8090-2e9539a8bbac", + "related-to": "service-instance", + "related-to-property": [ + { + "property-key": "service-instance.service-instance-name", + "property-value": "vLoadBalancerMS-Service-0809-1" + } + ], + "relationship-data": [ + { + "relationship-key": "customer.global-customer-id", + "relationship-value": "Demonstration" + }, + { + "relationship-key": "service-subscription.service-type", + "relationship-value": "vLB" + }, + { + "relationship-key": "service-instance.service-instance-id", + "relationship-value": "b66d24cc-feca-4fdc-8090-2e9539a8bbac" + } + ] + }, + { + "related-link": "/aai/v11/business/lines-of-business/line-of-business/Test-Business", + "related-to": "line-of-business", + "relationship-data": [ + { + "relationship-key": "line-of-business.line-of-business-name", + "relationship-value": "Test-Business" + } + ] + }, + { + "related-link": "/aai/v11/business/platforms/platform/Test-Platform", + "related-to": "platform", + "relationship-data": [ + { + "relationship-key": "platform.platform-name", + "relationship-value": "Test-Platform" + } + ] + }, + { + "related-link": "/aai/v11/cloud-infrastructure/cloud-regions/cloud-region/CloudOwner/RegionOne/tenants/tenant/4086f396c5e04caf9502c5fdeca575c4/vservers/vserver/191729bd-cb1d-485d-aa06-b20c888272a8", + "related-to": "vserver", + "related-to-property": [ + { + "property-key": "vserver.vserver-name", + "property-value": "vdns-ms01-0809-1" + } + ], + "relationship-data": [ + { + "relationship-key": "cloud-region.cloud-owner", + "relationship-value": "CloudOwner" + }, + { + "relationship-key": "cloud-region.cloud-region-id", + "relationship-value": "RegionOne" + }, + { + "relationship-key": "tenant.tenant-id", + "relationship-value": "4086f396c5e04caf9502c5fdeca575c4" + }, + { + "relationship-key": "vserver.vserver-id", + "relationship-value": "191729bd-cb1d-485d-aa06-b20c888272a8" + } + ] + }, + { + "related-link": "/aai/v11/cloud-infrastructure/cloud-regions/cloud-region/CloudOwner/RegionOne/tenants/tenant/4086f396c5e04caf9502c5fdeca575c4/vservers/vserver/1c94da3f-16f1-4fc7-9ed1-e018dfa62774", + "related-to": "vserver", + "related-to-property": [ + { + "property-key": "vserver.vserver-name", + "property-value": "vlb-ms-0809-1" + } + ], + "relationship-data": [ + { + "relationship-key": "cloud-region.cloud-owner", + "relationship-value": "CloudOwner" + }, + { + "relationship-key": "cloud-region.cloud-region-id", + "relationship-value": "RegionOne" + }, + { + "relationship-key": "tenant.tenant-id", + "relationship-value": "4086f396c5e04caf9502c5fdeca575c4" + }, + { + "relationship-key": "vserver.vserver-id", + "relationship-value": "1c94da3f-16f1-4fc7-9ed1-e018dfa62774" + } + ] + } + ] + }, + "resource-version": "1533850960381", + "service-id": "50e1b0be-e0c9-48e2-9f42-15279a783ee8", + "vnf-id": "807a3f02-f878-436b-870c-f0e91e81570d", + "vnf-name": "vLoadBalancerMS-Vnf-0809-2", + "vnf-type": "vLoadBalancerMS/vLoadBalancerMS 0" +} diff --git a/models-interactions/model-impl/aai/src/test/resources/org/onap/policy/aai/AaiGetVserverResponse.json b/models-interactions/model-impl/aai/src/test/resources/org/onap/policy/aai/AaiGetVserverResponse.json new file mode 100644 index 000000000..19885942e --- /dev/null +++ b/models-interactions/model-impl/aai/src/test/resources/org/onap/policy/aai/AaiGetVserverResponse.json @@ -0,0 +1,82 @@ +{ + "vserver": [ + { + "in-maint": false, + "is-closed-loop-disabled": true, + "prov-status": "ACTIVE", + "relationship-list": { + "relationship": [ + { + "related-link": "/aai/v11/network/generic-vnfs/generic-vnf/807a3f02-f878-436b-870c-f0e91e81570d", + "related-to": "generic-vnf", + "related-to-property": [ + { + "property-key": "generic-vnf.vnf-name", + "property-value": "vLoadBalancerMS-Vnf-0809-2" + } + ], + "relationship-data": [ + { + "relationship-key": "generic-vnf.vnf-id", + "relationship-value": "807a3f02-f878-436b-870c-f0e91e81570d" + } + ] + }, + { + "related-link": "/aai/v11/cloud-infrastructure/cloud-regions/cloud-region/CloudOwner/RegionOne/images/image/6e219e86-cd94-4989-9119-def29aa10b12", + "related-to": "image", + "related-to-property": [ + { + "property-key": "image.image-name", + "property-value": "unknown" + } + ], + "relationship-data": [ + { + "relationship-key": "cloud-region.cloud-owner", + "relationship-value": "CloudOwner" + }, + { + "relationship-key": "cloud-region.cloud-region-id", + "relationship-value": "RegionOne" + }, + { + "relationship-key": "image.image-id", + "relationship-value": "6e219e86-cd94-4989-9119-def29aa10b12" + } + ] + }, + { + "related-link": "/aai/v11/cloud-infrastructure/cloud-regions/cloud-region/CloudOwner/RegionOne/flavors/flavor/764efb04-5a46-4806-a766-2bdd24559f39", + "related-to": "flavor", + "related-to-property": [ + { + "property-key": "flavor.flavor-name", + "property-value": "m1.medium" + } + ], + "relationship-data": [ + { + "relationship-key": "cloud-region.cloud-owner", + "relationship-value": "CloudOwner" + }, + { + "relationship-key": "cloud-region.cloud-region-id", + "relationship-value": "RegionOne" + }, + { + "relationship-key": "flavor.flavor-id", + "relationship-value": "764efb04-5a46-4806-a766-2bdd24559f39" + } + ] + } + ] + }, + "resource-version": "1533850964910", + "vserver-id": "1c94da3f-16f1-4fc7-9ed1-e018dfa62774", + "vserver-name": "vlb-ms-0809-1", + "vserver-name2": "vlb-ms-0809-7", + "vserver-selflink": "http://localhost:8774/v2.1/4086f396c5e04caf9502c5fdeca575c4/servers/1c94da3f-16f1-4fc7-9ed1-e018dfa62774" + } + ] +} diff --git a/models-interactions/model-impl/aai/src/test/resources/org/onap/policy/aai/AaiNqResponseWrapper-NoItems.json b/models-interactions/model-impl/aai/src/test/resources/org/onap/policy/aai/AaiNqResponseWrapper-NoItems.json new file mode 100644 index 000000000..996692402 --- /dev/null +++ b/models-interactions/model-impl/aai/src/test/resources/org/onap/policy/aai/AaiNqResponseWrapper-NoItems.json @@ -0,0 +1,96 @@ +{ + "inventory-response-item": [ + { + "extra-properties": {}, + "inventory-response-items": { + "inventory-response-item": [ + { + "extra-properties": { + "extra-property": [ + { + "property-name": "model-ver.model-version-id", + "property-value": "a82cd55f-1452-4c36-941a-c9f970a3e67c" + }, + { + "property-name": "model-ver.model-name", + "property-value": "vLoadBalancerMS" + }, + { + "property-name": "model.model-type", + "property-value": "resource" + }, + { + "property-name": "model.model-invariant-id", + "property-value": "53638a85-361a-437d-8830-4b0d5329225e" + }, + { + "property-name": "model-ver.model-version", + "property-value": "1.0" + } + ] + }, + "generic-vnf": { + "in-maint": false, + "ipv4-oam-address": "10.0.150.1", + "is-closed-loop-disabled": false, + "model-customization-id": "6c1a5439-3b77-4d8a-bb2b-9fe7006ad671", + "model-invariant-id": "53638a85-361a-437d-8830-4b0d5329225e", + "model-version-id": "a82cd55f-1452-4c36-941a-c9f970a3e67c", + "nf-function": "", + "nf-naming-code": "", + "nf-role": "vLB", + "nf-type": "", + "orchestration-status": "Active", + "prov-status": "PROV", + "resource-version": "1533850960381", + "service-id": "50e1b0be-e0c9-48e2-9f42-15279a783ee8", + "vnf-id": "807a3f02-f878-436b-870c-f0e91e81570d", + "vnf-name": "vLoadBalancerMS-Vnf-0809-2", + "vnf-type": "vLoadBalancerMS/vLoadBalancerMS 0" + }, + "inventory-response-items": { + "inventory-response-item": [ + ] + }, + "model-name": "vLoadBalancerMS" + }, + { + "extra-properties": {}, + "inventory-response-items": { + "inventory-response-item": [ + { + "cloud-region": { + "cloud-owner": "CloudOwner", + "cloud-region-id": "RegionOne", + "cloud-region-version": "v2.5", + "cloud-type": "openstack", + "cloud-zone": "zone-1", + "owner-defined-type": "owner type", + "resource-version": "1533652058185", + "sriov-automation": false + }, + "extra-properties": {} + } + ] + }, + "tenant": { + "resource-version": "1533652058206", + "tenant-id": "4086f396c5e04caf9502c5fdeca575c4", + "tenant-name": "PFPP" + } + } + ] + }, + "vserver": { + "in-maint": false, + "is-closed-loop-disabled": false, + "prov-status": "ACTIVE", + "resource-version": "1533850964910", + "vserver-id": "1c94da3f-16f1-4fc7-9ed1-e018dfa62774", + "vserver-name": "vlb-ms-0809-1", + "vserver-name2": "vlb-ms-0809-1", + "vserver-selflink": "http://10.12.25.2:8774/v2.1/4086f396c5e04caf9502c5fdeca575c4/servers/1c94da3f-16f1-4fc7-9ed1-e018dfa62774" + } + } + ] +} diff --git a/models-interactions/model-impl/aai/src/test/resources/org/onap/policy/aai/AaiNqResponseWrapper-NoModules.json b/models-interactions/model-impl/aai/src/test/resources/org/onap/policy/aai/AaiNqResponseWrapper-NoModules.json new file mode 100644 index 000000000..2dd6090c7 --- /dev/null +++ b/models-interactions/model-impl/aai/src/test/resources/org/onap/policy/aai/AaiNqResponseWrapper-NoModules.json @@ -0,0 +1,133 @@ +{ + "inventory-response-item": [ + { + "extra-properties": {}, + "inventory-response-items": { + "inventory-response-item": [ + { + "extra-properties": { + "extra-property": [ + { + "property-name": "model-ver.model-version-id", + "property-value": "a82cd55f-1452-4c36-941a-c9f970a3e67c" + }, + { + "property-name": "model-ver.model-name", + "property-value": "vLoadBalancerMS" + }, + { + "property-name": "model.model-type", + "property-value": "resource" + }, + { + "property-name": "model.model-invariant-id", + "property-value": "53638a85-361a-437d-8830-4b0d5329225e" + }, + { + "property-name": "model-ver.model-version", + "property-value": "1.0" + } + ] + }, + "generic-vnf": { + "in-maint": false, + "ipv4-oam-address": "10.0.150.1", + "is-closed-loop-disabled": false, + "model-customization-id": "6c1a5439-3b77-4d8a-bb2b-9fe7006ad671", + "model-invariant-id": "53638a85-361a-437d-8830-4b0d5329225e", + "model-version-id": "a82cd55f-1452-4c36-941a-c9f970a3e67c", + "nf-function": "", + "nf-naming-code": "", + "nf-role": "vLB", + "nf-type": "", + "orchestration-status": "Active", + "prov-status": "PROV", + "resource-version": "1533850960381", + "service-id": "50e1b0be-e0c9-48e2-9f42-15279a783ee8", + "vnf-id": "807a3f02-f878-436b-870c-f0e91e81570d", + "vnf-name": "vLoadBalancerMS-Vnf-0809-2", + "vnf-type": "vLoadBalancerMS/vLoadBalancerMS 0" + }, + "inventory-response-items": { + "inventory-response-item": [ + { + "extra-properties": { + "extra-property": [ + { + "property-name": "model-ver.model-version-id", + "property-value": "4feb459d-d8ef-4cde-a714-235c79787962" + }, + { + "property-name": "model-ver.model-name", + "property-value": "vLoadBalancerMS" + }, + { + "property-name": "model.model-type", + "property-value": "service" + }, + { + "property-name": "model.model-invariant-id", + "property-value": "b5477216-9b7d-4e75-8777-5b632d406759" + }, + { + "property-name": "model-ver.model-version", + "property-value": "1.0" + } + ] + }, + "model-name": "vLoadBalancerMS", + "service-instance": { + "environment-context": "General_Revenue-Bearing", + "model-invariant-id": "b5477216-9b7d-4e75-8777-5b632d406759", + "model-version-id": "4feb459d-d8ef-4cde-a714-235c79787962", + "orchestration-status": "Active", + "resource-version": "1533848425145", + "service-instance-id": "b66d24cc-feca-4fdc-8090-2e9539a8bbac", + "service-instance-name": "vLoadBalancerMS-Service-0809-1", + "workload-context": "Production" + } + } + ] + }, + "model-name": "vLoadBalancerMS" + }, + { + "extra-properties": {}, + "inventory-response-items": { + "inventory-response-item": [ + { + "cloud-region": { + "cloud-owner": "CloudOwner", + "cloud-region-id": "RegionOne", + "cloud-region-version": "v2.5", + "cloud-type": "openstack", + "cloud-zone": "zone-1", + "owner-defined-type": "owner type", + "resource-version": "1533652058185", + "sriov-automation": false + }, + "extra-properties": {} + } + ] + }, + "tenant": { + "resource-version": "1533652058206", + "tenant-id": "4086f396c5e04caf9502c5fdeca575c4", + "tenant-name": "PFPP" + } + } + ] + }, + "vserver": { + "in-maint": false, + "is-closed-loop-disabled": false, + "prov-status": "ACTIVE", + "resource-version": "1533850964910", + "vserver-id": "1c94da3f-16f1-4fc7-9ed1-e018dfa62774", + "vserver-name": "vlb-ms-0809-1", + "vserver-name2": "vlb-ms-0809-1", + "vserver-selflink": "http://10.12.25.2:8774/v2.1/4086f396c5e04caf9502c5fdeca575c4/servers/1c94da3f-16f1-4fc7-9ed1-e018dfa62774" + } + } + ] +} diff --git a/models-interactions/model-impl/aai/src/test/resources/org/onap/policy/aai/AaiNqResponseWrapper-NoNames.json b/models-interactions/model-impl/aai/src/test/resources/org/onap/policy/aai/AaiNqResponseWrapper-NoNames.json new file mode 100644 index 000000000..9c1a9bc5d --- /dev/null +++ b/models-interactions/model-impl/aai/src/test/resources/org/onap/policy/aai/AaiNqResponseWrapper-NoNames.json @@ -0,0 +1,133 @@ +{ + "inventory-response-item": [ + { + "extra-properties": {}, + "inventory-response-items": { + "inventory-response-item": [ + { + "extra-properties": { + "extra-property": [ + { + "property-name": "model-ver.model-version-id", + "property-value": "a82cd55f-1452-4c36-941a-c9f970a3e67c" + }, + { + "property-name": "model-ver.model-name", + "property-value": "vLoadBalancerMS" + }, + { + "property-name": "model.model-type", + "property-value": "resource" + }, + { + "property-name": "model.model-invariant-id", + "property-value": "53638a85-361a-437d-8830-4b0d5329225e" + }, + { + "property-name": "model-ver.model-version", + "property-value": "1.0" + } + ] + }, + "generic-vnf": { + "in-maint": false, + "ipv4-oam-address": "10.0.150.1", + "is-closed-loop-disabled": false, + "model-customization-id": "6c1a5439-3b77-4d8a-bb2b-9fe7006ad671", + "model-invariant-id": "53638a85-361a-437d-8830-4b0d5329225e", + "model-version-id": "a82cd55f-1452-4c36-941a-c9f970a3e67c", + "nf-function": "", + "nf-naming-code": "", + "nf-role": "vLB", + "nf-type": "", + "orchestration-status": "Active", + "prov-status": "PROV", + "resource-version": "1533850960381", + "service-id": "50e1b0be-e0c9-48e2-9f42-15279a783ee8", + "vnf-id": "807a3f02-f878-436b-870c-f0e91e81570d", + "vnf-name": "vLoadBalancerMS-Vnf-0809-2", + "vnf-type": "vLoadBalancerMS/vLoadBalancerMS 0" + }, + "inventory-response-items": { + "inventory-response-item": [ + { + "model-name": "vLoadBalancerMS", + "service-instance": { + "environment-context": "General_Revenue-Bearing", + "model-invariant-id": "b5477216-9b7d-4e75-8777-5b632d406759", + "model-version-id": "4feb459d-d8ef-4cde-a714-235c79787962", + "orchestration-status": "Active", + "resource-version": "1533848425145", + "service-instance-id": "b66d24cc-feca-4fdc-8090-2e9539a8bbac", + "service-instance-name": "vLoadBalancerMS-Service-0809-1", + "workload-context": "Production" + } + }, + { + "vf-module": { + "is-base-vf-module": false, + "model-invariant-id": "6d01b7f1-769a-4080-b8ea-57fd03ef1572", + "model-version-id": "3302088a-457e-496c-9282-2eb3d5b8dd24", + "resource-version": "1534270663202", + "vf-module-id": "dummy_807a3f02-f878-436b-870c-f0e91e81570d", + "vf-module-name": "dummy_807a3f02-f878-436b-870c-f0e91e81570d" + } + }, + { + "vf-module": { + "heat-stack-id": "Vfmodule_vLBMS-0809-1/83ab2394-2b22-40f9-8ba2-383698dd2958", + "is-base-vf-module": true, + "model-customization-id": "5198f732-8f22-48f9-98f8-d6b8b50118be", + "model-invariant-id": "1f566a81-58ba-4762-81f9-d2259509429a", + "model-version-id": "94827d25-4ac3-4850-abfc-7b6e3c531db4", + "module-index": 0, + "orchestration-status": "active", + "resource-version": "1533850416834", + "vf-module-id": "b861467d-d3a7-4b21-81b3-94d928a7e8b7", + "vf-module-name": "Vfmodule_vLBMS-0809-1" + } + } + ] + }, + "model-name": "vLoadBalancerMS" + }, + { + "extra-properties": {}, + "inventory-response-items": { + "inventory-response-item": [ + { + "cloud-region": { + "cloud-owner": "CloudOwner", + "cloud-region-id": "RegionOne", + "cloud-region-version": "v2.5", + "cloud-type": "openstack", + "cloud-zone": "zone-1", + "owner-defined-type": "owner type", + "resource-version": "1533652058185", + "sriov-automation": false + }, + "extra-properties": {} + } + ] + }, + "tenant": { + "resource-version": "1533652058206", + "tenant-id": "4086f396c5e04caf9502c5fdeca575c4", + "tenant-name": "PFPP" + } + } + ] + }, + "vserver": { + "in-maint": false, + "is-closed-loop-disabled": false, + "prov-status": "ACTIVE", + "resource-version": "1533850964910", + "vserver-id": "1c94da3f-16f1-4fc7-9ed1-e018dfa62774", + "vserver-name": "vlb-ms-0809-1", + "vserver-name2": "vlb-ms-0809-1", + "vserver-selflink": "http://10.12.25.2:8774/v2.1/4086f396c5e04caf9502c5fdeca575c4/servers/1c94da3f-16f1-4fc7-9ed1-e018dfa62774" + } + } + ] +} diff --git a/models-interactions/model-impl/aai/src/test/resources/org/onap/policy/aai/AaiNqResponseWrapper-Vserver.json b/models-interactions/model-impl/aai/src/test/resources/org/onap/policy/aai/AaiNqResponseWrapper-Vserver.json new file mode 100644 index 000000000..fb341dc65 --- /dev/null +++ b/models-interactions/model-impl/aai/src/test/resources/org/onap/policy/aai/AaiNqResponseWrapper-Vserver.json @@ -0,0 +1,157 @@ +{ + "inventory-response-item": [ + { + "extra-properties": {}, + "inventory-response-items": { + "inventory-response-item": [ + { + "extra-properties": { + "extra-property": [ + { + "property-name": "model-ver.model-version-id", + "property-value": "a82cd55f-1452-4c36-941a-c9f970a3e67c" + }, + { + "property-name": "model-ver.model-name", + "property-value": "vLoadBalancerMS" + }, + { + "property-name": "model.model-type", + "property-value": "resource" + }, + { + "property-name": "model.model-invariant-id", + "property-value": "53638a85-361a-437d-8830-4b0d5329225e" + }, + { + "property-name": "model-ver.model-version", + "property-value": "1.0" + } + ] + }, + "generic-vnf": { + "in-maint": false, + "ipv4-oam-address": "10.0.150.1", + "is-closed-loop-disabled": false, + "model-customization-id": "6c1a5439-3b77-4d8a-bb2b-9fe7006ad671", + "model-invariant-id": "53638a85-361a-437d-8830-4b0d5329225e", + "model-version-id": "a82cd55f-1452-4c36-941a-c9f970a3e67c", + "nf-function": "", + "nf-naming-code": "", + "nf-role": "vLB", + "nf-type": "", + "orchestration-status": "Active", + "prov-status": "PROV", + "resource-version": "1533850960381", + "service-id": "50e1b0be-e0c9-48e2-9f42-15279a783ee8", + "vnf-id": "807a3f02-f878-436b-870c-f0e91e81570d", + "vnf-name": "vLoadBalancerMS-Vnf-0809-2", + "vnf-type": "vLoadBalancerMS/vLoadBalancerMS 0" + }, + "inventory-response-items": { + "inventory-response-item": [ + { + "model-name": "vLoadBalancerMS", + "service-instance": { + "environment-context": "General_Revenue-Bearing", + "model-invariant-id": "b5477216-9b7d-4e75-8777-5b632d406759", + "model-version-id": "4feb459d-d8ef-4cde-a714-235c79787962", + "orchestration-status": "Active", + "resource-version": "1533848425145", + "service-instance-id": "b66d24cc-feca-4fdc-8090-2e9539a8bbac", + "service-instance-name": "vLoadBalancerMS-Service-0809-1", + "workload-context": "Production" + } + }, + { + "vf-module": { + "is-base-vf-module": false, + "model-invariant-id": "6d01b7f1-769a-4080-b8ea-57fd03ef1572", + "model-version-id": "3302088a-457e-496c-9282-2eb3d5b8dd24", + "resource-version": "1534270663202", + "vf-module-id": "dummy_807a3f02-f878-436b-870c-f0e91e81570d", + "vf-module-name": "dummy_807a3f02-f878-436b-870c-f0e91e81570d" + } + }, + { + "vf-module": { + "is-base-vf-module": false, + "vf-module-name": "my-module-abc_1" + } + }, + { + "vf-module": { + "heat-stack-id": "Vfmodule_vLBMS-0809-1/83ab2394-2b22-40f9-8ba2-383698dd2958", + "is-base-vf-module": true, + "model-customization-id": "5198f732-8f22-48f9-98f8-d6b8b50118be", + "model-invariant-id": "1f566a81-58ba-4762-81f9-d2259509429a", + "model-version-id": "94827d25-4ac3-4850-abfc-7b6e3c531db4", + "module-index": 0, + "orchestration-status": "active", + "resource-version": "1533850416834", + "vf-module-id": "b861467d-d3a7-4b21-81b3-94d928a7e8b7", + "vf-module-name": "Vfmodule_vLBMS-0809-1" + } + }, + { + "vf-module": { + "is-base-vf-module": false, + "vf-module-name": "my-module-abc_123" + } + }, + { + "vf-module": { + "is-base-vf-module": false, + "vf-module-name": "no-underscore-number-9999" + } + }, + { + "vf-module": { + "is-base-vf-module": false, + "vf-module-name": "my-module-abc_34" + } + } + ] + }, + "model-name": "vLoadBalancerMS" + }, + { + "extra-properties": {}, + "inventory-response-items": { + "inventory-response-item": [ + { + "cloud-region": { + "cloud-owner": "CloudOwner", + "cloud-region-id": "RegionOne", + "cloud-region-version": "v2.5", + "cloud-type": "openstack", + "cloud-zone": "zone-1", + "owner-defined-type": "owner type", + "resource-version": "1533652058185", + "sriov-automation": false + }, + "extra-properties": {} + } + ] + }, + "tenant": { + "resource-version": "1533652058206", + "tenant-id": "4086f396c5e04caf9502c5fdeca575c4", + "tenant-name": "PFPP" + } + } + ] + }, + "vserver": { + "in-maint": false, + "is-closed-loop-disabled": false, + "prov-status": "ACTIVE", + "resource-version": "1533850964910", + "vserver-id": "1c94da3f-16f1-4fc7-9ed1-e018dfa62774", + "vserver-name": "vlb-ms-0809-1", + "vserver-name2": "vlb-ms-0809-1", + "vserver-selflink": "http://10.12.25.2:8774/v2.1/4086f396c5e04caf9502c5fdeca575c4/servers/1c94da3f-16f1-4fc7-9ed1-e018dfa62774" + } + } + ] +} diff --git a/models-interactions/model-impl/aai/src/test/resources/org/onap/policy/aai/AaiNqVServer.json b/models-interactions/model-impl/aai/src/test/resources/org/onap/policy/aai/AaiNqVServer.json new file mode 100644 index 000000000..0a59d8a87 --- /dev/null +++ b/models-interactions/model-impl/aai/src/test/resources/org/onap/policy/aai/AaiNqVServer.json @@ -0,0 +1,78 @@ +{ + "in-maint": false, + "is-closed-loop-disabled": true, + "prov-status": "ACTIVE", + "relationship-list": { + "relationship": [ + { + "related-link": "/aai/v11/network/generic-vnfs/generic-vnf/807a3f02-f878-436b-870c-f0e91e81570d", + "related-to": "generic-vnf", + "related-to-property": [ + { + "property-key": "generic-vnf.vnf-name", + "property-value": "vLoadBalancerMS-Vnf-0809-2" + } + ], + "relationship-data": [ + { + "relationship-key": "generic-vnf.vnf-id", + "relationship-value": "807a3f02-f878-436b-870c-f0e91e81570d" + } + ] + }, + { + "related-link": "/aai/v11/cloud-infrastructure/cloud-regions/cloud-region/CloudOwner/RegionOne/images/image/6e219e86-cd94-4989-9119-def29aa10b12", + "related-to": "image", + "related-to-property": [ + { + "property-key": "image.image-name", + "property-value": "unknown" + } + ], + "relationship-data": [ + { + "relationship-key": "cloud-region.cloud-owner", + "relationship-value": "CloudOwner" + }, + { + "relationship-key": "cloud-region.cloud-region-id", + "relationship-value": "RegionOne" + }, + { + "relationship-key": "image.image-id", + "relationship-value": "6e219e86-cd94-4989-9119-def29aa10b12" + } + ] + }, + { + "related-link": "/aai/v11/cloud-infrastructure/cloud-regions/cloud-region/CloudOwner/RegionOne/flavors/flavor/764efb04-5a46-4806-a766-2bdd24559f39", + "related-to": "flavor", + "related-to-property": [ + { + "property-key": "flavor.flavor-name", + "property-value": "m1.medium" + } + ], + "relationship-data": [ + { + "relationship-key": "cloud-region.cloud-owner", + "relationship-value": "CloudOwner" + }, + { + "relationship-key": "cloud-region.cloud-region-id", + "relationship-value": "RegionOne" + }, + { + "relationship-key": "flavor.flavor-id", + "relationship-value": "764efb04-5a46-4806-a766-2bdd24559f39" + } + ] + } + ] + }, + "resource-version": "1533850964910", + "vserver-id": "1c94da3f-16f1-4fc7-9ed1-e018dfa62774", + "vserver-name": "vlb-ms-0809-1", + "vserver-name2": "vlb-ms-0809-7", + "vserver-selflink": "http://localhost:8774/v2.1/4086f396c5e04caf9502c5fdeca575c4/servers/1c94da3f-16f1-4fc7-9ed1-e018dfa62774" +} diff --git a/models-interactions/model-impl/aai/src/test/resources/org/onap/policy/aai/RelatedToProperty.json b/models-interactions/model-impl/aai/src/test/resources/org/onap/policy/aai/RelatedToProperty.json new file mode 100644 index 000000000..2211b3725 --- /dev/null +++ b/models-interactions/model-impl/aai/src/test/resources/org/onap/policy/aai/RelatedToProperty.json @@ -0,0 +1,4 @@ +{ + "property-key": "generic-vnf.vnf-name", + "property-value": "vLoadBalancerMS-Vnf-0809-1" +} diff --git a/models-interactions/model-impl/aai/src/test/resources/org/onap/policy/aai/Relationship.json b/models-interactions/model-impl/aai/src/test/resources/org/onap/policy/aai/Relationship.json new file mode 100644 index 000000000..39d9ce1b6 --- /dev/null +++ b/models-interactions/model-impl/aai/src/test/resources/org/onap/policy/aai/Relationship.json @@ -0,0 +1,25 @@ + +{ + "related-link": "/aai/v11/network/generic-vnfs/generic-vnf/807a3f02-f878-436b-870c-f0e91e81570d", + "related-to": "generic-vnf", + "related-to-property": [ + { + "property-key": "generic-vnf.vnf-name", + "property-value": "vLoadBalancerMS-Vnf-0809-1" + }, + { + "property-key": "generic-vnf.vnf-name", + "property-value": "vLoadBalancerMS-Vnf-0809-2" + } + ], + "relationship-data": [ + { + "relationship-key": "generic-vnf.vnf-id", + "relationship-value": "807a3f02-f878-436b-870c-f0e91e81570d" + }, + { + "relationship-key": "generic-vnf.vnf-id", + "relationship-value": "907a3f02-f878-436b-870c-f0e91e81570e" + } + ] +} diff --git a/models-interactions/model-impl/aai/src/test/resources/org/onap/policy/aai/RelationshipData.json b/models-interactions/model-impl/aai/src/test/resources/org/onap/policy/aai/RelationshipData.json new file mode 100644 index 000000000..4bbb39e8f --- /dev/null +++ b/models-interactions/model-impl/aai/src/test/resources/org/onap/policy/aai/RelationshipData.json @@ -0,0 +1,4 @@ +{ + "relationship-key": "generic-vnf.vnf-id", + "relationship-value": "807a3f02-f878-436b-870c-f0e91e81570d" +} diff --git a/models-interactions/model-impl/aai/src/test/resources/org/onap/policy/aai/RelationshipList.json b/models-interactions/model-impl/aai/src/test/resources/org/onap/policy/aai/RelationshipList.json new file mode 100644 index 000000000..ae180f056 --- /dev/null +++ b/models-interactions/model-impl/aai/src/test/resources/org/onap/policy/aai/RelationshipList.json @@ -0,0 +1,68 @@ +{ + "relationship": [ + { + "related-link": "/aai/v11/network/generic-vnfs/generic-vnf/807a3f02-f878-436b-870c-f0e91e81570d", + "related-to": "generic-vnf", + "related-to-property": [ + { + "property-key": "generic-vnf.vnf-name", + "property-value": "vLoadBalancerMS-Vnf-0809-2" + } + ], + "relationship-data": [ + { + "relationship-key": "generic-vnf.vnf-id", + "relationship-value": "807a3f02-f878-436b-870c-f0e91e81570d" + } + ] + }, + { + "related-link": "/aai/v11/cloud-infrastructure/cloud-regions/cloud-region/CloudOwner/RegionOne/images/image/6e219e86-cd94-4989-9119-def29aa10b12", + "related-to": "image", + "related-to-property": [ + { + "property-key": "image.image-name", + "property-value": "unknown" + } + ], + "relationship-data": [ + { + "relationship-key": "cloud-region.cloud-owner", + "relationship-value": "CloudOwner" + }, + { + "relationship-key": "cloud-region.cloud-region-id", + "relationship-value": "RegionOne" + }, + { + "relationship-key": "image.image-id", + "relationship-value": "6e219e86-cd94-4989-9119-def29aa10b12" + } + ] + }, + { + "related-link": "/aai/v11/cloud-infrastructure/cloud-regions/cloud-region/CloudOwner/RegionOne/flavors/flavor/764efb04-5a46-4806-a766-2bdd24559f39", + "related-to": "flavor", + "related-to-property": [ + { + "property-key": "flavor.flavor-name", + "property-value": "m1.medium" + } + ], + "relationship-data": [ + { + "relationship-key": "cloud-region.cloud-owner", + "relationship-value": "CloudOwner" + }, + { + "relationship-key": "cloud-region.cloud-region-id", + "relationship-value": "RegionOne" + }, + { + "relationship-key": "flavor.flavor-id", + "relationship-value": "764efb04-5a46-4806-a766-2bdd24559f39" + } + ] + } + ] +} |