-
Notifications
You must be signed in to change notification settings - Fork 4
Limitations and capabilities
This page describes the limitations of the "YAML Transformer". If you want to know, what is meant with "YAML Transformer", click here.
A full documentation is provided at /documentation.
For the remainder of the page the following abbreviations are used:
"transformer" for the here described "YAML Transformer".
"yaml spec" for the used specification.
Dots are used in the yaml examples instead of the leading spaces.
The YAML Transformer is based on the TOSCA Simple Profile in YAML Version 1.0, Committee Specification Draft 01, 27 March 2014
http://docs.oasis-open.org/tosca/TOSCA-Simple-Profile-YAML/v1.0/csd01/TOSCA-Simple-Profile-YAML-v1.0-csd01.pdf
The "new" specification: http://docs.oasis-open.org/tosca/TOSCA-Simple-Profile-YAML/v1.0/TOSCA-Simple-Profile-YAML-v1.0.pdf
The XML specification: http://docs.oasis-open.org/tosca/TOSCA/v1.0/os/TOSCA-v1.0-os.pdf
If you want to use a String containing a ":" or "{" (e.g. for a JSON string), you need to put the whole string into double quotes, e.g. "{key:value}". If you need to set a string within that string, you have to use single quotes, e.g. you need to write "{key:'my-string'}"
This is important, because braces are interpreted as a (Hash-)Map by the transformer. The double quotes mask the braces.
File extensions in artifact types should be set within brackets (e.g.: "[war]" but without the double quotes)
Currently we don't support the following elements of the YAML Service Template:
- imports
- groups
- DeploymentArtifact
NodeTemplates in YAML can have interfaces and artifacts, however those properties are currently not supported and ignored.
Requirements are currently not supported as the definition in the yaml spec stands in conflict with the yaml standard. It is possible to use a capability instead.
If interfaces are used, we can't support the implementation name (or any other property) given in YAML, because the Tosca classes don't support this.
Example:
node_type:
..interfaces:
....InterfaceA:
......operationX:
........implementation: something
Here, the implementation "something" is lost at the moment.
Only ImplementationArtifacts are supported in YAML -> all artifacts in NodeTypes are converted to ArtifactTemplates which are used by a corresponding ImplementationArtifact of a NodeTypeImplementation.
CapabilityTypes are supported like this:
node_templates:
..nodeTemplateFoo:
....capabilities:
......capability_name:
........type: capabilityTypeName
capability_types:
..capabilityTypeName:
....derived_from: XY
....[etc.]
Relationship types are supported.
Example:
relationship_types:
..typeA:
....derived_from: typeRoot
....description: DESCRIPTION
....valid_targets: [CapabilityXY]