Change in vdsm[master]: ClientIF: avoid runtime errors at VM shutdown

ykaplan at redhat.com ykaplan at redhat.com
Sun Aug 4 07:50:17 UTC 2013


Yeela Kaplan has posted comments on this change.

Change subject: ClientIF: avoid runtime errors at VM shutdown
......................................................................


Patch Set 3: I would prefer that you didn't submit this

(1 inline comment)

This will not fix the issue, since you still iterate over the dictionary. 


I'm working on a bigger fix , will be uploaded later today.

....................................................
File vdsm/clientIF.py
Line 124:     def removeVmFromMonitoredDomains(self, vmId):
Line 125:         #
Line 126:         # If addVmToMonitoredDomains can held the lock for the whole loop,
Line 127:         # also remove should be fast enough for helding it.
Line 128:         #
The reason add is holding the key is because we want runVm to finish as quickly as possible.

This operation (shutdown) on the other hand is less urgent and we want to allow runVm to take the lock in between if possible.
Line 129:         with self.domainVmIdsLock:
Line 130:             for dom in self.domainVmIds.keys():
Line 131:                 try:
Line 132:                     self.domainVmIds[dom].remove(vmId)


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

Gerrit-MessageType: comment
Gerrit-Change-Id: I4e39f777ce914b8b038505969767b6fd3ff9072f
Gerrit-PatchSet: 3
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Sandro Bonazzola <sbonazzo at redhat.com>
Gerrit-Reviewer: Antoni Segura Puimedon <asegurap at redhat.com>
Gerrit-Reviewer: Ayal Baron <abaron at redhat.com>
Gerrit-Reviewer: Dan Kenigsberg <danken at redhat.com>
Gerrit-Reviewer: Federico Simoncelli <fsimonce at redhat.com>
Gerrit-Reviewer: Greg Padgett <gpadgett at redhat.com>
Gerrit-Reviewer: Michal Skrivanek <michal.skrivanek at redhat.com>
Gerrit-Reviewer: Sandro Bonazzola <sbonazzo at redhat.com>
Gerrit-Reviewer: Yeela Kaplan <ykaplan at redhat.com>
Gerrit-Reviewer: oVirt Jenkins CI Server


More information about the vdsm-patches mailing list