Hi,
AFAIK, currently the "tags" are supported only in EC2.
So, changing the cartridge definition for that seems to be not good.
However this is JSON and we can just add the tags for the definitions.
But adding another element to Cartridge definition means there will be lot
of code changes.
When I was working with vCloud, I noticed each vCloud object can have
metadata. I'm not sure about OpenStack yet, but may be we can have a
generic solution for all IaaSes.
There is also an option to avoid changing the Cartridge definition and add
each tag as a property. We might need to add another property to identify
tags.
"property":[
{
"name":"instanceType",
"value":"m3.medium"
},
{
"name":"keyPair",
"value":"r2-azdev1"
},
{
"name":"tagPrefix",
"value":"tag-"
},
{
"name":"tag-name",
"value":"DEV Stratos"
},
{
"name":"tag-owner",
"value":"Lahiru"
}
],
Thanks!
Best Regards,
On Wed, Mar 26, 2014 at 5:56 AM, Lahiru Sandaruwan <[email protected]>wrote:
> Hi,
>
> I have a requirement to add tags to the instances created through cloud
> controller. jclouds supports tags already.
>
> Since we have to support several tags, we will not abe to support them at
> properties.
>
> How about cartridge definition with iaasProvider like following(Adding
> optional 'tag' element),
>
> "iaasProvider":[
> {
> "type":"ec2-west",
> "imageId":"us-west-1/ami-2a39076f",
> "maxInstanceLimit":"5",
> "property":[
> {
> "name":"instanceType",
> "value":"m3.medium"
> },
> {
> "name":"keyPair",
> "value":"r2-azdev1"
> }
> ],
> "tag":[
> {
> "name":"name",
> "value":"DEV Stratos"
> },
> {
> "name":"owner",
> "value":"Lahiru"
> }
> ],
>
> }
>
> send your thoughts over.
>
> Thanks.
>
--
Isuru Perera
Senior Software Engineer | WSO2, Inc. | http://wso2.com/
Lean . Enterprise . Middleware
about.me/chrishantha