Change in ovirt-engine[master]: core: Clean pending memory and CPUs only during init

dfediuck at redhat.com dfediuck at redhat.com
Thu Nov 21 15:20:00 UTC 2013


Doron Fediuck has submitted this change and it was merged.

Change subject: core: Clean pending memory and CPUs only during init
......................................................................


core: Clean pending memory and CPUs only during init

When the engine tries to start a VM, we leave pending memory
and CPU information in the database. This information is removed
when the VDSM reports the VM as fully Up.

However when the engine crashes without telling VDSM, the info
needs to be removed as no VM was actually started.

We dealt with this in VdsUpdateRuntimeInfo so far, but that caused
a race condition: We removed the pending data because the engine
did not manage to send the VM start event to VDSM before the next
VDSM update.

This patch moves the cleanup to the engine startup routines to
make sure it gets applied only in cases of real engine crashes.

Change-Id: I84c2ba29368c0b6bc400087512d7b3a68c5c8f5c
Bug-Url: https://bugzilla.redhat.com/show_bug.cgi?id=1008146
Signed-off-by: Martin Sivak <msivak at redhat.com>
---
M backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/scheduling/SchedulingManager.java
M backend/manager/modules/vdsbroker/src/main/java/org/ovirt/engine/core/vdsbroker/ResourceManager.java
M backend/manager/modules/vdsbroker/src/main/java/org/ovirt/engine/core/vdsbroker/VdsUpdateRunTimeInfo.java
3 files changed, 38 insertions(+), 21 deletions(-)

Approvals:
  Martin Sivák: Verified
  Doron Fediuck: Verified; Looks good to me, approved
  Roy Golan: Looks good to me, approved



-- 
To view, visit http://gerrit.ovirt.org/20172
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I84c2ba29368c0b6bc400087512d7b3a68c5c8f5c
Gerrit-PatchSet: 6
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Martin Sivák <msivak at redhat.com>
Gerrit-Reviewer: Doron Fediuck <dfediuck at redhat.com>
Gerrit-Reviewer: Gilad Chaplik <gchaplik at redhat.com>
Gerrit-Reviewer: Liran Zelkha <lzelkha at redhat.com>
Gerrit-Reviewer: Martin Sivák <msivak at redhat.com>
Gerrit-Reviewer: Michal Skrivanek <michal.skrivanek at redhat.com>
Gerrit-Reviewer: Omer Frenkel <ofrenkel at redhat.com>
Gerrit-Reviewer: Roy Golan <rgolan at redhat.com>
Gerrit-Reviewer: oVirt Jenkins CI Server



More information about the Engine-commits mailing list