From fdeaf8b56c8d342ef8145aae15c87525fe105f2a Mon Sep 17 00:00:00 2001 From: "Chayal, Avteet (ac229e)" Date: Thu, 19 Mar 2020 03:13:27 -0400 Subject: OSDF migration to new Policy API Map policy type with constraints type for HAS payload Added new attribute policies for Network Sliciing reference Fixed the logic to proccess Attribute policy translation Issue-ID: OPTFRA-721 Change-Id: I6b01815963b48b3df97c1a3109cc39b2a8bc2c3c Signed-off-by: Chayal, Avteet (ac229e) --- test/policy-local-files/Attribute_vNS_1.json | 49 +++++++++++++++++++++ .../new_policies/Attribute_vNS_1.json | 51 ++++++++++++++++++++++ .../new_policies/meta-valid-policies.txt | 1 + 3 files changed, 101 insertions(+) create mode 100644 test/policy-local-files/Attribute_vNS_1.json create mode 100644 test/policy-local-files/new_policies/Attribute_vNS_1.json (limited to 'test/policy-local-files') diff --git a/test/policy-local-files/Attribute_vNS_1.json b/test/policy-local-files/Attribute_vNS_1.json new file mode 100644 index 0000000..e4766db --- /dev/null +++ b/test/policy-local-files/Attribute_vNS_1.json @@ -0,0 +1,49 @@ +{ + "service": "attributePolicy", + "policyName": "OSDF_FRANKFURT.AttributePolicy_vNS_1", + "description": "Attribute Policy for Network Slicing (NS)", + "templateVersion": "OpenSource.version.1", + "version": "OpenSource.version.1", + "priority": "1", + "riskType": "test", + "riskLevel": "3", + "guard": "False", + "content": { + "identity": "attribute-vNS", + "policyScope": [ + "vNS", + "us", + "international", + "ip" + ], + "policyType": "attribute", + "resources": [ + "vNS", + "" + ], + "attributeProperties": { + "cloudRegion": { + "serviceRequests": [ + "", + "" + ], + "cloudRequests": [ + "", + "" + ] + }, + "networkRoles": { + "all": [ + "", + "" + ] + }, + "complex": { + "any": [ + "", + "" + ] + } + } + } +} \ No newline at end of file diff --git a/test/policy-local-files/new_policies/Attribute_vNS_1.json b/test/policy-local-files/new_policies/Attribute_vNS_1.json new file mode 100644 index 0000000..35b3c74 --- /dev/null +++ b/test/policy-local-files/new_policies/Attribute_vNS_1.json @@ -0,0 +1,51 @@ +{ + "OSDF_FRANKFURT.Attribute_vNS_1": { + "type": "onap.policies.optimization.AttributePolicy", + "version": "1.0.0", + "type_version": "1.0.0", + "metadata": { + "policy-id": "OSDF_FRANKFURT.Attribute_vNS_1", + "policy-version": 1 + }, + "properties": { + "scope": [ + "OSDF_FRANKFURT" + ], + "services": [ + "vNS" + ], + "resources": [ + "vNS" + ], + "geography": [ + "US", + "INTERNATIONAL" + ], + "identity": "attribute-vNS", + "attributeProperties": { + "cloudRegion": { + "serviceRequests": [ + "", + "" + ], + "cloudRequests": [ + "", + "" + ] + }, + "networkRoles": { + "all": [ + "", + "" + ] + }, + "complex": { + "any": [ + "", + "" + ] + } + } + } + } +} \ No newline at end of file diff --git a/test/policy-local-files/new_policies/meta-valid-policies.txt b/test/policy-local-files/new_policies/meta-valid-policies.txt index 7f5a007..5f969bf 100644 --- a/test/policy-local-files/new_policies/meta-valid-policies.txt +++ b/test/policy-local-files/new_policies/meta-valid-policies.txt @@ -14,3 +14,4 @@ QueryPolicy_vFW_TD.json vnfPolicy_vFW_TD.json vnfPolicy_vPGN_TD.json Affinity_vFW_TD.json +Attribute_vNS_1.json \ No newline at end of file -- cgit 1.2.3-korg