Commit 492e0238 authored by Julian Rother's avatar Julian Rother

Merge branch 'master' of git.fsmpi.rwth-aachen.de:videoagwebsite/videoagwebsite

parents 0aefcd3f 3d4fe94f
This diff is collapsed.
......@@ -17,11 +17,14 @@ def sched_func(delay, priority=0, firstdelay=None, args=[], kargs={}):
def sched_wrapper():
with app.test_request_context():
try:
if config.get('DEBUG', False):
print("Scheduler: started {} (frequency 1/{}s)".format(func.__name__, delay))
func(*args, **kargs)
except Exception:
traceback.print_exc()
scheduler.enter(delay, priority, sched_wrapper)
scheduler.enter(firstdelay, priority, sched_wrapper)
print("Scheduler: registered {} (frequency 1/{}s, start delay: {}s)".format(func.__name__, delay, firstdelay))
return func
return wrapper
......
......@@ -52,9 +52,9 @@
{% for i in worker %}
{% set td = (datetime.now()-(i.last_ping) ) %}
{% if td < timedelta(seconds=10) %}
{% if td < timedelta(seconds=30) %}
<tr class="success">
{% elif td < timedelta(seconds=30) %}
{% elif td < timedelta(seconds=60) %}
<tr class="warning">
{% else %}
<tr class="danger">
......
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