tliron / puccini

Cloud topology management and deployment tools based on TOSCA
https://puccini.cloud
Apache License 2.0
91 stars 20 forks source link

call_operation extended notation unsupported #65

Closed philippemerle closed 3 years ago

philippemerle commented 3 years ago

The following template:

tosca_definitions_version: tosca_simple_yaml_1_3
topology_template:
  node_templates:
    node:
      type: tosca.nodes.Root # or any node type
  policies:
    - policy:
        type: tosca.policies.Root # or any policy type
        targets: [ node ]
        triggers:
          t_ok:
            event: an.event.type
            action:
              - call_operation: Standard.stop
          t_problem:
            event: an.event.type
            action:
              - call_operation:
                  operation: Standard.stop
                  inputs: {}

is not supported by Puccini 0.18.0:

$ puccini-tosca compile triggers_action_call_operation.yaml 
PROBLEMS (1)
  file:....../triggers_action_call_operation.yaml
    @18,17 topology_template.policies{0}.triggers["t_problem"].action[0].call_operation: "map" instead of "string"
$

The extended notation for call_operation seems to be unsupported by Puccini, doesn't it?

tliron commented 3 years ago

This has been a TODO for a while. Now finally implemented, quite difficult!

Note that the long notation is only supported since TOSCA 1.3.