Federico Simoncelli has posted comments on this change. Change subject: sp: refresh metadata on hsm when listing domains ......................................................................
Patch Set 4: (3 comments) .................................................... Commit Message Line 3: AuthorDate: 2013-11-27 06:32:14 -0500 Line 4: Commit: Federico Simoncelli <[email protected]> Line 5: CommitDate: 2013-12-06 12:10:20 -0500 Line 6: Line 7: sp: refresh metadata on hsm when listing domains This is part of the pool-no-md topic, and it's used to encapsulate the metadata operations. Line 8: Line 9: In this patch: Line 10: - validatePoolSD and validateAttachedDomain are relevant only for SPM Line 11: operations (remove @unsecured) .................................................... File vdsm/storage/sp.py Line 535: with poolMeta.transaction(): Line 536: poolMeta[PMDK_MASTER_VER] = masterVersion Line 537: domain.changeRole(role) Line 538: Line 539: # TODO: Remove or rename this function. validatePoolSD is used to check if a storage domain is part of the pool in order to do some SPM operation. As we know HSM doesn't care if a storage domain is part of the pool or not. Marking this as "secure" will ring a bell for anyone trying to add an HSM verb that checks if the domain is part of the pool. Line 540: def validatePoolSD(self, sdUUID): Line 541: if sdUUID not in self.getDomains(): Line 542: raise se.StorageDomainNotMemberOfPool(self.spUUID, sdUUID) Line 543: return True Line 536: poolMeta[PMDK_MASTER_VER] = masterVersion Line 537: domain.changeRole(role) Line 538: Line 539: # TODO: Remove or rename this function. Line 540: def validatePoolSD(self, sdUUID): We don't have more invalidations, now that this is an SPM verb the validation is prevented by invalidateMetadata (smart enough to skip the invalidation for the SPM). Line 541: if sdUUID not in self.getDomains(): Line 542: raise se.StorageDomainNotMemberOfPool(self.spUUID, sdUUID) Line 543: return True Line 544: -- To view, visit http://gerrit.ovirt.org/21786 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I095cd0760076fb4be97a776498af78a40ff84112 Gerrit-PatchSet: 4 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Federico Simoncelli <[email protected]> Gerrit-Reviewer: Allon Mureinik <[email protected]> Gerrit-Reviewer: Ayal Baron <[email protected]> Gerrit-Reviewer: Dan Kenigsberg <[email protected]> Gerrit-Reviewer: Eduardo <[email protected]> Gerrit-Reviewer: Federico Simoncelli <[email protected]> Gerrit-Reviewer: Nir Soffer <[email protected]> Gerrit-Reviewer: Sergey Gotliv <[email protected]> Gerrit-Reviewer: oVirt Jenkins CI Server Gerrit-HasComments: Yes _______________________________________________ vdsm-patches mailing list [email protected] https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
