Pyramid configuration with celery integration. Allows you to use pyramid .ini files to configure celery and have your pyramid configuration inside celery tasks.
Python
Switch branches/tags
Nothing to show
Pull request Compare This branch is 117 commits behind sontek:master.
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
pyramid_celery
pyramid_celery_demo
.gitignore
CHANGES.txt
MANIFEST.in
README.md
requirements.txt
setup.py

README.md

Getting Started

Include pyramid_celery either by setting your includes in your .ini, or by calling config.include('pyramid_celery').

    pyramid.includes = pyramid_celery

Now you can either use class based:

from celery.task import task
from celery.task import Task

@task
class AddTask(Task):
    def run(self, x, y):
        print x+y

or decorator based:

from celery.task import task

@task
def add(x, y):
    print x+y

Configuration

All standard celery configuration options will work. Check out http://ask.github.com/celery/configuration.html

Demo

To see it all in action check out pyramid_celery_demo, run rabbitmq-server and then do:

$ python setup.py develop
$ populate_pyramid_celery_demo ./development.ini
$ pserve ./development.ini
$ pceleryd ./development.ini