restructured app and added task signing

This commit is contained in:
Ilan Steemers
2015-06-17 13:33:46 +02:00
parent 4ffa0f7054
commit c8d2927dd2
8 changed files with 218 additions and 186 deletions
@@ -1,9 +1,9 @@
from django.core.management.base import BaseCommand
from django_q.apps import Worker
from django_q import Cluster
class Command(BaseCommand):
help = "My shiny new management command."
def handle(self, *args, **options):
q = Worker()
q = Cluster()
+2 -2
View File
@@ -1,6 +1,6 @@
from django.core.management.base import BaseCommand
from django_q.apps import defer
from django_q import async
class Command(BaseCommand):
@@ -8,4 +8,4 @@ class Command(BaseCommand):
def handle(self, *args, **options):
for i in range(20):
defer('testq.tasks.multiply', 2, i)
async('testq.tasks.multiply', 2, i)