Commit 535834c0 authored by Tristan Cavelier's avatar Tristan Cavelier

job checker upgraded to manage job wait

parent b4cec462
...@@ -20,8 +20,11 @@ function enableJobChecker(jio, shared, options) { ...@@ -20,8 +20,11 @@ function enableJobChecker(jio, shared, options) {
shared.job_rule_actions = { shared.job_rule_actions = {
wait: function (original_job, new_job) { wait: function (original_job, new_job) {
// XXX original_job.deferred.promise().always(function () {
return; shared.emit('job', new_job);
});
new_job.state = 'waiting';
new_job.modified = new Date();
}, },
update: function (original_job, new_job) { update: function (original_job, new_job) {
if (!new_job.deferred) { if (!new_job.deferred) {
...@@ -38,6 +41,7 @@ function enableJobChecker(jio, shared, options) { ...@@ -38,6 +41,7 @@ function enableJobChecker(jio, shared, options) {
} }
} }
new_job.state = 'running'; new_job.state = 'running';
new_job.modified = new Date();
}, },
deny: function (original_job, new_job) { deny: function (original_job, new_job) {
// XXX // XXX
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment