if a worker is DISABLED while processing a task, it shouldn't resume after finishing it

This commit is contained in:
niphlod
2014-06-15 17:35:42 +02:00
parent e172c2cade
commit d2c9f510bc
+2 -1
View File
@@ -657,7 +657,8 @@ class Scheduler(MetaScheduler):
self.w_stats.status = RUNNING
self.w_stats.total += 1
self.wrapped_report_task(task, self.async(task))
self.w_stats.status = ACTIVE
if not self.w_stats.status == DISABLED:
self.w_stats.status = ACTIVE
else:
self.w_stats.empty_runs += 1
logger.debug('sleeping...')