##// END OF EJS Templates
celerylib: fixed broken tasks for auto-update
super-admin -
r4735:fd8f99cd stable
parent child Browse files
Show More
@@ -43,6 +43,9 b' class ResultWrapper(object):'
43 43
44 44 def run_task(task, *args, **kwargs):
45 45 log.debug('Got task `%s` for execution', task)
46 if task is None:
47 raise ValueError('Got non-existing task for execution')
48
46 49 if rhodecode.CELERY_ENABLED:
47 50 celery_is_up = False
48 51 try:
@@ -386,9 +386,7 b' def beat_check(*args, **kwargs):'
386 386 return time.time()
387 387
388 388
389 @async_task(ignore_result=True)
390 def sync_last_update(*args, **kwargs):
391
389 def sync_last_update_for_objects(*args, **kwargs):
392 390 skip_repos = kwargs.get('skip_repos')
393 391 if not skip_repos:
394 392 repos = Repository.query() \
@@ -405,3 +403,8 b' def sync_last_update(*args, **kwargs):'
405 403 for root_gr in repo_groups:
406 404 for repo_gr in reversed(root_gr.recursive_groups()):
407 405 repo_gr.update_commit_cache()
406
407
408 @async_task(ignore_result=True)
409 def sync_last_update(*args, **kwargs):
410 sync_last_update_for_objects(*args, **kwargs)
General Comments 0
You need to be logged in to leave comments. Login now