diff forums/tasks.py @ 750:aeafbf3ecebf

For #63, upgrade to celery 3.1.7.
author Brian Neal <bgneal@gmail.com>
date Tue, 31 Dec 2013 16:36:22 -0600
parents f3fded5df64b
children
line wrap: on
line diff
--- a/forums/tasks.py	Mon Dec 30 15:05:43 2013 -0600
+++ b/forums/tasks.py	Tue Dec 31 16:36:22 2013 -0600
@@ -2,12 +2,14 @@
 Celery tasks for the forums application.
 
 """
-from celery.task import task
+from __future__ import absolute_import
+
+from celery import shared_task
 
 import forums.latest
 
 
-@task
+@shared_task
 def new_post_task(post_id):
     """
     This task performs new post processing on a Celery task.
@@ -16,7 +18,7 @@
     forums.latest.process_new_post(post_id)
 
 
-@task
+@shared_task
 def updated_post_task(post_id):
     """
     This task performs updated post processing on a Celery task.
@@ -25,7 +27,7 @@
     forums.latest.process_updated_post(post_id)
 
 
-@task
+@shared_task
 def new_topic_task(topic_id):
     """
     This task performs new topic processing on a Celery task.
@@ -34,7 +36,7 @@
     forums.latest.process_new_topic(topic_id)
 
 
-@task
+@shared_task
 def updated_topic_task(topic_id):
     """
     This task performs updated topic processing on a Celery task.