← Back to team overview

yahoo-eng-team team mailing list archive

[Bug 1123381] Re: list availability zones doesn't seem to work with the new aggregate model

 

** Changed in: python-novaclient
       Status: Fix Committed => Fix Released

-- 
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to OpenStack Compute (nova).
https://bugs.launchpad.net/bugs/1123381

Title:
  list availability zones doesn't seem to work with the new aggregate
  model

Status in OpenStack Compute (Nova):
  Invalid
Status in Python client library for Nova:
  Fix Released

Bug description:
  Creating an AZ via the nova-client aggregate commands seems to work
  fine, but it doesn't show up in the list.

  
  $ nova aggregate-create az1_agg az1
  +----+---------+-------------------+-------+----------+
  | Id | Name    | Availability Zone | Hosts | Metadata |
  +----+---------+-------------------+-------+----------+
  | 2  | az1_agg | az1               |       |          |
  +----+---------+-------------------+-------+----------+

  
  $ nova aggregate-details 2 availability_zone=az1
  +----+---------+-------------------+-------+--------------------------------+
  | Id | Name    | Availability Zone | Hosts | Metadata                       |
  +----+---------+-------------------+-------+--------------------------------+
  | 2  | az1_agg | az1               | []    | {u'availability_zone': u'az1'} |
  +----+---------+-------------------+-------+--------------------------------+

  
  So far so good, but the new API to list availability zones doesn’t seem to pick this up:

  As a non-admin user: 
  $ nova availability-zone-list
  +------+-----------+
  | Name | Status    |
  +------+-----------+
  | nova | available |
  +------+-----------+

  As an admin user: 
  $ nova availability-zone-list 
  ERROR: 'unicode' object has no attribute 'strftime'

  Although with the debug switch I can see the return value as: 
  RESP: [200] {'date': 'Tue, 12 Feb 2013 13:59:01 GMT', 'x-compute-request-id': 'req-c7af3992-6ac4-45ec-8480-d6ec8b78981a', 'content-type': 'application/json', 'content-length': '857'}
  RESP BODY: {"availabilityZoneInfo": [{"zoneState": {"available": true}, "hosts": {"server-1358868788-az-3-region-a-geo-1.novalocal": {"nova-conductor": {"available": true, "active": true, "updated_at": "2013-02-12T13:58:59.000000"}, "nova-scheduler": {"available": true, "active": true, "updated_at": "2013-02-12T13:59:00.000000"}, "nova-consoleauth": {"available": true, "active": true, "updated_at": "2013-02-12T13:58:57.000000"}, "nova-cert": {"available": true, "active": true, "updated_at": "2013-02-12T13:58:59.000000"}, "nova-network": {"available": true, "active": true, "updated_at": "2013-02-12T13:58:51.000000"}}}, "zoneName": "internal"}, {"zoneState": {"available": true}, "hosts": {"server-1358868788-az-3-region-a-geo-1.novalocal": {"nova-compute": {"available": true, "active": true, "updated_at": "2013-02-12T13:58:53.000000"}}}, "zoneName": "nova"}]}

  
  Looking at the code for this new API – it seems to be calling nova/availability_zones – which I *think* is the pre-aggregate class.

To manage notifications about this bug go to:
https://bugs.launchpad.net/nova/+bug/1123381/+subscriptions