A Django helper to monitor jobs running Celery tasks
Project description
Django-Celery-GrowthMonitor
A Django helper to monitor jobs running Celery tasks
Features
Utilities to track progress of Celery tasks via in-database jobs
Requirements
Python >= 3.4
Django >= 1.8
Celery >= 4.0.2
echoices >= 2.5.0
autoslugged >= 2.0.0
Installation
Using PyPI
Run pip install django-celery-growthmonitor
Using the source code
Make sure `pandoc <http://pandoc.org/index.html>`__ is installed
Run ./pypi_packager.sh
Run pip install dist/django_celery_growthmonitor-x.y.z-[...].wheel, where x.y.z must be replaced by the actual version number and [...] depends on your packaging configuration
Usage
('state', echoices.fields.make_echoicefield(default=celery_growthmonitor.models.AJob.EStates.CREATED, echoices=celery_growthmonitor.models.AJob.EStates, editable=False)),
('status', echoices.fields.make_echoicefield(default=celery_growthmonitor.models.AJob.EStatuses.ACTIVE, echoices=celery_growthmonitor.models.AJob.EStatuses, editable=False)),
from .celery import app
@app.task
def my_task(holder: JobHolder, *args):
job = holder.get_job()
# Some processing
return holder.pre_serialization()
Helpers
Admin
from django.contrib import admin
from celery_growthmonitor.admin import AJobAdmin
@admin.register(MyJob)
class MyJobAdmin(AJobAdmin):
fields = AJobAdmin.fields + ('my_extra_field',)
readonly_fields = AJobAdmin.readonly_fields + ('my_extra_field',)
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file django-celery-growthmonitor-0.0.0.dev45.tar.gz
.
File metadata
- Download URL: django-celery-growthmonitor-0.0.0.dev45.tar.gz
- Upload date:
- Size: 24.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | c04e2e1c5d1db91b3304b0cfa274b5885c2bebeb7a9d79cb2c06a6f85f3c08cb |
|
MD5 | 26ace264c357ca6040ef3fc891900f83 |
|
BLAKE2b-256 | b2a6da56f968b6daa16e2a7b156944732fe2560baa38fe0f736e5ccfc5c3e3c1 |
File details
Details for the file django_celery_growthmonitor-0.0.0.dev45-py3-none-any.whl
.
File metadata
- Download URL: django_celery_growthmonitor-0.0.0.dev45-py3-none-any.whl
- Upload date:
- Size: 14.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | b299a96d5521b4301eb7da0721b37053dbe7292061311b0f1373325ebf97d4be |
|
MD5 | 2b719f689e782db11ab03170b9b079b7 |
|
BLAKE2b-256 | 487db3c58d4194c6171e50cf4cebc15644d25d20226ad7d22bfa27655c21e81e |