Change in vdsm[master]: detach: Support force detach on Storage Domains with old pools.

Federico Simoncelli fsimonce at redhat.com
Thu Jun 26 14:08:00 UTC 2014


Federico Simoncelli has posted comments on this change.

Change subject: detach: Support force detach on Storage Domains with old pools.
......................................................................


Patch Set 12:

(1 comment)

http://gerrit.ovirt.org/#/c/29042/12/vdsm/storage/hsm.py
File vdsm/storage/hsm.py:

Line 746:         # We are called with blank pool uuid, to avoid changing exiting
Line 747:         # API which we want to drop in next version anyway.
Line 748:         # So to get the pool we use the fact that there can be only one
Line 749:         # pool, and get the host id from it.
Line 750:         assert len(self.pools) <= 1
> Yea, it would be better. Anyway we already have some asserts in vdsm, they 
"An assertion is a sanity-check that you can turn on or turn off when you are done with your testing of the program."

"Assertions are often enabled during development and disabled during final testing and on release to the customer."

We have to make sure that the "assert" introduced lately are not wrong as this one. Especially in libraries (such as DynamicBarrier and netinfo), where you have no control on the main application execution (could contain -O).
Line 751:         pool = self.pools.values()[0]
Line 752: 
Line 753:         dom = sdCache.produce(sdUUID=sdUUID)
Line 754:         dom.acquireHostId(pool.id)


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

Gerrit-MessageType: comment
Gerrit-Change-Id: I4a6fb01775f7c834a3466e45b9b7ed9b4bd5c3be
Gerrit-PatchSet: 12
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Maor Lipchuk <mlipchuk at redhat.com>
Gerrit-Reviewer: Allon Mureinik <amureini at redhat.com>
Gerrit-Reviewer: Dan Kenigsberg <danken at redhat.com>
Gerrit-Reviewer: Federico Simoncelli <fsimonce at redhat.com>
Gerrit-Reviewer: Maor Lipchuk <mlipchuk at redhat.com>
Gerrit-Reviewer: Nir Soffer <nsoffer at redhat.com>
Gerrit-Reviewer: automation at ovirt.org
Gerrit-Reviewer: oVirt Jenkins CI Server
Gerrit-HasComments: Yes


More information about the vdsm-patches mailing list