Author: eallen
Date: 2008-12-11 11:33:43 -0500 (Thu, 11 Dec 2008)
New Revision: 2972
Modified:
mgmt/trunk/cumin/python/cumin/limits.py
Log:
Avoid exception that happens when a negotiator doesn't have a statsCurr.
Modified: mgmt/trunk/cumin/python/cumin/limits.py
===================================================================
--- mgmt/trunk/cumin/python/cumin/limits.py 2008-12-11 16:20:37 UTC (rev 2971)
+++ mgmt/trunk/cumin/python/cumin/limits.py 2008-12-11 16:33:43 UTC (rev 2972)
@@ -36,12 +36,15 @@
if negotiator.qmfBrokerId:
if not most_recent:
most_recent = negotiator
- if negotiator.statsCurr.qmfUpdateTime > \
- most_recent.statsCurr.qmfUpdateTime:
- most_recent = negotiator
-
+ try:
+ if negotiator.statsCurr.qmfUpdateTime > \
+ most_recent.statsCurr.qmfUpdateTime:
+ most_recent = negotiator
+ except:
+ pass
+
return most_recent
-
+
def set_limit(self, session, limit):
negotiator = self.get_negotiator(session)
action = self.app.model.limit.setlimit
Show replies by date