Validation should catch unavailable resources

Bug #1388047 reported by Steven Hardy
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Heat
Fix Released
High
Kanagaraj Manickam

Bug Description

If you try to launch a stack containing, e.g a OS::Neutron resource on an openstack which doesn't have Neutron, we fail to catch that during validation and start the stack create, then fail later.

It would be better if we could validate availability of the resources (by checking the client can be instantiated, this the endpoint is found?) such that we fail fast when a service is not available.

Possibly, we could add a test to the resource superclass which tries to instantiate the resource client?

Changed in heat:
assignee: nobody → Tetiana Lashchova (tlashchova)
Revision history for this message
Pavlo Shchelokovskyy (pshchelo) wrote :

Once I had an idea of detecting if Neutron is available during heat-engine start and simply not to register Neutron resources then (so they do not even show up in heat resource-type-list), but it turns out some deployments like TripleO do start heat before Neutron...

Also, especially for Nova-network/Neutron case, we have some resources that are "transparent" and use several clients, so there is no single "resource client".

Revision history for this message
Steven Hardy (shardy) wrote :

Yeah, I think it has to be done per-stack at runtime, based on the content of the keystone catalog, which is not perfect as it doesn't prove the service is running, but it does at least prove it's configured and expected to be available in the environment heat is running - this to me seems the least expensive pre-create check we can do, but open to other ideas :)

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

Fix proposed to branch: master
Review: https://review.openstack.org/132305

Changed in heat:
status: New → In Progress
Revision history for this message
Steve Baker (steve-stevebaker) wrote : Re: [Bug 1388047] Re: Validation should catch unavailable resources

On 31/10/14 14:55, Pavlo Shchelokovskyy wrote:
> Once I had an idea of detecting if Neutron is available during heat-
> engine start and simply not to register Neutron resources then (so they
> do not even show up in heat resource-type-list), but it turns out some
> deployments like TripleO do start heat before Neutron...
They start heat before keystone too ;)

Calling self.client_plugin('<client name>') would be enough to determine
if a service is available, and will be cheap to do during validation
since it is just looking up an already loaded service catalog.

Angus Salkeld (asalkeld)
Changed in heat:
importance: Undecided → High
milestone: none → liberty-2
status: In Progress → Triaged
Changed in heat:
assignee: Tetiana Lashchova (tlashchova) → Kanagaraj Manickam (kanagaraj-manickam)
status: Triaged → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Change abandoned on heat (master)

Change abandoned by Tetiana Lashchova (<email address hidden>) on branch: master
Review: https://review.openstack.org/132305

Changed in heat:
status: In Progress → Fix Committed
Thierry Carrez (ttx)
Changed in heat:
status: Fix Committed → Fix Released
Thierry Carrez (ttx)
Changed in heat:
milestone: liberty-2 → 5.0.0
Revision history for this message
Zane Bitter (zaneb) wrote :
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.