describe_resource have to return values with better format

Bug #924093 reported by Kei Masumoto
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Compute (nova)
Fix Released
Undecided
Kei Masumoto

Bug Description

describe_resource functionality of python-novaclient is now on reviewing.
<https://review.openstack.org/#change,3457>

As a result of review, the return value of nova.api.openstack.compute.contribe.hosts.show() have to be changed slightly.

Currently, format of return values are depicted below.
> {u'host': {u'usage': {u'admin': {u'memory_mb': 6144, u'vcpus': 3, u'local_gb': 30},
> u'test005': {u'memory_mb': 2048, u'vcpus': 1, u'local_gb': 10}
> },
> u'resource': {u'vcpus_used': 1, u'local_gb_used': 45, u'memory_mb': 32234, u'vcpus': 16, u'local_gb': 128, u'memory_mb_used': 2013}
> }
>}

But it should be like this.
>{u'host': [{u'resource': {u'project': u'(total)', u'host': u'cb-blsv4a1', u'cpu': 16, u'mem(mb)': 32234, u'disk(gb)': 128}},
> {u'resource': {u'project': u'(used_now)', u'host': u'cb-blsv4a1', u'cpu': 2, u'mem(mb)': 2276, u'disk(gb)': 46}},
> {u'resource': {u'project': u'(used_max)', u'host': u'cb-blsv4a1', u'cpu': 2, u'mem(mb)': 4096, u'disk(gb)': 60}},
> {u'resource': {u'project': u'admin', u'host': u'cb-blsv4a1', u'cpu': 1, u'mem(mb)': 2048, u'disk(gb)': 30}},
> {u'resource': {u'project': u'test005', u'host': u'cb-blsv4a1', u'cpu': 1, u'mem(mb)': 2048, u'disk(gb)': 30}}
> ]
>}

Kei Masumoto (masumotok)
Changed in nova:
assignee: nobody → Kei Masumoto (masumotok)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to nova (master)

Fix proposed to branch: master
Review: https://review.openstack.org/3570

Changed in nova:
status: New → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to nova (master)

Reviewed: https://review.openstack.org/3570
Committed: http://github.com/openstack/nova/commit/55a9930c7a67cbb890825435418ab1cc42f0926b
Submitter: Jenkins
Branch: master

commit 55a9930c7a67cbb890825435418ab1cc42f0926b
Author: masumotok <email address hidden>
Date: Tue Jan 31 11:04:18 2012 +0900

    Fix bug #924093

    Change-Id: If014165a630c3722eae26bf2aa1e5d137f145815

Changed in nova:
status: In Progress → Fix Committed
Thierry Carrez (ttx)
Changed in nova:
milestone: none → essex-4
status: Fix Committed → Fix Released
Thierry Carrez (ttx)
Changed in nova:
milestone: essex-4 → 2012.1
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.