libcloud-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Tomaz Muraus (JIRA)" <j...@apache.org>
Subject [jira] [Resolved] (LIBCLOUD-547) linode labels - 1 to 48 chars
Date Sat, 17 May 2014 22:12:14 GMT

     [ https://issues.apache.org/jira/browse/LIBCLOUD-547?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Tomaz Muraus resolved LIBCLOUD-547.
-----------------------------------

    Resolution: Fixed
      Assignee: Tomaz Muraus

This has been merged into trunk.

Thanks.

> linode labels - 1 to 48 chars
> -----------------------------
>
>                 Key: LIBCLOUD-547
>                 URL: https://issues.apache.org/jira/browse/LIBCLOUD-547
>             Project: Libcloud
>          Issue Type: Bug
>          Components: Compute
>    Affects Versions: 0.14.0-beta3
>            Reporter: Gary Wilson
>            Assignee: Tomaz Muraus
>              Labels: linode
>
> The labels generated in libcloud/compute/drivers/linode.py are limited in length, however
seeing as the name is using the node name which is a hostname and can be up to 63 characters
as per RFC 1034, the generated labels can result in a string longer than the allowed 48 characters.
> In this instance the name was zpf-watcher-dev-2-96g-luk1
> [zpf-watcher-dev-2-96g-luk1] Configuration Profile = 51 chars
> Perhaps the linode["id"] could be used instead of name as the name could be longer than
48 chars
> libcloud/compute/drivers/linode.py
> {code}
>         # Labels
>         label = {
>             "lconfig": "[%s] Configuration Profile" % name,
>             "lroot": "[%s] %s Disk Image" % (name, image.name),
>             "lswap": "[%s] Swap Space" % name
>         }
>         for what in ["lconfig", "lroot", "lswap"]:
>             if what in kwargs:
>                 label[what] = kwargs[what]
> {/code}
> {code}
>   File "/usr/lib/python2.6/site-packages/libcloud/compute/drivers/linode.py", line 361,
in create_node
>     data = self.connection.request(API_ROOT, params=params).objects[0]
>   File "/usr/lib/python2.6/site-packages/libcloud/common/base.py", line 675, in request
>     response = responseCls(**kwargs)
>   File "/usr/lib/python2.6/site-packages/libcloud/common/linode.py", line 105, in __init__
>     raise self.errors[0]
> libcloud.common.linode.LinodeException: (8) Invalid Label length - must be between 1
and 48 characters
> {/code}



--
This message was sent by Atlassian JIRA
(v6.2#6252)

Mime
View raw message