CC-3342: Pypo: if a user doesn't update anything on calendar for 24 hrs, it could cause a problem.

-make it so that we cannot use all CPU if spinning in while loop
-remove Message Acknowledge exception
This commit is contained in:
Martin Konecny 2012-02-22 19:23:48 -05:00
parent d5a8f63d36
commit 54f81ca5de
1 changed files with 6 additions and 3 deletions

View File

@ -522,10 +522,13 @@ class PypoFetch(Thread):
Queue timeout. Fetching data manually
"""
raise
except MessageStateError, m:
logger.error("Message ACK error: %s", m)
raise
except Exception, e:
"""
sleep 5 seconds so that we don't spin inside this
while loop and eat all the CPU
"""
time.sleep(5)
"""
There is a problem with the RabbitMq messenger service. Let's
log the error and get the schedule via HTTP polling