Change in vdsm[master]: lvm: Allow autobackup option in lvm module

nsoffer at redhat.com nsoffer at redhat.com
Fri Mar 13 12:28:24 UTC 2015


Nir Soffer has posted comments on this change.

Change subject: lvm: Allow autobackup option in lvm module
......................................................................


Patch Set 7:

(2 comments)

Thanks Timothy! looks very nice.

Can you add simple tests for the functions you changed?

https://gerrit.ovirt.org/#/c/38195/7/vdsm/storage/lvm.py
File vdsm/storage/lvm.py:

Line 1041: # Public Logical volume interface
Line 1042: #
Line 1043: 
Line 1044: 
Line 1045: def createLV(vgName, lvName, size, autobackup="n", activate=True,
This is correct - kwargs has no order - but did you verify that all callers are calling this using kwargs?

For example, this (bad) call will break now:

    createLV(vgname, lvname, size, True)

If we have such calls, please fix them to use kwargs call style in a separate patch before this patch.
Line 1046:              contiguous=False, initialTag=None):
Line 1047:     """
Line 1048:     Size units: MB (1024 ** 2 = 2 ** 20)B.
Line 1049:     """


Line 1204:         # Fix me: should be se.ChangeLogicalVolumeError but this not exists.
Line 1205:         raise se.MissingTagOnLogicalVolume("%s/%s" % (vg, lv), tag)
Line 1206: 
Line 1207: 
Line 1208: def changeLVTags(vg, lv, autobackup='n', delTags=(), addTags=()):
Same, did you check that all callers are using kwargs call style for delTags and addTags?
Line 1209:     lvname = '%s/%s' % (vg, lv)
Line 1210:     delTags = set(delTags)
Line 1211:     addTags = set(addTags)
Line 1212:     if delTags.intersection(addTags):


-- 
To view, visit https://gerrit.ovirt.org/38195
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I8190878fe071fad46800e666795b94779d745abf
Gerrit-PatchSet: 7
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Timothy Asir <tjeyasin at redhat.com>
Gerrit-Reviewer: Adam Litke <alitke at redhat.com>
Gerrit-Reviewer: Allon Mureinik <amureini at redhat.com>
Gerrit-Reviewer: Dan Kenigsberg <danken at redhat.com>
Gerrit-Reviewer: Eduardo <ewarszaw at gmail.com>
Gerrit-Reviewer: Federico Simoncelli <fsimonce at redhat.com>
Gerrit-Reviewer: Nir Soffer <nsoffer at redhat.com>
Gerrit-Reviewer: Sandro Bonazzola <sbonazzo at redhat.com>
Gerrit-Reviewer: Timothy Asir <tjeyasin 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