OS API issues when calling network API

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

Bug Description

OS API uses instance['info_cache']['network_info'] to use for server details, however it'll fall back to doing network API queries if network_info is None or []. This means that immediate GETs after POST /server will call to the network API.. When using melange and melange is down, CONNREFUSED errors are returned via the API.

We should trust the cache.. Perhaps we should implement some self healing.

Chris Behrens (cbehrens)
Changed in nova:
status: New → In Progress
assignee: nobody → Chris Behrens (cbehrens)
description: updated
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/4269

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to nova (master)

Reviewed: https://review.openstack.org/4269
Committed: http://github.com/openstack/nova/commit/08fa534a0d28fa1be48aef927584161becb936c7
Submitter: Jenkins
Branch: master

commit 08fa534a0d28fa1be48aef927584161becb936c7
Author: Chris Behrens <email address hidden>
Date: Fri Feb 17 00:42:10 2012 +0000

    Remove network_api fallback for info_cache from APIs

    Fixes bug 932395

    OS API and EC2 would query the network API when instance['info_cache']
    had no network info.. or network info was an empty list. The ideal was
    to fall back to querying the network IP in case the cache was busted.

    However, reality says this case is extremely common as it is the case
    when instances are freshly built and haven't had network info assigned
    yet. The calls to network API are expensive and goes against the whole
    idea of this "cache".

    So, this patch removes the fallback to querying the network API. In its
    place, it adds a periodic task to the compute manager to periodically
    sync the cache entry.

    Since I had to fix a number of tests, I consolidated some things there
    as well with regards to instance stubbing.

    Change-Id: I493f811bcba4e99ac6a5756bcab473557d5c0104

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.