Change in vdsm[master]: vdsm: Throw MountError in mount.getRecord()(#883877)
shuming at linux.vnet.ibm.com
shuming at linux.vnet.ibm.com
Wed Jan 16 01:42:56 UTC 2013
Shu Ming has posted comments on this change.
Change subject: vdsm: Throw MountError in mount.getRecord()(#883877)
......................................................................
Patch Set 1: I would prefer that you didn't submit this
(1 inline comment)
....................................................
File vdsm/storage/mount.py
Line 262: if (record.fs_spec == self.fs_spec and
Line 263: record.fs_file == self.fs_file):
Line 264: return record
Line 265:
Line 266: raise MountError(errno.ENOENT,
Also, I think making getRecord to raise an exception is not reasonable when the record is not existing. Why not just return a None when the record is not existing? By returning None, it is easy to handle for the upper level function.
Line 267: "Mount of `%s` at `%s` does not exist" %
Line 268: (self.fs_spec, self.fs_file))
Line 269:
Line 270: def __repr__(self):
--
To view, visit http://gerrit.ovirt.org/10966
To unsubscribe, visit http://gerrit.ovirt.org/settings
Gerrit-MessageType: comment
Gerrit-Change-Id: I0f36b3ea18690d7cf53439e5a0342b1495f4f181
Gerrit-PatchSet: 1
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Vered Volansky <vvolansk at redhat.com>
Gerrit-Reviewer: Ayal Baron <abaron at redhat.com>
Gerrit-Reviewer: Dan Kenigsberg <danken at redhat.com>
Gerrit-Reviewer: Federico Simoncelli <fsimonce at redhat.com>
Gerrit-Reviewer: Shu Ming <shuming at linux.vnet.ibm.com>
Gerrit-Reviewer: Vered Volansky <vvolansk 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