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

 


Help: OASIS Mailing Lists Help | MarkMail Help

camp message

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


Subject: [OASIS Issue Tracker] Commented: (CAMP-30) Parameter Scheme


    [ http://tools.oasis-open.org/issues/browse/CAMP-30?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=31894#action_31894 ] 

Adrian Otto commented on CAMP-30:
---------------------------------

Section 5.7 presents this as the minimal representation for an AssemblyTemplate:

{
"definition": "some JSON here",
"created": Timestamp
}

It may also have a bunch of other attributes as well, like:

{ 
  "uri": URI,
  "name": String, 
  "description": String, 
  "created": Timestamp, 
  "tags": [String, + ]
  "definition": String,
  "basedOn": {"href": URI}, ? 
  "applicationComponentTemplates": [{"href": URI}, + ], ?
  "platformComponentTemplates": [ {"href": URI}, + ], ?
  "dependencies": [{"href": URI}, + }]
}

I suggest that we allow a special starting character ($) to indicate a variable (label) that should be filled in with a user-supplied value at the time the template is instantiated. For example:

{
"definition": "some JSON here",
"created": Timestamp,
"name" : "$name",
"uri" : "/12342/AssemblyTemplates/1"
}

This would mean that the label "$name" indicates the value provided by the client at the time of instantiation of the template, rather than the string literal defined in the template.

Applications are instantiated in accordance with section 6.10 by sending a POST to an AssemblyTemplate URL. Although the body of the post may be empty, if you provide a body, the parameter names should be used to expand and labels expressed in the template.

For example:

POST /12342/AssemblyTemplates/1 HTTP/1.1
Host: example.org
Content-Type: application/json
Content-Length: 27

{ name : "Rackspace Test" }

The platform would then produce an Assembly with the name "Rackspace Test" set.

I suggest that this same style solution be allowed for all templates in the spec.

> Parameter Scheme
> ----------------
>
>                 Key: CAMP-30
>                 URL: http://tools.oasis-open.org/issues/browse/CAMP-30
>             Project: OASIS Cloud Application Management for Platforms (CAMP) TC
>          Issue Type: Improvement
>          Components: Spec
>            Reporter: Adrian Otto
>            Assignee: Adrian Otto
>
> Create a well defined template parameter scheme that can be used to express special labels in template resource attributes that are used for supplying values upon instantiating entities using the template. In addition to a template parameter label, we also need a standard mechanism to specify values for the labels when using the API.
> This feature can be used for supplying a unique name to an Application Assembly at the time it is created and started. This would allow multiple Application Assemblies to be created from the same template to run concurrently, and offer a way to easily tell them apart from each other. The scheme should be flexible such that it works for Component Templates as well, so that it can be used for passing in configuration parameters that are employed by a downstream configuration management system.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://tools.oasis-open.org/issues/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        


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