|
|
|
|
@ -6,17 +6,3 @@ from django.conf import settings # noqa |
|
|
|
|
app = Celery('dokumentor') |
|
|
|
|
app.config_from_object('django.conf:settings', namespace='CELERY') |
|
|
|
|
app.autodiscover_tasks() |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
# @app.on_after_configure.connect |
|
|
|
|
# def setup_periodic_tasks(sender, **kwargs): |
|
|
|
|
# # Calls test('hello') every 10 seconds. |
|
|
|
|
# sender.add_periodic_task(10.0, test.s('hello'), name='add every 10') |
|
|
|
|
# |
|
|
|
|
# # Calls test('world') every 30 seconds |
|
|
|
|
# sender.add_periodic_task(30.0, test.s('world'), expires=10) |
|
|
|
|
# |
|
|
|
|
# |
|
|
|
|
# @app.task |
|
|
|
|
# def test(arg): |
|
|
|
|
# print(arg) |
|
|
|
|
|