1.1.1.1 Tosca Policy Type Definitions
A Policy Type defines a type of requirement that affects or governs an application or service’s topology at some stage of its lifecycle, but is not explicitly part of the topology itself (i.e., it does not prevent the application or service from being deployed or run if it did not exist).
1.1.1.1.1 Keynames
The Policy Type is a TOSCA Entity and has the common keynames listed in section Error! Reference source not found. TOSCA Entity Schema.
In addition, the Policy Type has the following recognized keynames:
...
Keyname
...
Required
...
Type
...
Description
...
properties
...
no
...
list of
...
An optional list of property definitions for the Policy Type.
...
targets
...
no
...
string[]
...
An optional list of valid Node Types or Group Types the Policy Type can be applied to.
Note: This can be viewed by TOSCA Orchestrators as an implied relationship to the target nodes, but one that does not have operational lifecycle considerations. For example, if we were to name this as an explicit Relationship Type we might call this “AppliesTo” (node or group).
...
triggers
...
no
...
list of trigger
...
An optional list of policy triggers for the Policy Type.
1.1.1.1.2 Grammar
Policy Types have the following grammar:
derived_from: <parent_policy_type_name> version: <version_number> metadata: description: <policy_description> properties: targets: [ <list_of_valid_target_types> ] triggers: |
...
Table of Contents |
---|
1.1.1.2 SDC Policy Type Metadata
...
conformance level 8.0 | invariantUUID: |
type: string description: Constant identifier of the resource model. Ex.: AA97B177-9383-4934-8543-0F91A7A02836 | ||
conformance level 8.0 | uuid: | type: string description: Versioned identifier of the resource model (this uuid is changed for every major version of the resource) Ex.: b8ff69ca-786d-479e-9f9c-217a90ee0ebc |
conformance level 8.0 | version: | type: string description: The resource version in SDC catalog. Two digit blocks separated by a dot (“.”). Ex. : “2.0” |
conformance level 8.0 | name: | type: string description: The name of the policy. |
...
1.1.1.3 SDC Policy Type Definitions
Tosca Type | Conformance level | Status |
org.openecomp.policies.scaling.Fixed | 8.0 | Defined |
org.openecomp.policies.External | 8.0 | Defined |
org.openecomp.policies.scaling.Variable | future | Defined |
1.1.1.3.1 org.openecomp.policies.scaling.Fixed
...
In case the policy target includes group, recourse quantity addresses group members.
TOSCA definition:
policy_types: org.openecomp.policies.scaling.Fixed: derived_from: tosca.policies.Scaling properties: quantity: description: the exact number of instances to keep up type: integer required: true |
1.1.1.3.2 org.openecomp.policies.External
Policy with type External allows a designer to specify resource specific assignments.
TOSCA definition:
policy_types: org.openecomp.policies.External: derived_from: tosca.policies.Root description: externally managed policy (for example, type="network assignment", source="Policy Manager", name="route target") properties: source: type: string description: The name of the server that exposes the policy with predefined type and name. required: false type: type: string description: The type (category) of the policy same as it is defined in the source. required: false name: type: string description: The name of the policy, that related to specific type, same as it is defined in the source. required: false |
1.1.1.3.3 org.openecomp.policies.scaling.Variable
...
org.openecomp.policies.scaling.Variable: derived_from: tosca.policies.Scaling description: Maintain the number of instances within the specified range properties: init_quantity: description: the number of instances to start with type: integer required: true min_quantity: description: the max. number of instances type: integer required: true max_quantity: description: the min. number of instances type: integer required: true |