htools: add group restrictions to findBestAllocGroup
authorIustin Pop <iustin@google.com>
Thu, 7 Jul 2011 11:58:30 +0000 (13:58 +0200)
committerIustin Pop <iustin@google.com>
Fri, 15 Jul 2011 13:24:16 +0000 (15:24 +0200)
commitd72ff6c39260421f6fffded9d8213053b65084a2
treef1cf06525ee21cae5e2295f3b039d018fc547e52
parentc9a9b853326289bb3f01ade10aa74cdfdf93f42d
htools: add group restrictions to findBestAllocGroup

While a normal multi-group allocation doesn't need to restrict the
list of target groups beyond the unallocable status of some groups,
when we relocate instances from one group to the other we need to
limit the subset of searched groups.

Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Guido Trotter <ultrotter@google.com>
htools/Ganeti/HTools/Cluster.hs