Ironic driver requires extra_specs

Bug #1367007 reported by aeva black
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Compute (nova)
Fix Released
Critical
Michael Davies

Bug Description

Comments on review https://review.openstack.org/#/c/111429/ suggested that the Ironic driver should use

  flavor = instance.get_flavor()

instead of

  flavor = flavor_obj.Flavor.get_by_id(context, instance['instance_type_id'])

During the crunch to land things before feature freeze, these were integrated in the proposal to the Nova tree prior to being landed in the Ironic tree (the only place where they would have been tested). These changes actually broke the driver, since it requires access to flavor['extra_specs'] -- which is not present in the instance's cached copy of the flavor.

This problem was discovered when attempting to update the devstack config and begin testing with the driver from the Nova tree (rather than the copy of the driver in the Ironic tree). That patch is here:

https://review.openstack.org/#/c/119844/

The error being encountered can be seen both on the devstack patch (eg, in the Nova code)

http://logs.openstack.org/44/119844/2/check/check-tempest-dsvm-virtual-ironic-nv/ce443f8/logs/screen-n-cpu.txt.gz

and in the back-port of the same code to Ironic here:

http://logs.openstack.org/65/119165/3/check/check-tempest-dsvm-virtual-ironic/c161a89/logs/screen-n-cpu.txt.gz#_2014-09-08_08_41_06_821

==========
Proposed fix
==========

Fetch flavor['extra_specs'] on demand, when needed by the Ironic driver.

Tags: ironic
aeva black (tenbrae)
Changed in nova:
assignee: nobody → Devananda van der Veen (devananda)
aeva black (tenbrae)
Changed in nova:
status: New → Confirmed
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/119944

Changed in nova:
status: Confirmed → In Progress
Changed in nova:
assignee: Devananda van der Veen (devananda) → Michael Davies (mrda)
Changed in nova:
importance: Undecided → High
aeva black (tenbrae)
tags: added: ironic
Thierry Carrez (ttx)
no longer affects: nova/juno
Changed in nova:
importance: High → Critical
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to nova (master)

Reviewed: https://review.openstack.org/119944
Committed: https://git.openstack.org/cgit/openstack/nova/commit/?id=07f53b002eede8570cbae8cbab695429d2fdbc56
Submitter: Jenkins
Branch: master

commit 07f53b002eede8570cbae8cbab695429d2fdbc56
Author: Devananda van der Veen <email address hidden>
Date: Mon Sep 8 15:30:40 2014 -0700

    Ironic driver fetches extra_specs when needed

    The Ironic driver needs to access flavor['extra_specs'] in certain
    situations. This access was erroneously removed during the large patch
    series to land the driver in Nova. The corresponding change did not land
    in Ironic, because it fails to pass tempest (as does the current Ironic
    driver in Nova).

    This patch reverts that change.

    Change-Id: I525c611aa0e98076477c2a9a279a0f8a47858aac
    Closes-bug: 1367007

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