Dan Kenigsberg has submitted this change and it was merged.
Change subject: lvm: Raise an exception if missing physical volume ......................................................................
lvm: Raise an exception if missing physical volume
Raise InaccessiblePhysDev when getting a pv which is not in lvm cache.
When lvm.getPV() tries to get a cached PV object from its cache, there is a possibility that the physical volume is not in the cache anymore. In such a case, we should raise a relevant storage exception, instead of letting the code fail at a random point later when trying to access an attribute of None object.
Change-Id: I9932b044c8b439dc8b1f09191a5d89f4bc44c38a Bug-Url: https://bugzilla.redhat.com/1048696 Signed-off-by: Xavi Francisco xfrancis@redhat.com Signed-off-by: Idan Shaby ishaby@redhat.com Reviewed-on: https://gerrit.ovirt.org/27442 Reviewed-by: Nir Soffer nsoffer@redhat.com Reviewed-by: Dan Kenigsberg danken@redhat.com Reviewed-by: Federico Simoncelli fsimonce@redhat.com --- M vdsm/storage/hsm.py M vdsm/storage/lvm.py 2 files changed, 5 insertions(+), 4 deletions(-)
Approvals: Nir Soffer: Looks good to me, but someone else must approve Federico Simoncelli: Looks good to me, approved Dan Kenigsberg: Looks good to me, but someone else must approve Idan Shaby: Verified