Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/ikvk/django_dramatiq_charts
Charts for django_dramatiq - django app
https://github.com/ikvk/django_dramatiq_charts
dashboard django-application dramatiq pypi-package python
Last synced: about 1 month ago
JSON representation
Charts for django_dramatiq - django app
- Host: GitHub
- URL: https://github.com/ikvk/django_dramatiq_charts
- Owner: ikvk
- License: apache-2.0
- Created: 2021-11-26T04:35:02.000Z (almost 3 years ago)
- Default Branch: master
- Last Pushed: 2022-02-09T09:54:53.000Z (almost 3 years ago)
- Last Synced: 2024-09-30T10:42:47.115Z (about 2 months ago)
- Topics: dashboard, django-application, dramatiq, pypi-package, python
- Language: Python
- Homepage:
- Size: 1.4 MB
- Stars: 1
- Watchers: 4
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.rst
- License: LICENSE
Awesome Lists containing this project
README
.. http://docutils.sourceforge.net/docs/user/rst/quickref.html
django_dramatiq_charts 📊
=========================Draw charts by `django_dramatiq `_ task history in db.
Chart types: `load <#load-chart>`_ and `timeline <#timeline-chart>`_.
.. image:: https://img.shields.io/pypi/dm/django_dramatiq_charts.svg?style=social
=============== ===============================================================
Python version 3.6+
License Apache-2.0
PyPI https://pypi.python.org/pypi/django_dramatiq_charts/
=============== ===============================================================.. contents::
Installation
------------
::$ pip install django-dramatiq-charts
Requirements:
* Django 2.2+
* dramatiq 1.11+
* django-dramatiq 0.10.0+Guide
-----Configuration
^^^^^^^^^^^^^1. Add django_dramatiq_charts to installed apps after django_dramatiq app:
.. code-block:: python
INSTALLED_APPS = [
'django_dramatiq',
'django_dramatiq_charts',
'my_app',
# ...
]2. Add lib views to your urls:
.. code-block:: python
from django_dramatiq_charts.views import load_chart, timeline_chart, clean_cache
urlpatterns = [
path('django_dramatiq_charts/load_chart/', load_chart, name='ddc_load_chart'),
path('django_dramatiq_charts/timeline_chart/', timeline_chart, name='ddc_timeline_chart'),
path('django_dramatiq_charts/clean_cache/', clean_cache, name='ddc_clean_cache'),
# ...
]3. Configure lib in your project settings file:
.. list-table::
:header-rows: 1* - Parameter
- Description
- Default
* - DJANGO_DRAMATIQ_CHARTS_PERM_FN
- users with access to the charts
- def fn(request): return request.user.is_superuser
* - DJANGO_DRAMATIQ_CHARTS_LOAD_QS_FILTER
- Additional queryset filter for load chart
- None
* - DJANGO_DRAMATIQ_CHARTS_TIMELINE_QS_FILTER
- Additional queryset filter for timeline chart
- None
* - DJANGO_DRAMATIQ_CHARTS_CACHE_FORM_DATA_SEC
- Minutes to cache choices of queue and actor form fields (False-like to disable)
- 4 hoursLoad chart
^^^^^^^^^^**Shows the number of simultaneously executed actors in each time interval on timeline**
.. image:: docs/load_chart.png
Tasks running more than one day are not counted (assumed to be an error).
Timeline chart
^^^^^^^^^^^^^^**Shows actors on timeline**
.. figure:: docs/timeline_chart.png
If the task duration is less than a second, this task is displayed on the chart with a duration of 1 second.
Release notes
-------------History of important changes: `release_notes.rst `_
Thanks
------Thanks to all who helped develop this library:
`MilkyCake `_,
`lexa2907 `_,
`python `_,
`django `_,
`plotly `_,
`jquery `_,
`select2 `_,
`flaticon.com `_