Change in vdsm[master]: Avoid running scheduled jobs when not SPM.

abaron at redhat.com abaron at redhat.com
Sun Jul 28 20:44:52 UTC 2013


Ayal Baron has posted comments on this change.

Change subject: Avoid running scheduled jobs when not SPM.
......................................................................


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

(4 inline comments)

....................................................
Commit Message
Line 3: AuthorDate: 2013-07-03 17:00:50 +0300
Line 4: Commit:     Eduardo Warszawski <ewarszaw at redhat.com>
Line 5: CommitDate: 2013-07-03 17:50:56 +0300
Line 6: 
Line 7: Avoid running scheduled jobs when not SPM.
who what when why where?
what exactly is this solving? how?
Line 8: 
Line 9: Related to: BZ#960952.
Line 10: 
Line 11: Change-Id: I0402817df9c2c08a5a945082edfbb03e832facbe


....................................................
File vdsm/storage/sp.py
Line 150:     @unsecured
Line 151:     def forceFreeSpm(self):
Line 152:         # DO NOT USE, STUPID, HERE ONLY FOR BC
Line 153:         # TODO: SCSI Fence the 'lastOwner'
Line 154:         self.taskMng.unloadTasks()
this has no place here
Line 155:         self.setMetaParams({PMDK_SPM_ID: SPM_ID_FREE, PMDK_LVER: LVER_INVALID},
Line 156:                            __securityOverride=True)
Line 157:         self.spmRole = SPM_FREE
Line 158: 


Line 272:                 # Forcing to acquire the host id (if it's not acquired already)
Line 273:                 self.masterDomain.acquireHostId(self.id)
Line 274:                 self.masterDomain.acquireClusterLock(self.id)
Line 275:             except:
Line 276:                 self.taskMng.unloadTasks()
this makes no sense.  the tasks are only loaded below on line 306...
Line 277:                 self.spmRole = SPM_FREE
Line 278:                 raise
Line 279: 
Line 280:             self.log.debug("spm lock acquired successfully")


Line 394:             else:
Line 395:                 cls.log.debug("master `%s` is not mounted, skipping", master)
Line 396: 
Line 397:     def stopSpm(self, force=False):
Line 398:         self.taskMng.unloadTasks()
this should at least move down to line 402
Line 399:         with self.lock:
Line 400:             if not force and self.spmRole == SPM_FREE:
Line 401:                 return True
Line 402: 


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

Gerrit-MessageType: comment
Gerrit-Change-Id: I0402817df9c2c08a5a945082edfbb03e832facbe
Gerrit-PatchSet: 1
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Eduardo <ewarszaw at redhat.com>
Gerrit-Reviewer: Ayal Baron <abaron at redhat.com>
Gerrit-Reviewer: Barak Azulay <bazulay at redhat.com>
Gerrit-Reviewer: Dan Kenigsberg <danken at redhat.com>
Gerrit-Reviewer: Elad Ben Aharon <eladba1990 at gmail.com>
Gerrit-Reviewer: Saggi Mizrahi <smizrahi at redhat.com>
Gerrit-Reviewer: Yaniv Bronhaim <ybronhei 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