Skip to content

Commit e812377

Browse files
Do not continue to autoreload the job page if a reload fails. (#504)
Autoreload causes the job page to hit the backend every couple of seconds. However, most RQ implementations set a TTL on jobs in redis. So, this polling will eventually fail. If it continues, it will do so continuously. This makes it difficult for users to set up monitoring and alerting, since these errors eventually overwhelm everything else coming from RQ dashboard. And, the refreshes are meaningless anyway. This PR stops polling on the job page if a reload fails.
1 parent 0a84a8c commit e812377

File tree

1 file changed

+1
-1
lines changed
  • rq_dashboard/templates/rq_dashboard/scripts

1 file changed

+1
-1
lines changed

rq_dashboard/templates/rq_dashboard/scripts/job.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
var reload_job_info = function(done) {
99
api.getJob({{ id|tojson|safe }}, function(job, err) {
1010
if (err) {
11-
return done();
11+
return;
1212
}
1313
onJobLoaded(job, done);
1414
});

0 commit comments

Comments
 (0)