From 772c73244e6036635cf0861cea08034a932ffad8 Mon Sep 17 00:00:00 2001 From: Pamela Dragosh Date: Sat, 7 Dec 2019 18:00:36 -0500 Subject: Refactor optimization policies Optimization policies need to be further refactored so that Resource vs Service type policies can be specified. Issue-ID: POLICY-2066 Change-Id: Ia40a947097692ea7dcc6ea8d13eb8669c37fac14 Signed-off-by: Pamela Dragosh --- .../policytypes/onap.policies.Optimization.yaml | 16 ---- .../onap.policies.optimization.AffinityPolicy.yaml | 31 ------- .../onap.policies.optimization.DistancePolicy.yaml | 56 ----------- .../onap.policies.optimization.HpaPolicy.yaml | 103 --------------------- ...p.policies.optimization.OptimizationPolicy.yaml | 66 ------------- .../onap.policies.optimization.PciPolicy.yaml | 30 ------ .../onap.policies.optimization.QueryPolicy.yaml | 24 ----- .../onap.policies.optimization.Resource.yaml | 23 +++++ .../onap.policies.optimization.Service.yaml | 15 +++ ...nap.policies.optimization.SubscriberPolicy.yaml | 28 ------ .../onap.policies.optimization.Vim_fit.yaml | 28 ------ .../onap.policies.optimization.VnfPolicy.yaml | 44 --------- ...icies.optimization.resource.AffinityPolicy.yaml | 31 +++++++ ...icies.optimization.resource.DistancePolicy.yaml | 56 +++++++++++ ...p.policies.optimization.resource.HpaPolicy.yaml | 103 +++++++++++++++++++++ ...s.optimization.resource.OptimizationPolicy.yaml | 66 +++++++++++++ ...p.policies.optimization.resource.PciPolicy.yaml | 30 ++++++ ...nap.policies.optimization.resource.Vim_fit.yaml | 28 ++++++ ...p.policies.optimization.resource.VnfPolicy.yaml | 44 +++++++++ ....policies.optimization.service.QueryPolicy.yaml | 24 +++++ ...cies.optimization.service.SubscriberPolicy.yaml | 28 ++++++ 21 files changed, 448 insertions(+), 426 deletions(-) delete mode 100644 models-examples/src/main/resources/policytypes/onap.policies.optimization.AffinityPolicy.yaml delete mode 100644 models-examples/src/main/resources/policytypes/onap.policies.optimization.DistancePolicy.yaml delete mode 100644 models-examples/src/main/resources/policytypes/onap.policies.optimization.HpaPolicy.yaml delete mode 100644 models-examples/src/main/resources/policytypes/onap.policies.optimization.OptimizationPolicy.yaml delete mode 100644 models-examples/src/main/resources/policytypes/onap.policies.optimization.PciPolicy.yaml delete mode 100644 models-examples/src/main/resources/policytypes/onap.policies.optimization.QueryPolicy.yaml create mode 100644 models-examples/src/main/resources/policytypes/onap.policies.optimization.Resource.yaml create mode 100644 models-examples/src/main/resources/policytypes/onap.policies.optimization.Service.yaml delete mode 100644 models-examples/src/main/resources/policytypes/onap.policies.optimization.SubscriberPolicy.yaml delete mode 100644 models-examples/src/main/resources/policytypes/onap.policies.optimization.Vim_fit.yaml delete mode 100644 models-examples/src/main/resources/policytypes/onap.policies.optimization.VnfPolicy.yaml create mode 100644 models-examples/src/main/resources/policytypes/onap.policies.optimization.resource.AffinityPolicy.yaml create mode 100644 models-examples/src/main/resources/policytypes/onap.policies.optimization.resource.DistancePolicy.yaml create mode 100644 models-examples/src/main/resources/policytypes/onap.policies.optimization.resource.HpaPolicy.yaml create mode 100644 models-examples/src/main/resources/policytypes/onap.policies.optimization.resource.OptimizationPolicy.yaml create mode 100644 models-examples/src/main/resources/policytypes/onap.policies.optimization.resource.PciPolicy.yaml create mode 100644 models-examples/src/main/resources/policytypes/onap.policies.optimization.resource.Vim_fit.yaml create mode 100644 models-examples/src/main/resources/policytypes/onap.policies.optimization.resource.VnfPolicy.yaml create mode 100644 models-examples/src/main/resources/policytypes/onap.policies.optimization.service.QueryPolicy.yaml create mode 100644 models-examples/src/main/resources/policytypes/onap.policies.optimization.service.SubscriberPolicy.yaml (limited to 'models-examples/src/main') diff --git a/models-examples/src/main/resources/policytypes/onap.policies.Optimization.yaml b/models-examples/src/main/resources/policytypes/onap.policies.Optimization.yaml index f88239d73..2cd391ff0 100644 --- a/models-examples/src/main/resources/policytypes/onap.policies.Optimization.yaml +++ b/models-examples/src/main/resources/policytypes/onap.policies.Optimization.yaml @@ -13,22 +13,6 @@ policy_types: required: true entry_schema: type: string - services: - description: One or more services that the policy applies to. - type: list - metadata: - matchable: true - required: true - entry_schema: - type: string - resources: - description: One or more VNF resources that the policy applies to. - type: list - metadata: - matchable: true - required: true - entry_schema: - type: string geography: description: One or more geographic regions type: list diff --git a/models-examples/src/main/resources/policytypes/onap.policies.optimization.AffinityPolicy.yaml b/models-examples/src/main/resources/policytypes/onap.policies.optimization.AffinityPolicy.yaml deleted file mode 100644 index abac21922..000000000 --- a/models-examples/src/main/resources/policytypes/onap.policies.optimization.AffinityPolicy.yaml +++ /dev/null @@ -1,31 +0,0 @@ -tosca_definitions_version: tosca_simple_yaml_1_0_0 -policy_types: - onap.policies.optimization.AffinityPolicy: - derived_from: onap.policies.Optimization - version: 1.0.0 - properties: - applicableResources: - type: list - required: true - entry_schema: - type: string - constraints: - - valid_values: - - any - - all - affinityProperties: - type: policy.data.affinityProperties_properties - required: true -data_types: - policy.data.affinityProperties_properties: - derived_from: tosca.nodes.Root - properties: - qualifier: - type: string - constraints: - - valid_values: - - same - - different - category: - type: string - required: true \ No newline at end of file diff --git a/models-examples/src/main/resources/policytypes/onap.policies.optimization.DistancePolicy.yaml b/models-examples/src/main/resources/policytypes/onap.policies.optimization.DistancePolicy.yaml deleted file mode 100644 index 3c9150d9e..000000000 --- a/models-examples/src/main/resources/policytypes/onap.policies.optimization.DistancePolicy.yaml +++ /dev/null @@ -1,56 +0,0 @@ -tosca_definitions_version: tosca_simple_yaml_1_0_0 -policy_types: - onap.policies.optimization.DistancePolicy: - derived_from: onap.policies.Optimization - version: 1.0.0 - properties: - applicableResources: - type: list - required: true - entry_schema: - type: string - constraints: - - valid_values: - - any - - all - distanceProperties: - type: policy.data.distanceProperties_properties - required: true -data_types: - policy.data.distanceProperties_properties: - derived_from: tosca.nodes.Root - properties: - locationInfo: - type: string - required: true - 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: - value: - type: string - required: true - operator: - type: list - required: true - entry_schema: - type: string - constraints: - - valid_values: - - < - - <= - - '>' - - '>=' - - = - unit: - type: list - required: true - entry_schema: - type: string - constraints: - - valid_values: - - km \ No newline at end of file diff --git a/models-examples/src/main/resources/policytypes/onap.policies.optimization.HpaPolicy.yaml b/models-examples/src/main/resources/policytypes/onap.policies.optimization.HpaPolicy.yaml deleted file mode 100644 index dbb5e9ef1..000000000 --- a/models-examples/src/main/resources/policytypes/onap.policies.optimization.HpaPolicy.yaml +++ /dev/null @@ -1,103 +0,0 @@ -tosca_definitions_version: tosca_simple_yaml_1_0_0 -policy_types: - onap.policies.optimization.HpaPolicy: - derived_from: onap.policies.Optimization - version: 1.0.0 - properties: - flavorFeatures: - type: list - required: true - entry_schema: - type: policy.data.flavorFeatures_properties -data_types: - policy.data.flavorFeatures_properties: - derived_from: tosca.nodes.Root - properties: - id: - type: string - required: true - type: - type: string - required: true - directives: - type: list - required: true - entry_schema: - type: policy.data.directives_properties - flavorProperties: - type: list - required: true - entry_schema: - type: policy.data.flavorProperties_properties - policy.data.directives_properties: - derived_from: tosca.nodes.Root - properties: - type: - type: string - attributes: - type: list - entry_schema: - type: policy.data.directives_attributes_properties - policy.data.directives_attributes_properties: - derived_from: tosca.nodes.Root - properties: - attribute_name: - type: string - attribute_value: - type: string - policy.data.flavorProperties_properties: - derived_from: tosca.nodes.Root - properties: - hpa-feature: - type: string - required: true - mandatory: - type: string - required: true - score: - type: string - required: false - architecture: - type: string - required: true - hpa-version: - type: string - required: true - directives: - type: list - required: true - entry_schema: - type: policy.data.directives_properties - hpa-feature-attributes: - type: list - required: true - entry_schema: - type: policy.data.hpa-feature-attributes_properties - policy.data.hpa-feature-attributes_properties: - derived_from: tosca.nodes.Root - properties: - hpa-attribute-key: - type: string - required: true - hpa-attribute-value: - type: string - required: true - operator: - type: list - required: true - entry_schema: - type: string - constraints: - - valid_values: - - < - - <= - - '>' - - '>=' - - = - - '!=' - - any - - all - - subset - unit: - type: string - required: false \ No newline at end of file diff --git a/models-examples/src/main/resources/policytypes/onap.policies.optimization.OptimizationPolicy.yaml b/models-examples/src/main/resources/policytypes/onap.policies.optimization.OptimizationPolicy.yaml deleted file mode 100644 index e03ceeea6..000000000 --- a/models-examples/src/main/resources/policytypes/onap.policies.optimization.OptimizationPolicy.yaml +++ /dev/null @@ -1,66 +0,0 @@ -tosca_definitions_version: tosca_simple_yaml_1_0_0 -policy_types: - onap.policies.optimization.OptimizationPolicy: - derived_from: onap.policies.Optimization - version: 1.0.0 - properties: - objective: - type: list - required: true - entry_schema: - type: string - constraints: - - valid_values: - - minimize - - maximize - objectiveParameter: - type: policy.data.objectiveParameter_properties - required: true -data_types: - policy.data.objectiveParameter_properties: - derived_from: tosca.nodes.Root - properties: - parameterAttributes: - type: list - required: true - entry_schema: - type: policy.data.parameterAttributes_properties - operator: - type: list - required: true - entry_schema: - type: string - constraints: - - valid_values: - - '*' - - + - - '-' - - / - - '%' - policy.data.parameterAttributes_properties: - derived_from: tosca.nodes.Root - properties: - resources: - type: string - required: true - customerLocationInfo: - type: string - required: true - parameter: - type: string - required: true - weight: - type: string - required: true - operator: - type: list - required: true - entry_schema: - type: string - constraints: - - valid_values: - - '*' - - + - - '-' - - / - - '%' \ No newline at end of file diff --git a/models-examples/src/main/resources/policytypes/onap.policies.optimization.PciPolicy.yaml b/models-examples/src/main/resources/policytypes/onap.policies.optimization.PciPolicy.yaml deleted file mode 100644 index 097a5f173..000000000 --- a/models-examples/src/main/resources/policytypes/onap.policies.optimization.PciPolicy.yaml +++ /dev/null @@ -1,30 +0,0 @@ -tosca_definitions_version: tosca_simple_yaml_1_0_0 -policy_types: - onap.policies.optimization.PciPolicy: - derived_from: onap.policies.Optimization - version: 1.0.0 - properties: - pciProperties: - type: list - required: false - entry_schema: - type: policy.data.pciProperties_properties -data_types: - policy.data.pciProperties_properties: - derived_from: tosca.nodes.Root - properties: - algoCategory: - type: string - required: false - pciOptmizationAlgoName: - type: string - required: false - pciOptimizationNwConstraint: - type: string - required: false - pciOptimizationPriority: - type: string - required: false - pciOptimizationTimeConstraint: - type: string - required: false \ No newline at end of file diff --git a/models-examples/src/main/resources/policytypes/onap.policies.optimization.QueryPolicy.yaml b/models-examples/src/main/resources/policytypes/onap.policies.optimization.QueryPolicy.yaml deleted file mode 100644 index 41b923ad7..000000000 --- a/models-examples/src/main/resources/policytypes/onap.policies.optimization.QueryPolicy.yaml +++ /dev/null @@ -1,24 +0,0 @@ -tosca_definitions_version: tosca_simple_yaml_1_0_0 -policy_types: - onap.policies.optimization.QueryPolicy: - derived_from: onap.policies.Optimization - version: 1.0.0 - properties: - queryProperties: - type: list - required: true - entry_schema: - type: policy.data.queryProperties_properties -data_types: - policy.data.queryProperties_properties: - derived_from: tosca.nodes.Root - properties: - attribute: - type: string - required: true - value: - type: string - required: true - attribute_location: - type: string - required: true \ No newline at end of file diff --git a/models-examples/src/main/resources/policytypes/onap.policies.optimization.Resource.yaml b/models-examples/src/main/resources/policytypes/onap.policies.optimization.Resource.yaml new file mode 100644 index 000000000..1d8135162 --- /dev/null +++ b/models-examples/src/main/resources/policytypes/onap.policies.optimization.Resource.yaml @@ -0,0 +1,23 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +policy_types: + onap.policies.optimization.Resource: + derived_from: onap.policies.Optimization + version: 1.0.0 + description: The base policy type for all policies that govern optimization for a Resource in a Service. + properties: + services: + description: One or more services that the policy applies to. + type: list + metadata: + matchable: true + required: true + entry_schema: + type: string + resources: + description: One or more VNF resources that the policy applies to. + type: list + metadata: + matchable: true + required: true + entry_schema: + type: string \ No newline at end of file diff --git a/models-examples/src/main/resources/policytypes/onap.policies.optimization.Service.yaml b/models-examples/src/main/resources/policytypes/onap.policies.optimization.Service.yaml new file mode 100644 index 000000000..8e7b724da --- /dev/null +++ b/models-examples/src/main/resources/policytypes/onap.policies.optimization.Service.yaml @@ -0,0 +1,15 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +policy_types: + onap.policies.optimization.Service: + derived_from: onap.policies.Optimization + version: 1.0.0 + description: The base policy type for all policies that govern optimization for a Service. + properties: + services: + description: One or more services that the policy applies to. + type: list + metadata: + matchable: true + required: true + entry_schema: + type: string \ No newline at end of file diff --git a/models-examples/src/main/resources/policytypes/onap.policies.optimization.SubscriberPolicy.yaml b/models-examples/src/main/resources/policytypes/onap.policies.optimization.SubscriberPolicy.yaml deleted file mode 100644 index 010a1534b..000000000 --- a/models-examples/src/main/resources/policytypes/onap.policies.optimization.SubscriberPolicy.yaml +++ /dev/null @@ -1,28 +0,0 @@ -tosca_definitions_version: tosca_simple_yaml_1_0_0 -policy_types: - onap.policies.optimization.SubscriberPolicy: - derived_from: onap.policies.Optimization - version: 1.0.0 - properties: - subscriberProperties: - type: policy.data.subscriberProperties_properties - required: true -data_types: - policy.data.subscriberProperties_properties: - derived_from: tosca.nodes.Root - properties: - subscriberName: - type: list - required: true - entry_schema: - type: string - subscriberRole: - type: list - required: true - entry_schema: - type: string - provStatus: - type: list - required: true - entry_schema: - type: string \ No newline at end of file diff --git a/models-examples/src/main/resources/policytypes/onap.policies.optimization.Vim_fit.yaml b/models-examples/src/main/resources/policytypes/onap.policies.optimization.Vim_fit.yaml deleted file mode 100644 index b70dddb2f..000000000 --- a/models-examples/src/main/resources/policytypes/onap.policies.optimization.Vim_fit.yaml +++ /dev/null @@ -1,28 +0,0 @@ -tosca_definitions_version: tosca_simple_yaml_1_0_0 -policy_types: - onap.policies.optimization.Vim_fit: - derived_from: onap.policies.Optimization - version: 1.0.0 - properties: - applicableResources: - type: list - required: true - entry_schema: - type: string - constraints: - - valid_values: - - any - - all - capacityProperties: - type: policy.data.capacityProperties_properties - required: true -data_types: - policy.data.capacityProperties_properties: - derived_from: tosca.nodes.Root - properties: - controller: - type: string - required: true - request: - type: string - required: true \ No newline at end of file diff --git a/models-examples/src/main/resources/policytypes/onap.policies.optimization.VnfPolicy.yaml b/models-examples/src/main/resources/policytypes/onap.policies.optimization.VnfPolicy.yaml deleted file mode 100644 index 18a0ccfd0..000000000 --- a/models-examples/src/main/resources/policytypes/onap.policies.optimization.VnfPolicy.yaml +++ /dev/null @@ -1,44 +0,0 @@ -tosca_definitions_version: tosca_simple_yaml_1_0_0 -policy_types: - onap.policies.optimization.VnfPolicy: - derived_from: onap.policies.Optimization - version: 1.0.0 - properties: - applicableResources: - type: list - required: true - entry_schema: - type: string - constraints: - - valid_values: - - any - - all - vnfProperties: - type: list - required: true - entry_schema: - type: policy.data.vnfProperties_properties -data_types: - policy.data.vnfProperties_properties: - derived_from: tosca.nodes.Root - properties: - inventoryProvider: - type: string - required: true - serviceType: - type: string - required: true - inventoryType: - type: list - required: true - entry_schema: - type: string - constraints: - - valid_values: - - serviceInstanceId - - vnfName - - cloudRegionId - - vimId - customerId: - type: string - required: true \ No newline at end of file diff --git a/models-examples/src/main/resources/policytypes/onap.policies.optimization.resource.AffinityPolicy.yaml b/models-examples/src/main/resources/policytypes/onap.policies.optimization.resource.AffinityPolicy.yaml new file mode 100644 index 000000000..173691f21 --- /dev/null +++ b/models-examples/src/main/resources/policytypes/onap.policies.optimization.resource.AffinityPolicy.yaml @@ -0,0 +1,31 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +policy_types: + onap.policies.optimization.resource.AffinityPolicy: + derived_from: onap.policies.optimization.Resource + version: 1.0.0 + properties: + applicableResources: + type: list + required: true + entry_schema: + type: string + constraints: + - valid_values: + - any + - all + affinityProperties: + type: policy.data.affinityProperties_properties + required: true +data_types: + policy.data.affinityProperties_properties: + derived_from: tosca.nodes.Root + properties: + qualifier: + type: string + constraints: + - valid_values: + - same + - different + category: + type: string + required: true \ No newline at end of file diff --git a/models-examples/src/main/resources/policytypes/onap.policies.optimization.resource.DistancePolicy.yaml b/models-examples/src/main/resources/policytypes/onap.policies.optimization.resource.DistancePolicy.yaml new file mode 100644 index 000000000..060c4f97c --- /dev/null +++ b/models-examples/src/main/resources/policytypes/onap.policies.optimization.resource.DistancePolicy.yaml @@ -0,0 +1,56 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +policy_types: + onap.policies.optimization.resource.DistancePolicy: + derived_from: onap.policies.optimization.Resource + version: 1.0.0 + properties: + applicableResources: + type: list + required: true + entry_schema: + type: string + constraints: + - valid_values: + - any + - all + distanceProperties: + type: policy.data.distanceProperties_properties + required: true +data_types: + policy.data.distanceProperties_properties: + derived_from: tosca.nodes.Root + properties: + locationInfo: + type: string + required: true + 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: + value: + type: string + required: true + operator: + type: list + required: true + entry_schema: + type: string + constraints: + - valid_values: + - < + - <= + - '>' + - '>=' + - = + unit: + type: list + required: true + entry_schema: + type: string + constraints: + - valid_values: + - km \ No newline at end of file diff --git a/models-examples/src/main/resources/policytypes/onap.policies.optimization.resource.HpaPolicy.yaml b/models-examples/src/main/resources/policytypes/onap.policies.optimization.resource.HpaPolicy.yaml new file mode 100644 index 000000000..d35552f10 --- /dev/null +++ b/models-examples/src/main/resources/policytypes/onap.policies.optimization.resource.HpaPolicy.yaml @@ -0,0 +1,103 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +policy_types: + onap.policies.optimization.resource.HpaPolicy: + derived_from: onap.policies.optimization.Resource + version: 1.0.0 + properties: + flavorFeatures: + type: list + required: true + entry_schema: + type: policy.data.flavorFeatures_properties +data_types: + policy.data.flavorFeatures_properties: + derived_from: tosca.nodes.Root + properties: + id: + type: string + required: true + type: + type: string + required: true + directives: + type: list + required: true + entry_schema: + type: policy.data.directives_properties + flavorProperties: + type: list + required: true + entry_schema: + type: policy.data.flavorProperties_properties + policy.data.directives_properties: + derived_from: tosca.nodes.Root + properties: + type: + type: string + attributes: + type: list + entry_schema: + type: policy.data.directives_attributes_properties + policy.data.directives_attributes_properties: + derived_from: tosca.nodes.Root + properties: + attribute_name: + type: string + attribute_value: + type: string + policy.data.flavorProperties_properties: + derived_from: tosca.nodes.Root + properties: + hpa-feature: + type: string + required: true + mandatory: + type: string + required: true + score: + type: string + required: false + architecture: + type: string + required: true + hpa-version: + type: string + required: true + directives: + type: list + required: true + entry_schema: + type: policy.data.directives_properties + hpa-feature-attributes: + type: list + required: true + entry_schema: + type: policy.data.hpa-feature-attributes_properties + policy.data.hpa-feature-attributes_properties: + derived_from: tosca.nodes.Root + properties: + hpa-attribute-key: + type: string + required: true + hpa-attribute-value: + type: string + required: true + operator: + type: list + required: true + entry_schema: + type: string + constraints: + - valid_values: + - < + - <= + - '>' + - '>=' + - = + - '!=' + - any + - all + - subset + unit: + type: string + required: false \ No newline at end of file diff --git a/models-examples/src/main/resources/policytypes/onap.policies.optimization.resource.OptimizationPolicy.yaml b/models-examples/src/main/resources/policytypes/onap.policies.optimization.resource.OptimizationPolicy.yaml new file mode 100644 index 000000000..abc329ccd --- /dev/null +++ b/models-examples/src/main/resources/policytypes/onap.policies.optimization.resource.OptimizationPolicy.yaml @@ -0,0 +1,66 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +policy_types: + onap.policies.optimization.resource.OptimizationPolicy: + derived_from: onap.policies.optimization.Resource + version: 1.0.0 + properties: + objective: + type: list + required: true + entry_schema: + type: string + constraints: + - valid_values: + - minimize + - maximize + objectiveParameter: + type: policy.data.objectiveParameter_properties + required: true +data_types: + policy.data.objectiveParameter_properties: + derived_from: tosca.nodes.Root + properties: + parameterAttributes: + type: list + required: true + entry_schema: + type: policy.data.parameterAttributes_properties + operator: + type: list + required: true + entry_schema: + type: string + constraints: + - valid_values: + - '*' + - + + - '-' + - / + - '%' + policy.data.parameterAttributes_properties: + derived_from: tosca.nodes.Root + properties: + resources: + type: string + required: true + customerLocationInfo: + type: string + required: true + parameter: + type: string + required: true + weight: + type: string + required: true + operator: + type: list + required: true + entry_schema: + type: string + constraints: + - valid_values: + - '*' + - + + - '-' + - / + - '%' \ No newline at end of file diff --git a/models-examples/src/main/resources/policytypes/onap.policies.optimization.resource.PciPolicy.yaml b/models-examples/src/main/resources/policytypes/onap.policies.optimization.resource.PciPolicy.yaml new file mode 100644 index 000000000..887e372df --- /dev/null +++ b/models-examples/src/main/resources/policytypes/onap.policies.optimization.resource.PciPolicy.yaml @@ -0,0 +1,30 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +policy_types: + onap.policies.optimization.resource.PciPolicy: + derived_from: onap.policies.optimization.Resource + version: 1.0.0 + properties: + pciProperties: + type: list + required: false + entry_schema: + type: policy.data.pciProperties_properties +data_types: + policy.data.pciProperties_properties: + derived_from: tosca.nodes.Root + properties: + algoCategory: + type: string + required: false + pciOptmizationAlgoName: + type: string + required: false + pciOptimizationNwConstraint: + type: string + required: false + pciOptimizationPriority: + type: string + required: false + pciOptimizationTimeConstraint: + type: string + required: false \ No newline at end of file diff --git a/models-examples/src/main/resources/policytypes/onap.policies.optimization.resource.Vim_fit.yaml b/models-examples/src/main/resources/policytypes/onap.policies.optimization.resource.Vim_fit.yaml new file mode 100644 index 000000000..fd851248f --- /dev/null +++ b/models-examples/src/main/resources/policytypes/onap.policies.optimization.resource.Vim_fit.yaml @@ -0,0 +1,28 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +policy_types: + onap.policies.optimization.resource.Vim_fit: + derived_from: onap.policies.optimization.Resource + version: 1.0.0 + properties: + applicableResources: + type: list + required: true + entry_schema: + type: string + constraints: + - valid_values: + - any + - all + capacityProperties: + type: policy.data.capacityProperties_properties + required: true +data_types: + policy.data.capacityProperties_properties: + derived_from: tosca.nodes.Root + properties: + controller: + type: string + required: true + request: + type: string + required: true \ No newline at end of file diff --git a/models-examples/src/main/resources/policytypes/onap.policies.optimization.resource.VnfPolicy.yaml b/models-examples/src/main/resources/policytypes/onap.policies.optimization.resource.VnfPolicy.yaml new file mode 100644 index 000000000..960ee15f4 --- /dev/null +++ b/models-examples/src/main/resources/policytypes/onap.policies.optimization.resource.VnfPolicy.yaml @@ -0,0 +1,44 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +policy_types: + onap.policies.optimization.resource.VnfPolicy: + derived_from: onap.policies.optimization.Resource + version: 1.0.0 + properties: + applicableResources: + type: list + required: true + entry_schema: + type: string + constraints: + - valid_values: + - any + - all + vnfProperties: + type: list + required: true + entry_schema: + type: policy.data.vnfProperties_properties +data_types: + policy.data.vnfProperties_properties: + derived_from: tosca.nodes.Root + properties: + inventoryProvider: + type: string + required: true + serviceType: + type: string + required: true + inventoryType: + type: list + required: true + entry_schema: + type: string + constraints: + - valid_values: + - serviceInstanceId + - vnfName + - cloudRegionId + - vimId + customerId: + type: string + required: true \ No newline at end of file diff --git a/models-examples/src/main/resources/policytypes/onap.policies.optimization.service.QueryPolicy.yaml b/models-examples/src/main/resources/policytypes/onap.policies.optimization.service.QueryPolicy.yaml new file mode 100644 index 000000000..68c6636b4 --- /dev/null +++ b/models-examples/src/main/resources/policytypes/onap.policies.optimization.service.QueryPolicy.yaml @@ -0,0 +1,24 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +policy_types: + onap.policies.optimization.service.QueryPolicy: + derived_from: onap.policies.optimization.Service + version: 1.0.0 + properties: + queryProperties: + type: list + required: true + entry_schema: + type: policy.data.queryProperties_properties +data_types: + policy.data.queryProperties_properties: + derived_from: tosca.nodes.Root + properties: + attribute: + type: string + required: true + value: + type: string + required: true + attribute_location: + type: string + required: true \ No newline at end of file diff --git a/models-examples/src/main/resources/policytypes/onap.policies.optimization.service.SubscriberPolicy.yaml b/models-examples/src/main/resources/policytypes/onap.policies.optimization.service.SubscriberPolicy.yaml new file mode 100644 index 000000000..b6327c87b --- /dev/null +++ b/models-examples/src/main/resources/policytypes/onap.policies.optimization.service.SubscriberPolicy.yaml @@ -0,0 +1,28 @@ +tosca_definitions_version: tosca_simple_yaml_1_0_0 +policy_types: + onap.policies.optimization.service.SubscriberPolicy: + derived_from: onap.policies.optimization.Service + version: 1.0.0 + properties: + subscriberProperties: + type: policy.data.subscriberProperties_properties + required: true +data_types: + policy.data.subscriberProperties_properties: + derived_from: tosca.nodes.Root + properties: + subscriberName: + type: list + required: true + entry_schema: + type: string + subscriberRole: + type: list + required: true + entry_schema: + type: string + provStatus: + type: list + required: true + entry_schema: + type: string \ No newline at end of file -- cgit 1.2.3-korg