Merge pull request #462 from niphlod/fix/scheduler_disabled

a DISABLED worker shouldn't resume after completing a task
This commit is contained in:
mdipierro
2014-06-15 22:20:17 -05:00
+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...')