Comment 2 for bug 1281319

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

Reviewed: https://review.openstack.org/74521
Committed: https://git.openstack.org/cgit/openstack-infra/nodepool/commit/?id=93689532297efe792ddd2e79930b46c5aaa82fb1
Submitter: Jenkins
Branch: master

commit 93689532297efe792ddd2e79930b46c5aaa82fb1
Author: Robert Collins <email address hidden>
Date: Wed Feb 19 11:32:28 2014 +1300

    Make nodepool more robust to offline clouds.

    When a cloud is offline we cannot query it's flavors or extensions,
    and without those we cannot use a provider manager. For these
    attributes making the properties that lazy-initialize will fix the
    problem (we may make multiple queries, but it is idempotent so
    locking is not needed).

    Callers that trigger flavor or extension lookups have to be able to
    cope with a failure propogating up - I've manually found all the
    places I think.

    The catchall in _getFlavors would mask the problem and lead to
    the manager being incorrectly initialized, so I have removed that.

    Startup will no longer trigger cloud connections in the main thread,
    it will all be deferred to worker threads such as ImageUpdate,
    periodic check etc.

    Additionally I've added some belts-and-braces catches to the two
    key methods - launchImage and updateImage which while they don't
    directly interact with a provider manager do access the provider
    definition, which I think can lead to occasional skew between the
    DB and the configuration - I'm not /sure/ they are needed, but
    I'd rather be safe.

    Change-Id: I7e8e16d5d4266c9424e4c27ebcc36ed7738bc86f
    Fixes-Bug: #1281319