diff --git a/manager.py b/manager.py index 2762cc2f6c03879246fb04705f909350f884ae18..1450ace424f0a47afbf5a6ac7f2731b3917eec11 100755 --- a/manager.py +++ b/manager.py @@ -38,7 +38,7 @@ api = WorkerApi(config['API']['BASE'],config['API']['KEY']) threading.Thread(target=run_scheduler, daemon=True).start() -@sched_func(5) +@sched_func(15) def ping_website_for_host(): # ping so the website knows our host is still alive if not api.worker_ping(): @@ -58,7 +58,8 @@ while True: continue j = api.worker_schedule(config['JOBS']['TYPES']) if not j: - time.sleep(1) + time.sleep(30) continue print("started jobid %i"%j['id']) procs.append(subprocess.Popen(['./worker.py', str(j['id']), str(j['type']), str(j['priority']) , str(j['data']) ] )) + time.sleep(1)