← Back to team overview

yahoo-eng-team team mailing list archive

[Bug 1100598] Re: New module "availability_zones" using context not follow habbit

 

** Changed in: nova
       Status: Fix Committed => Fix Released

** Changed in: nova
    Milestone: None => grizzly-3

-- 
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/1100598

Title:
  New module "availability_zones" using context not follow habbit

Status in OpenStack Compute (Nova):
  Fix Released

Bug description:
  As in nova/availability_zones.py, the method def get_host_availability_zone() expect the first argument "context" is a module rather than a RequestContext object. The code is shown below.
  For our preference, argument "context" is better to be a RequestContext object which contains the information of request user.

  def get_host_availability_zone(context, host):
   metadata = db.aggregate_metadata_get_by_host(context.get_admin_context(), host, key='availability_zone')
   ....

  This style may make coder confuse.

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