Skip to content

Commit

Permalink
Create celery_worker.py
Browse files Browse the repository at this point in the history
  • Loading branch information
christianlouis authored Feb 9, 2025
1 parent 37b3876 commit 6eac722
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions app/celery_worker.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
#!/usr/bin/env python3

from celery import Celery
from .config import settings

celery = Celery("document_processor", broker=settings.redis_url, backend=settings.redis_url)

celery.conf.task_routes = {
"app.tasks.*": {"queue": "default"},
}

@celery.task
def test_task():
return "Celery is working!"

0 comments on commit 6eac722

Please sign in to comment.