New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

LIBCLOUD-506: Added the resource extra attribute mapping and implemented... #239

Closed
wants to merge 2 commits into
base: trunk
from

Conversation

Projects
None yet
2 participants
@cderamus
Contributor

cderamus commented Feb 2, 2014

... it for networks, nodes and volumes. I also went ahead and added a number of additional properties for each of the three resource types.

Chris DeRamus
LIBCLOUD-506: Added the resource extra attribute mapping and implemen…
…ted it for networks, nodes and volumes. I also went ahead and added a number of additional properties for each of the three resource types.
@Kami

View changes

Show outdated Hide outdated libcloud/compute/drivers/cloudstack.py
for net in nets:
extra = self._get_extra_dict(net, extra_map)
if 'tags' in net.keys():

This comment has been minimized.

@Kami

Kami Feb 2, 2014

Member

.keys() is unnecessary, you can just do if 'tags' in net.

@Kami

Kami Feb 2, 2014

Member

.keys() is unnecessary, you can just do if 'tags' in net.

@Kami

View changes

Show outdated Hide outdated libcloud/compute/drivers/cloudstack.py
for vol in volumes['volume']:
extra = self._get_extra_dict(vol, extra_map)
if 'tags' in vol.keys():

This comment has been minimized.

@Kami

Kami Feb 2, 2014

Member

Same here.

@Kami

Kami Feb 2, 2014

Member

Same here.

@Kami

View changes

Show outdated Hide outdated libcloud/compute/drivers/cloudstack.py
RESOURCE_EXTRA_ATTRIBUTES_MAP = {
'network': {
'broadcast_domain_type': {
'xpath': 'broadcastdomaintype',

This comment has been minimized.

@Kami

Kami Feb 2, 2014

Member

CloudStack API returns JSON so calling a key xpath is deceiving :)

Maybe we should call it key_name or something along those lines?

@Kami

Kami Feb 2, 2014

Member

CloudStack API returns JSON so calling a key xpath is deceiving :)

Maybe we should call it key_name or something along those lines?

This comment has been minimized.

@cderamus

cderamus Feb 2, 2014

Contributor

Ah, nice call!

@cderamus

cderamus Feb 2, 2014

Contributor

Ah, nice call!

@Kami

This comment has been minimized.

Show comment
Hide comment
@Kami

Kami Feb 2, 2014

Member

Merged into trunk, thanks.

Member

Kami commented Feb 2, 2014

Merged into trunk, thanks.

@asfgit asfgit closed this in 39ffb83 Feb 2, 2014

@cderamus cderamus deleted the DivvyCloud:LIBCLOUD-506_Add_Resource_Map_To_CloudStack branch Feb 2, 2014

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment