Change in vdsm[master]: New getChildrenList implementation.

ybronhei at redhat.com ybronhei at redhat.com
Wed Oct 9 07:45:16 UTC 2013


Yaniv Bronhaim has posted comments on this change.

Change subject: New getChildrenList implementation.
......................................................................


Patch Set 8:

(4 comments)

....................................................
Commit Message
Line 3: AuthorDate: 2013-06-16 12:24:17 +0300
Line 4: Commit:     Eduardo Warszawski <ewarszaw at redhat.com>
Line 5: CommitDate: 2013-10-08 23:38:48 +0200
Line 6: 
Line 7: New getChildrenList implementation.
Adding grep util must be separately to this patch, with a commit message about why you use default flags like -H and -E. I prefer to +1 or -1 only this part of the patch, about the getChildren part I can just comment, the separation is necessary .
Line 8: 
Line 9: This implementation returns children of any image on the SD.
Line 10: Avoids to produce each volume in the domain.
Line 11: Implemented like one shot operation.


Line 10: Avoids to produce each volume in the domain.
Line 11: Implemented like one shot operation.
Line 12: 
Line 13: Change-Id: I584cd5d1b03d3965457f12c3d67de95455d1de24
Line 14: Related-to: BZ#960952
put a link please.


....................................................
File lib/vdsm/utils.py
Line 163:                 raise
Line 164:             time.sleep(0.1)
Line 165: 
Line 166: 
Line 167: def grepCmd(pattern, paths):
why not to allow *flags for advance usage? and why -E and -H are added hardcore? I would set them as default *flags value
Line 168:     cmd = [constants.EXT_GREP, '-E', '-H', pattern]
Line 169:     cmd.extend(paths)
Line 170:     rc, out, err = execCmd(cmd)
Line 171:     if rc == 0:


....................................................
File vdsm/storage/fileVolume.py
Line 377:         domPath = self.imagePath.split('images')[0]
Line 378:         gPath = os.path.join(domPath, 'images', '*', '*.meta')
Line 379:         metaPaths = oop.getProcessPool(self.sdUUID).glob.glob(gPath)
Line 380:         pattern = "%s.*%s" % (volume.PUUID, self.volUUID)
Line 381:         matches = grepCmd(pattern, metaPaths)
shouldn't be also oop?
Line 382:         if matches:
Line 383:             children = []
Line 384:             for line in matches:
Line 385:                 volMeta = os.path.basename(line.split(':')[0])


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

Gerrit-MessageType: comment
Gerrit-Change-Id: I584cd5d1b03d3965457f12c3d67de95455d1de24
Gerrit-PatchSet: 8
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Eduardo <ewarszaw at redhat.com>
Gerrit-Reviewer: Ayal Baron <abaron at redhat.com>
Gerrit-Reviewer: Dan Kenigsberg <danken at redhat.com>
Gerrit-Reviewer: Eduardo <ewarszaw at redhat.com>
Gerrit-Reviewer: Elad Ben Aharon <eladba1990 at gmail.com>
Gerrit-Reviewer: Gadi Ickowicz <gickowic at redhat.com>
Gerrit-Reviewer: Sergey Gotliv <sgotliv 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
Gerrit-HasComments: Yes


More information about the vdsm-patches mailing list