os-aggregates sample files miss

Bug #1294556 reported by Haiwei Xu
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Compute (nova)
Fix Released
Low
Haiwei Xu

Bug Description

os-aggregates' sample files are different in V2 and V3.

~$ vi /opt/stack/nova/doc/api_samples/os-aggregates/aggregates-list-get-resp.json

  1 {
  2 "aggregates": [
  3 {
  4 "availability_zone": "nova",
  5 "created_at": "2012-11-16T06:22:23.361359",
  6 "deleted": false,★
  7 "deleted_at": null,
  8 "hosts": [],
  9 "id": 1,
 10 "metadata": {
 11 "availability_zone": "nova"
 12 },
 13 "name": "name",
 14 "updated_at": null
 15 }
 16 ]
 17 }

~$ vi /opt/stack/nova/doc/v3/api_samples/os-aggregates/aggregates-list-get-resp.json

 1 {
  2 "aggregates": [
  3 {
  4 "availability_zone": "nova",
  5 "created_at": "2013-08-18T12:17:56.856455",
  6 "deleted": 0,★
  7 "deleted_at": null,
  8 "hosts": [],
  9 "id": 1,
 10 "metadata": {
 11 "availability_zone": "nova"
 12 },
 13 "name": "name",
 14 "updated_at": null
 15 }
 16 ]
 17 }

The 'deleted' element is 'false' in V2 but '0' in V3, and it's the same with aggregates-get-resp.json

I also found in the response from the API, 'deleted' is 'false'

 curl -i 'http://10.21.42.98:8774/v3/os-aggregates' -X GET -H "X-Auth-Project-Id: demo" -H "User-Agent: python-novaclient" -H "Accept: application/json" -H "X-Auth-Token: MIISPQYJKoZIhvcNA...

RESP BODY: {"aggregates": [{"name": "agg1", "availability_zone": "nova", ★"deleted": false,★ "created_at": "2014-03-18T19:38:33.000000", "updated_at": null, "hosts": [], "deleted_at": null, "id": 1, "metadata": {"availability_zone": "nova"}}, {"name": "agg2", "availability_zone": null, "deleted": false, "created_at": "2014-03-18T19:41:06.000000", "updated_at": null, "hosts": [], "deleted_at": null, "id": 2, "metadata": {}}]}

So i think this is a bug of V3 sample file.

Haiwei Xu (xu-haiwei)
Changed in nova:
assignee: nobody → Haiwei Xu (xu-haiwei)
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/81487

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

Reviewed: https://review.openstack.org/81487
Committed: https://git.openstack.org/cgit/openstack/nova/commit/?id=65c32882b990a5bb41cdbe241e59bfa0516741c9
Submitter: Jenkins
Branch: master

commit 65c32882b990a5bb41cdbe241e59bfa0516741c9
Author: Haiwei Xu <email address hidden>
Date: Thu Mar 20 03:39:33 2014 +0900

    Fix sample files miss for os-aggregates

    There are some sample files for os-aggregates V3 API assigning
    'deleted' element with '0', which should be assigned to 'false'.
    This patch fixes it.

    Change-Id: I6d7814ce98bc0c701d4eabefcbe64100345cb2d3
    Closes-Bug: #1294556

Changed in nova:
status: In Progress → Fix Committed
Thierry Carrez (ttx)
Changed in nova:
milestone: none → juno-rc1
status: Fix Committed → Fix Released
Thierry Carrez (ttx)
Changed in nova:
milestone: juno-rc1 → 2014.2
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.