Skip to main content

Integration of Django with dramatiq-pg

Project description

dramatiq-pg integration for django

Installation

  1. Install with pip

    $ pip install django-dramatiq-pg
  2. Add to your INSTALLED_APPS list in settings.py

    INSTALLED_APPS = [
        ...
        'django_dramatiq_pg',
    ]
  3. Configure the Database

    DRAMATIQ_BROKER = {
        "OPTIONS": {
            "url": "postgres:///mydb",
        },
        "MIDDLEWARE": [
            "dramatiq.middleware.TimeLimit",
            "dramatiq.middleware.Callbacks",
            "dramatiq.middleware.Retries",
        },
    }
  4. Start the worker process:

    $ dramatiq django_dramatiq_pg.worker

This worker module will auto-discover any module called ‘actors’ in INSTALLED_APPS.

Settings

This package attempts to retain backward compatibility with django-dramatiq settings, but ingores the BROKER key for DRAMATIQ_BROKER.

See https://github.com/Bogdanp/django_dramatiq for more details.

DRAMATIQ_BROKER

A dict of options to pass when instantiating the broker.

DRAMATIC_BROKER[‘OPTIONS’]

Arguments to pass to the Broker.

DRAMATIC_BROKER[‘MIDDLEWARE’]

A list of middleware classes to be passed to the broker.

These can either be import strings, or instances.

DRAMATIQ_ENCODER

Default: None

Import path for encoder class.

DRAMATIQ_ACTORS_MODULE

Default: ‘actors’

Name of module use to auto-discover actors in INSTALLED_APPS.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

django-dramatiq-pg-1.0.5.tar.gz (4.7 kB view details)

Uploaded Source

Built Distribution

django_dramatiq_pg-1.0.5-py3-none-any.whl (6.3 kB view details)

Uploaded Python 3

File details

Details for the file django-dramatiq-pg-1.0.5.tar.gz.

File metadata

  • Download URL: django-dramatiq-pg-1.0.5.tar.gz
  • Upload date:
  • Size: 4.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/44.0.0 requests-toolbelt/0.8.0 tqdm/4.43.0 CPython/3.8.2

File hashes

Hashes for django-dramatiq-pg-1.0.5.tar.gz
Algorithm Hash digest
SHA256 7929e3eb0313c778d324d416123db5a2b81ee36012f163e4de7ee2f305af78b0
MD5 76efd3111f8e82b4bc4fe4eb06ea3d5d
BLAKE2b-256 b4ad5307cca10a3cabae704d994ce6b1c581922ec6a11f4ccde24a896c746203

See more details on using hashes here.

Provenance

File details

Details for the file django_dramatiq_pg-1.0.5-py3-none-any.whl.

File metadata

  • Download URL: django_dramatiq_pg-1.0.5-py3-none-any.whl
  • Upload date:
  • Size: 6.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/44.0.0 requests-toolbelt/0.8.0 tqdm/4.43.0 CPython/3.8.2

File hashes

Hashes for django_dramatiq_pg-1.0.5-py3-none-any.whl
Algorithm Hash digest
SHA256 8ea1b6bbf0f7f99526931bb8af0d6680018ecabb3f6300e80e8d7c7ff57812fb
MD5 bf72eb1ce45d3f730ab2a4acddeaa788
BLAKE2b-256 f78b58b252e8bb8357b80c9983d261679c0f1a057bad4dae819e71fd49468f84

See more details on using hashes here.

Provenance

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page