Change in ovirt-engine[master]: sla: Update balancers and add memory based load balancing

rgolan at redhat.com rgolan at redhat.com
Tue May 19 08:42:10 UTC 2015


Roy Golan has submitted this change and it was merged.

Change subject: sla: Update balancers and add memory based load balancing
......................................................................


sla: Update balancers and add memory based load balancing

This patch cleans up the load balancing modules and creates
a new base class for them - CpuAndMemoryBalancingPolicyUnit.
It also cleans up the naming conventions in the code so we
are no longer confused by "overLoadedCPU" method getting
data about idle hosts.

The base class supports primary and secondary reason for
balancing, but does not force the content. All inherited
classes then provide their own lists for primary and
secondary source and destination hosts.

The base class provides parametrized methods for getting
CPU and memory over-, under- and normally loaded hosts.
These methods are meant to be called from the derived classes
when preparing the primary and secondary lists.

Migration is never attempted to CPU or memory overloaded
hosts (not even in power saving).

The Even Distribution unit is then updated to use Memory
as the secondary criteria when no CPU based load balancing
is needed (or possible).

The Power saving unit is updated in the same way, except
it tries to migrate VMs from over and under utilized hosts
to the middle group - normally utilized hosts. This should
behave the same as the old code with the exception of having
the memory information used as well.

Change-Id: I1fe13267feca89ab6c8fb9d85656f05930d0b333
Signed-off-by: Martin Sivak <msivak at redhat.com>
---
A backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/scheduling/policyunits/CpuAndMemoryBalancingPolicyUnit.java
M backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/scheduling/policyunits/EvenDistributionBalancePolicyUnit.java
M backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/scheduling/policyunits/EvenDistributionWeightPolicyUnit.java
M backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/scheduling/policyunits/EvenGuestDistributionBalancePolicyUnit.java
M backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/scheduling/policyunits/PowerSavingBalancePolicyUnit.java
A backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/scheduling/utils/FindVmAndDestinations.java
A backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/scheduling/utils/VdsCpuUsageComparator.java
A backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/scheduling/utils/VmCpuUsageComparator.java
A packaging/dbscripts/upgrade/03_06_1420_add_memory_balancing_vars.sql
9 files changed, 729 insertions(+), 281 deletions(-)

Approvals:
  Roy Golan: Verified; Looks good to me, approved



-- 
To view, visit https://gerrit.ovirt.org/38189
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I1fe13267feca89ab6c8fb9d85656f05930d0b333
Gerrit-PatchSet: 14
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Martin Sivák <msivak at redhat.com>
Gerrit-Reviewer: Jenkins CI
Gerrit-Reviewer: Martin Sivák <msivak at redhat.com>
Gerrit-Reviewer: Roy Golan <rgolan at redhat.com>
Gerrit-Reviewer: Tomer Saban <tsaban at redhat.com>
Gerrit-Reviewer: automation at ovirt.org



More information about the Engine-commits mailing list