Recif Deregle
2012-10-09 15:50:37 UTC
Hi all,
I work in a company who is giving a try to celery. So far its seems exactly
what we need
but i have pb configuring it to use a mysql backend for both broker &
results.
i know this is not the privileged way but we already have to integrate with
an existent solution
does an expert can give me a hand to have this working ?
can't find any ref to the error i am having or any tutos for using it with
mysql.
any help much appreciated.
cheers
=== task01.py ===
from celery import Celery
# define a queue
celery = Celery('task01', backend='database',
broker='sqla+mysql://dbuser:***@dbhost/celery')
# load the configuration
celery.config_from_object('celeryconfig')
# a task definition
@celery.task
def add(x, y):
return x + y
=== celeryconfig.py ==
## Broker settings.
BROKER_URL = "sqla+mysql://dbuser:***@dbhost/celery"
## Using the database to store task state and results.
CELERY_RESULT_BACKEND = "database"
CELERY_RESULT_DBURI = "sqla+mysql://dbuser:***@dbhost/celery"
# echo enables verbose logging from SQLAlchemy.
# CELERY_RESULT_ENGINE_OPTIONS = {"echo": True}
# timezone
CELERY_TIMEZONE = 'Europe/Paris'
=== running the queue ===
# /opt/celery/bin/celery -A task01 --loglevel=info worker
<snip>
[2012-10-09 17:47:32,155: WARNING/PoolWorker-6] return backend(app=self,
url=url)
[2012-10-09 17:47:32,155: WARNING/PoolWorker-6] File
"/opt/celery/lib/python2.6/site-packages/celery-3.0.11-py2.6.egg/celery/backends/database/__init__.py",
line 70, in __init__
[2012-10-09 17:47:32,155: WARNING/PoolWorker-6] 'Missing connection string!
Do you have '
[2012-10-09 17:47:32,155: WARNING/PoolWorker-6] ImproperlyConfigured:
Missing connection string! Do you have CELERY_RESULT_DBURI set to a real
value?
I work in a company who is giving a try to celery. So far its seems exactly
what we need
but i have pb configuring it to use a mysql backend for both broker &
results.
i know this is not the privileged way but we already have to integrate with
an existent solution
does an expert can give me a hand to have this working ?
can't find any ref to the error i am having or any tutos for using it with
mysql.
any help much appreciated.
cheers
=== task01.py ===
from celery import Celery
# define a queue
celery = Celery('task01', backend='database',
broker='sqla+mysql://dbuser:***@dbhost/celery')
# load the configuration
celery.config_from_object('celeryconfig')
# a task definition
@celery.task
def add(x, y):
return x + y
=== celeryconfig.py ==
## Broker settings.
BROKER_URL = "sqla+mysql://dbuser:***@dbhost/celery"
## Using the database to store task state and results.
CELERY_RESULT_BACKEND = "database"
CELERY_RESULT_DBURI = "sqla+mysql://dbuser:***@dbhost/celery"
# echo enables verbose logging from SQLAlchemy.
# CELERY_RESULT_ENGINE_OPTIONS = {"echo": True}
# timezone
CELERY_TIMEZONE = 'Europe/Paris'
=== running the queue ===
# /opt/celery/bin/celery -A task01 --loglevel=info worker
<snip>
[2012-10-09 17:47:32,155: WARNING/PoolWorker-6] return backend(app=self,
url=url)
[2012-10-09 17:47:32,155: WARNING/PoolWorker-6] File
"/opt/celery/lib/python2.6/site-packages/celery-3.0.11-py2.6.egg/celery/backends/database/__init__.py",
line 70, in __init__
[2012-10-09 17:47:32,155: WARNING/PoolWorker-6] 'Missing connection string!
Do you have '
[2012-10-09 17:47:32,155: WARNING/PoolWorker-6] ImproperlyConfigured:
Missing connection string! Do you have CELERY_RESULT_DBURI set to a real
value?
--
You received this message because you are subscribed to the Google Groups "celery-users" group.
To view this discussion on the web visit https://groups.google.com/d/msg/celery-users/-/VdmbivLiLlsJ.
To post to this group, send email to celery-users-/JYPxA39Uh5TLH3MbocFF+G/***@public.gmane.org
To unsubscribe from this group, send email to celery-users+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/***@public.gmane.org
For more options, visit this group at http://groups.google.com/group/celery-users?hl=en.
You received this message because you are subscribed to the Google Groups "celery-users" group.
To view this discussion on the web visit https://groups.google.com/d/msg/celery-users/-/VdmbivLiLlsJ.
To post to this group, send email to celery-users-/JYPxA39Uh5TLH3MbocFF+G/***@public.gmane.org
To unsubscribe from this group, send email to celery-users+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/***@public.gmane.org
For more options, visit this group at http://groups.google.com/group/celery-users?hl=en.