HomeClusterLabs Projects

Refactor: scheduler: reset node counts more efficiently

Description

Refactor: scheduler: reset node counts more efficiently

Previously, the callers of distribute_children() passed it a sorted list of a
resource's allowed nodes, but that was only used to reset their node counts,
for which the order doesn't matter.

Functionize resetting the node counts, and iterate through the allowed nodes
directly rather than unnecessarily creating a sorted list.

Details

Provenance
kgaillotAuthored on Jul 5 2022, 5:52 PM
Parents
rP97f67da8997d: Refactor: scheduler: best practices for allocate_instance()
Branches
Unknown
Tags
Unknown