allocation candidates "?member_of=" doesn't work with nested providers

Bug #1792503 reported by Tetsuro Nakamura
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Compute (nova)
Fix Released
Medium
Tetsuro Nakamura
Rocky
Won't Fix
Medium
Tetsuro Nakamura

Bug Description

"GET /allocation_candidates" now supports "member_of" parameter.
With nested providers present, this should work with the following constraints.

---------------------------------------------
(a) With "member_of" qparam, aggregates on the root should span on the whole tree

If a root provider is in the aggregate, which has been specified by "member_of" qparam,
the resource providers under that root can be in allocation candidates even the root is absent.

(b) Without "member_of" qparam, sharing resource provider should be shared with the whole tree

If a sharing provider is in the same aggregate with one resource provider (rpA),
and "member_of" hasn't been specified in qparam by user, the sharing provider can be in
allocation candidates with any of the resource providers in the same tree with rpA.

(c) With "member_of" qparam, the range of the share of sharing resource providers should shrink to the resource providers "under the specified aggregates" in a tree.

Here, whether the rp is "under the specified aggregates" is determined with the constraints of (a). Namely, not only rps that belongs to the aggregates directly are "under the aggregates",
but olso rps whose root is under the aggregates are also "under the aggregates".
---------------------------------------------

So far at Stein PTG time, 2018 Sep. 13th, this constraint is broken in the point that
when placement picks up allocation candidates, the aggregates of nested providers
are assumed as the same as root providers. This means it ignores the aggregates of
the nested provider itself. This could result in the lack of allocation candidates when
an aggregate which on a nested provider but not on the root has been specified in
the `member_of` query parameter.

This bug is well described in a test case which is submitted shortly.

Tags: placement
tags: added: placement
description: updated
Revision history for this message
Tetsuro Nakamura (tetsuro0907) wrote :
Revision history for this message
Eric Fried (efried) wrote :

member_of$N (granular request group) is *not* affected by this bug.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to nova (stable/rocky)

Fix proposed to branch: stable/rocky
Review: https://review.openstack.org/607454

Revision history for this message
Tetsuro Nakamura (tetsuro0907) wrote :

This bug has been fixed on the master of the placement repository. (https://review.openstack.org/#/c/602638/ and https://review.openstack.org/#/c/602639/)

Not they are backported and proposed in stable/rocky being squashed (https://review.openstack.org/607454).

- 20181003 Tetsuro Nakamura

Revision history for this message
OpenStack Infra (hudson-openstack) wrote :

Fix proposed to branch: stable/rocky
Review: https://review.openstack.org/608903

Changed in nova:
assignee: nobody → Tetsuro Nakamura (tetsuro0907)
importance: Undecided → Medium
status: New → In Progress
Revision history for this message
Tetsuro Nakamura (tetsuro0907) wrote :

This bug has been already fixed on placement/master
The backport to nova/stable/rocky is under review.
This bug will be ported to nova/master unless extraction is completed in Stein cycle.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Change abandoned on nova (stable/rocky)

Change abandoned by Matt Riedemann (<email address hidden>) on branch: stable/rocky
Review: https://review.openstack.org/608903
Reason: I'm going to abandon this since as far as I'm aware nothing is using nested providers in stable/rocky (nova isn't) so I think until this is needed by someone we don't need to backport it. I'm abandoning to clean up the nova stable/rocky review queue.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote :

Change abandoned by Matt Riedemann (<email address hidden>) on branch: stable/rocky
Review: https://review.openstack.org/607454
Reason: Abandoning since https://review.openstack.org/#/c/608903/ is abandoned (until someone expresses a need for it).

Chris Dent (cdent)
Changed in nova:
status: In Progress → Fix Committed
Changed in nova:
status: Fix Committed → Fix Released
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.