This module provide worker for hard work around periodical syncing and updating caches, sending emails or whatever you need do asynchronously.
Installation
pip install leonardo-celery
pip install django-leonardo[celery]
Settings
BROKER_URL = 'redis://localhost:6379/0'
BROKER_URL = 'amqp://user:password@127.0.0.1:5672/leonardo'
Set custom scheduler and result backend
CELERY_RESULT_BACKEND = 'djcelery.backends.database:DatabaseBackend'
CELERYBEAT_SCHEDULER = "djcelery.schedulers.DatabaseScheduler"
Start worker
python manage.py celery worker -B -E
Syncing state
For syncing state to databse run celerycam
python manage.py celerycam
Tasks are discovered by standard mechanism:
app.autodiscover_tasks(lambda: settings.INSTALLED_APPS)
Use smart caching
Use cacheback jobs for fetching data asynchronously.
pip install leonardo-celery[cacheback]
Define your jobs. More about Jobs http://django-cacheback.readthedocs.org/en/latest/usage.html#as-an-instance-of-cacheback-job
Read More
Metadata
Release files for leonardo-celery 0.1.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| leonardo-celery-0.1.2.tar.gz | 3.5 kB | Without provenance | Details for leonardo-celery-0.1.2.tar.gz |
Release files / leonardo-celery-0.1.2.tar.gz
| Download URL | leonardo-celery-0.1.2.tar.gz |
|---|---|
| Size | 3.5 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
2e5fc2f7584dc2d85df47f8fcebd00e183a51137b88dbd7ece4b1e69733ffde6
|
|
BLAKE2b-256 checksum How to use checksums |
40dccbf5a69d23bea8f4ebd5ab97ce753da9c3a2f75b919364f96ef82d61fba6
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
Security for leonardo-celery 0.1.2
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.