OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.

 


Help: OASIS Mailing Lists Help | MarkMail Help

tosca message

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]


Subject: RE: [tosca] [OASIS Issue Tracker] (TOSCA-274) get_property syntax is not valid


Hi Luc,

I don't think the problem is really about properties vs. capabilities: if there are only two parameters, then obviously we're looking for a property, not a capability. 

The problem is when there are three parameters. If there are three parameters, this could mean the following:

1. The second parameter could point to a capability, and the third parameter would point to a property of that capability
2. The second parameter could point to a requirement, and the third parameter would point to a property of the node that satisfies that requirement

The problems I see are the following:

1. If you have capabilities and requirements with the same name (not altogether unreasonable) then there is no way to distinguish between the two. To ensure unambiguous behavior, we would have to impose some type of ordering (e.g. requirements take precedence over capabilities) 
2. If the second parameter is a requirement, then the third parameter has to be a property of the node that fulfills that requirement. But what if we need a property of capability of the node that fulfill the requirement? It doesn't appear that the current grammar allows for that.

I also believe that the remaining optional parameter (nested_property_name_or_index_n) is challenging. I would prefer if the orchestrator didn't have to dig into the internals of these properties. Wouldn't it be better if we passed the entire property (even if it is a complex data structure or a list) to the scripts and let the scripts figure it out from there?

Chris

-----Original Message-----
From: tosca@lists.oasis-open.org [mailto:tosca@lists.oasis-open.org] On Behalf Of OASIS Issues Tracker
Sent: Wednesday, August 26, 2015 6:27 AM
To: tosca@lists.oasis-open.org
Subject: [tosca] [OASIS Issue Tracker] (TOSCA-274) get_property syntax is not valid

Luc Boutier created TOSCA-274:
---------------------------------

             Summary: get_property syntax is not valid
                 Key: TOSCA-274
                 URL: https://issues.oasis-open.org/browse/TOSCA-274
             Project: OASIS Topology and Orchestration Specification for Cloud Applications (TOSCA) TC
          Issue Type: Bug
          Components: Profile-YAML, Spec - Simple Profile
            Reporter: Luc Boutier
            Priority: Blocker


There is currently a big issue with the syntax of get_property, having an optional parameter as a second parameter with all parameters being of the same type is really bad practice.

Let's consider a node:

node:
  properties:
    toto:
      type: my_complex
  capabilities:
    toto:
      properties:
        titi:
         type: string

Let's say that the my_complex type has a titi field that is a string.

What do we do when we encounter a get_property that is:

get_property["node", "toto", "titi"]

Are we getting the toto's property nested field ? or the titi property of toto capability ?





--
This message was sent by Atlassian JIRA
(v6.2.2#6258)

---------------------------------------------------------------------
To unsubscribe from this mail list, you must leave the OASIS TC that generates this mail.  Follow this link to all your TCs in OASIS at:
https://www.oasis-open.org/apps/org/workgroup/portal/my_workgroups.php 



[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]