diff options
Diffstat (limited to 'main/src/test/resources/policytypes')
10 files changed, 66 insertions, 287 deletions
diff --git a/main/src/test/resources/policytypes/onap.policies.Optimization.yaml b/main/src/test/resources/policytypes/onap.policies.Optimization.yaml new file mode 100644 index 00000000..62f2c6f2 --- /dev/null +++ b/main/src/test/resources/policytypes/onap.policies.Optimization.yaml @@ -0,0 +1,39 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +policy_types: + onap.policies.Optimization: + derived_from: tosca.policies.Root + version: 1.0.0 + description: The base policy type for all policies that govern optimization + properties: + scope: + description: Scope for the policy - could be for a specific release. + type: string + matchable: true + required: true + services: + description: One or more services that the policy applies to. + type: list + matchable: true + required: true + entry_schema: + type: string + resources: + description: One or more VNF resources that the policy applies to. + type: list + matchable: true + required: true + entry_schema: + type: string + geography: + description: One or more geographic regions + type: list + matchable: true + required: true + entry_schema: + type: string + constraints: + - valid_values: ["US", "International"] + identity: + description: Used internally for identification + type: string + required: true diff --git a/main/src/test/resources/policytypes/onap.policies.optimization.AffinityPolicy.yaml b/main/src/test/resources/policytypes/onap.policies.optimization.AffinityPolicy.yaml index 415e05e2..f0d47ed6 100644 --- a/main/src/test/resources/policytypes/onap.policies.optimization.AffinityPolicy.yaml +++ b/main/src/test/resources/policytypes/onap.policies.optimization.AffinityPolicy.yaml @@ -1,32 +1,8 @@ tosca_definitions_version: tosca_simple_yaml_1_0_0 policy_types: - - onap.policies.Optimization: - derived_from: tosca.policies.Root - version: 1.0.0 - description: a base policy type for all policies that govern optimization - - onap.policies.optimization.AffinityPolicy: + onap.policies.optimization.AffinityPolicy: derived_from: onap.policies.Optimization properties: - policyScope: - type: list - description: scope where the policy is applicable - required: true - matchable: true - entry_schema: - type: string - policyType: - type: list - description: type of a policy - required: true - matchable: true - entry_schema: - type: string - constraints: - - valid_values: - - zone - identity: - type: string - required: true applicableResources: type: list required: true @@ -39,25 +15,16 @@ policy_types: affinityProperties: type: policy.data.affinityProperties_properties required: true - resources: - type: list - required: true - entry_schema: - type: string data_types: - - policy.data.affinityProperties_properties: derived_from: tosca.nodes.Root properties: qualifier: - type: list - required: true - entry_schema: - type: string - constraints: - - valid_values: - - same - - different + type: string + constraints: + - valid_values: + - same + - different category: type: string required: true diff --git a/main/src/test/resources/policytypes/onap.policies.optimization.DistancePolicy.yaml b/main/src/test/resources/policytypes/onap.policies.optimization.DistancePolicy.yaml index a0571bc1..9bcdd7a6 100644 --- a/main/src/test/resources/policytypes/onap.policies.optimization.DistancePolicy.yaml +++ b/main/src/test/resources/policytypes/onap.policies.optimization.DistancePolicy.yaml @@ -1,37 +1,8 @@ tosca_definitions_version: tosca_simple_yaml_1_0_0 policy_types: - - onap.policies.Optimization: - derived_from: tosca.policies.Root - version: 1.0.0 - description: a base policy type for all policies that govern optimization - - onap.policies.optimization.DistancePolicy: + onap.policies.optimization.DistancePolicy: derived_from: onap.policies.Optimization properties: - policyScope: - type: list - description: scope where the policy is applicable - required: true - matchable: true - entry_schema: - type: string - policyType: - type: list - description: type of a policy - required: true - matchable: true - entry_schema: - type: string - constraints: - - valid_values: - - distance_to_location - identity: - type: string - required: true - resources: - type: list - required: true - entry_schema: - type: string applicableResources: type: list required: true @@ -45,7 +16,6 @@ policy_types: type: policy.data.distanceProperties_properties required: true data_types: - - policy.data.distanceProperties_properties: derived_from: tosca.nodes.Root properties: @@ -55,6 +25,8 @@ data_types: distance: type: policy.data.distance_properties required: true + entry_schema: + type: policy.data.distance_properties policy.data.distance_properties: derived_from: tosca.nodes.Root properties: @@ -70,9 +42,9 @@ data_types: - valid_values: - < - <= - - '>' - - '>=' - - '=' + - > + - >= + - = unit: type: list required: true diff --git a/main/src/test/resources/policytypes/onap.policies.optimization.HpaPolicy.yaml b/main/src/test/resources/policytypes/onap.policies.optimization.HpaPolicy.yaml index e9e5436f..21a2e722 100644 --- a/main/src/test/resources/policytypes/onap.policies.optimization.HpaPolicy.yaml +++ b/main/src/test/resources/policytypes/onap.policies.optimization.HpaPolicy.yaml @@ -1,44 +1,14 @@ tosca_definitions_version: tosca_simple_yaml_1_0_0 policy_types: - - onap.policies.Optimization: - derived_from: tosca.policies.Root - version: 1.0.0 - description: a base policy type for all policies that govern optimization - - onap.policies.optimization.HpaPolicy: + onap.policies.optimization.HpaPolicy: derived_from: onap.policies.Optimization properties: - policyScope: - type: list - description: scope where the policy is applicable - required: true - matchable: true - entry_schema: - type: string - policyType: - type: list - description: type of a policy - required: true - matchable: true - entry_schema: - type: string - constraints: - - valid_values: - - hpa - resources: - type: list - required: true - entry_schema: - type: string - identity: - type: string - required: true flavorFeatures: type: list required: true entry_schema: type: policy.data.flavorFeatures_properties data_types: - - policy.data.flavorFeatures_properties: derived_from: tosca.nodes.Root properties: @@ -58,7 +28,6 @@ data_types: required: true entry_schema: type: policy.data.flavorProperties_properties - - policy.data.directives_properties: derived_from: tosca.nodes.Root properties: @@ -68,7 +37,6 @@ data_types: type: list entry_schema: type: policy.data.directives_attributes_properties - - policy.data.directives_attributes_properties: derived_from: tosca.nodes.Root properties: @@ -76,7 +44,6 @@ data_types: type: string attribute_value: type: string - - policy.data.flavorProperties_properties: derived_from: tosca.nodes.Root properties: @@ -105,7 +72,6 @@ data_types: required: true entry_schema: type: policy.data.hpa-feature-attributes_properties - - policy.data.hpa-feature-attributes_properties: derived_from: tosca.nodes.Root properties: @@ -124,10 +90,10 @@ data_types: - valid_values: - < - <= - - '>' - - '>=' - - '=' - - '!=' + - > + - >= + - = + - != - any - all - subset diff --git a/main/src/test/resources/policytypes/onap.policies.optimization.OptimizationPolicy.yaml b/main/src/test/resources/policytypes/onap.policies.optimization.OptimizationPolicy.yaml index cccd0b50..76bc550d 100644 --- a/main/src/test/resources/policytypes/onap.policies.optimization.OptimizationPolicy.yaml +++ b/main/src/test/resources/policytypes/onap.policies.optimization.OptimizationPolicy.yaml @@ -1,32 +1,8 @@ tosca_definitions_version: tosca_simple_yaml_1_0_0 policy_types: - - onap.policies.Optimization: - derived_from: tosca.policies.Root - version: 1.0.0 - description: a base policy type for all policies that govern optimization - - onap.policies.optimization.OptimizationPolicy: + onap.policies.optimization.OptimizationPolicy: derived_from: onap.policies.Optimization properties: - policyScope: - type: list - description: scope where the policy is applicable - required: true - matchable: true - entry_schema: - type: string - policyType: - type: list - description: type of a policy - required: true - matchable: true - entry_schema: - type: string - constraints: - - valid_values: - - placement_optimization - identity: - type: string - required: true objective: type: list required: true @@ -40,7 +16,6 @@ policy_types: type: policy.data.objectiveParameter_properties required: true data_types: - - policy.data.objectiveParameter_properties: derived_from: tosca.nodes.Root properties: diff --git a/main/src/test/resources/policytypes/onap.policies.optimization.PciPolicy.yaml b/main/src/test/resources/policytypes/onap.policies.optimization.PciPolicy.yaml index 2cc6d418..81187964 100644 --- a/main/src/test/resources/policytypes/onap.policies.optimization.PciPolicy.yaml +++ b/main/src/test/resources/policytypes/onap.policies.optimization.PciPolicy.yaml @@ -1,44 +1,14 @@ tosca_definitions_version: tosca_simple_yaml_1_0_0 policy_types: - - onap.policies.Optimization: - derived_from: tosca.policies.Root - version: 1.0.0 - description: a base policy type for all policies that govern optimization - - onap.policies.optimization.PciPolicy: + onap.policies.optimization.PciPolicy: derived_from: onap.policies.Optimization properties: - policyScope: - type: list - description: scope where the policy is applicable - required: true - matchable: true - entry_schema: - type: string - policyType: - type: list - description: type of a policy - required: true - matchable: true - entry_schema: - type: string - constraints: - - valid_values: - - pciPolicy - identity: - type: string - required: true - resources: - type: list - required: true - entry_schema: - type: string pciProperties: type: list required: false entry_schema: type: policy.data.pciProperties_properties data_types: - - policy.data.pciProperties_properties: derived_from: tosca.nodes.Root properties: diff --git a/main/src/test/resources/policytypes/onap.policies.optimization.QueryPolicy.yaml b/main/src/test/resources/policytypes/onap.policies.optimization.QueryPolicy.yaml index 7c54a8d0..7f85c777 100644 --- a/main/src/test/resources/policytypes/onap.policies.optimization.QueryPolicy.yaml +++ b/main/src/test/resources/policytypes/onap.policies.optimization.QueryPolicy.yaml @@ -1,39 +1,14 @@ tosca_definitions_version: tosca_simple_yaml_1_0_0 policy_types: - - onap.policies.Optimization: - derived_from: tosca.policies.Root - version: 1.0.0 - description: a base policy type for all policies that govern optimization - - onap.policies.optimization.QueryPolicy: + onap.policies.optimization.QueryPolicy: derived_from: onap.policies.Optimization properties: - policyScope: - type: list - description: scope where the policy is applicable - required: true - matchable: true - entry_schema: - type: string - policyType: - type: list - description: type of a policy - required: true - matchable: true - entry_schema: - type: string - constraints: - - valid_values: - - request_param_query - identity: - type: string - required: true queryProperties: type: list required: true entry_schema: type: policy.data.queryProperties_properties data_types: - - policy.data.queryProperties_properties: derived_from: tosca.nodes.Root properties: diff --git a/main/src/test/resources/policytypes/onap.policies.optimization.SubscriberPolicy.yaml b/main/src/test/resources/policytypes/onap.policies.optimization.SubscriberPolicy.yaml index 294dcdf4..6b24fbc9 100644 --- a/main/src/test/resources/policytypes/onap.policies.optimization.SubscriberPolicy.yaml +++ b/main/src/test/resources/policytypes/onap.policies.optimization.SubscriberPolicy.yaml @@ -1,38 +1,13 @@ tosca_definitions_version: tosca_simple_yaml_1_0_0 policy_types: - - onap.policies.Optimization: - derived_from: tosca.policies.Root - version: 1.0.0 - description: a base policy type for all policies that govern optimization - - onap.policies.optimization.SubscriberPolicy: + onap.policies.optimization.SubscriberPolicy: derived_from: onap.policies.Optimization properties: - policyScope: - type: list - description: scope where the policy is applicable - required: true - matchable: true - entry_schema: - type: string - policyType: - type: list - description: type of a policy - required: true - matchable: true - entry_schema: - type: string - constraints: - - valid_values: - - subscriberPolicy - identity: - type: string - required: true - properties: - type: policy.data.properties_properties + subscriberProperties: + type: policy.data.subscriberProperties_properties required: true data_types: - - - policy.data.properties_properties: + policy.data.subscriberProperties_properties: derived_from: tosca.nodes.Root properties: subscriberName: diff --git a/main/src/test/resources/policytypes/onap.policies.optimization.Vim_fit.yaml b/main/src/test/resources/policytypes/onap.policies.optimization.Vim_fit.yaml index e4dc5009..2d35741a 100644 --- a/main/src/test/resources/policytypes/onap.policies.optimization.Vim_fit.yaml +++ b/main/src/test/resources/policytypes/onap.policies.optimization.Vim_fit.yaml @@ -1,32 +1,8 @@ tosca_definitions_version: tosca_simple_yaml_1_0_0 policy_types: - - onap.policies.Optimization: - derived_from: tosca.policies.Root - version: 1.0.0 - description: a base policy type for all policies that govern optimization - - onap.policies.optimization.Vim_fit: + onap.policies.optimization.Vim_fit: derived_from: onap.policies.Optimization properties: - policyScope: - type: list - description: scope where the policy is applicable - required: true - matchable: true - entry_schema: - type: string - policyType: - type: list - description: type of a policy - required: true - matchable: true - entry_schema: - type: string - constraints: - - valid_values: - - vim_fit - identity: - type: string - required: true applicableResources: type: list required: true @@ -36,16 +12,10 @@ policy_types: - valid_values: - any - all - resources: - type: list - required: true - entry_schema: - type: string - capacityProperties: + capacityProperties: type: policy.data.capacityProperties_properties required: true data_types: - - policy.data.capacityProperties_properties: derived_from: tosca.nodes.Root properties: diff --git a/main/src/test/resources/policytypes/onap.policies.optimization.VnfPolicy.yaml b/main/src/test/resources/policytypes/onap.policies.optimization.VnfPolicy.yaml index 009df412..3ee62483 100644 --- a/main/src/test/resources/policytypes/onap.policies.optimization.VnfPolicy.yaml +++ b/main/src/test/resources/policytypes/onap.policies.optimization.VnfPolicy.yaml @@ -1,37 +1,8 @@ tosca_definitions_version: tosca_simple_yaml_1_0_0 policy_types: - - onap.policies.Optimization: - derived_from: tosca.policies.Root - version: 1.0.0 - description: a base policy type for all policies that govern optimization - - onap.policies.optimization.VnfPolicy: + onap.policies.optimization.VnfPolicy: derived_from: onap.policies.Optimization properties: - policyScope: - type: list - description: scope where the policy is applicable - required: true - matchable: true - entry_schema: - type: string - policyType: - type: list - description: type of a policy - required: true - matchable: true - entry_schema: - type: string - constraints: - - valid_values: - - vnfPolicy - identity: - type: string - required: true - resources: - type: list - required: true - entry_schema: - type: string applicableResources: type: list required: true @@ -47,7 +18,6 @@ policy_types: entry_schema: type: policy.data.vnfProperties_properties data_types: - - policy.data.vnfProperties_properties: derived_from: tosca.nodes.Root properties: |