[NEW PATCH] BZ#728958 Don't check read delay when domain was not produced (via gerrit-bot)
Dan Kenigsberg
danken at redhat.com
Wed Sep 7 11:07:31 UTC 2011
New patch submitted by Dan Kenigsberg (danken at redhat.com)
You can review this change at: http://gerrit.usersys.redhat.com/801
commit 9b3b23c754c718be485cc79c69f4cd45d7e28572
Author: Saggi Mizrahi <smizrahi at redhat.com>
Date: Mon Aug 8 16:54:11 2011 +0300
BZ#728958 Don't check read delay when domain was not produced
Change-Id: Idb9a0d62299136cd8011f0e550373900b04ec3af
diff --git a/vdsm/storage/sp.py b/vdsm/storage/sp.py
index 8961e1c..bec3beb 100644
--- a/vdsm/storage/sp.py
+++ b/vdsm/storage/sp.py
@@ -113,13 +113,14 @@ class StatsThread(threading.Thread):
code = 200
delay = 0
- try:
- # This is handled seperatly because in case of this kind
- # of failure we don't want to print stack trace
- delay = self._domain.getReadDelay()
- except Exception, e:
- self.log.error("Could not figure out delay for domain `%s` (%s)", self._sdUUID, e)
- code = 200
+ if self._domain is not None:
+ try:
+ # This is handled seperatly because in case of this kind
+ # of failure we don't want to print stack trace
+ delay = self._domain.getReadDelay()
+ except Exception, e:
+ self.log.error("Could not figure out delay for domain `%s` (%s)", self._sdUUID, e)
+ code = 200
if code != 0:
self._domain = None
More information about the vdsm-patches
mailing list