Hi Lahiru,

Actually there's a limitation in jclouds, that you cannot have name, value
pairs as tags, but only names :-) (at least this is what I see in the API)

public EC2TemplateOptions tags(Iterable<String> tags) {
      return EC2TemplateOptions.class.cast(super.tags(tags));
   }

On Wed, Mar 26, 2014 at 8:59 AM, Lahiru Sandaruwan <[email protected]> wrote:

> Ahh. Great :)
>
> One question can we customize "name" tag?
>
>
> On Tue, Mar 25, 2014 at 8:19 PM, Nirmal Fernando 
> <[email protected]>wrote:
>
>> Guys,
>>
>> We already have tags support for EC2 in CC. :-) Please add a property to
>> IaaSProvider section, named as 'tags' and also you can have a comma
>> separated list of values for that.
>>
>>
>> On Wed, Mar 26, 2014 at 8:46 AM, Lahiru Sandaruwan <[email protected]>wrote:
>>
>>>
>>>
>>> On Tue, Mar 25, 2014 at 7:42 PM, Isuru Perera <[email protected]> wrote:
>>>
>>>> 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"
>>>>                 }
>>>>             ],
>>>>
>>>
>>> +1... Will do like this.
>>>
>>> BTW. What do you mean by tagPrefix?
>>>
>>>>
>>>> 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
>>>>
>>>
>>>
>>>
>>> --
>>> --
>>> Lahiru Sandaruwan
>>> Software Engineer,
>>> Platform Technologies,
>>> WSO2 Inc., http://wso2.com
>>> lean.enterprise.middleware
>>>
>>> email: [email protected] cell: (+94) 773 325 954
>>> blog: http://lahiruwrites.blogspot.com/
>>> twitter: http://twitter.com/lahirus
>>> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>
>>>
>>
>>
>> --
>> Best Regards,
>> Nirmal
>>
>> Nirmal Fernando.
>> PPMC Member & Committer of Apache Stratos,
>> Senior Software Engineer, WSO2 Inc.
>>
>> Blog: http://nirmalfdo.blogspot.com/
>>
>
>
>
> --
> --
> Lahiru Sandaruwan
> Software Engineer,
> Platform Technologies,
> WSO2 Inc., http://wso2.com
> lean.enterprise.middleware
>
> email: [email protected] cell: (+94) 773 325 954
> blog: http://lahiruwrites.blogspot.com/
> twitter: http://twitter.com/lahirus
> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>
>


-- 
Best Regards,
Nirmal

Nirmal Fernando.
PPMC Member & Committer of Apache Stratos,
Senior Software Engineer, WSO2 Inc.

Blog: http://nirmalfdo.blogspot.com/

Reply via email to