remove celery and use dramatiq

This commit is contained in:
virusdefender
2019-03-11 16:21:29 +08:00
parent 1af50c0f4c
commit a5f0c8eb31
16 changed files with 65 additions and 61 deletions

View File

@@ -1,6 +1,3 @@
amqp==2.4.2
billiard==3.5.0.5
celery==4.2.1
certifi==2019.3.9
chardet==3.0.4
coverage==4.5.3
@@ -15,7 +12,6 @@ flake8-quotes==1.0.0
gunicorn==19.9.0
idna==2.8
jsonfield==2.0.2
kombu==4.4.0
mccabe==0.6.1
otpauth==1.0.1
Pillow==5.4.1
@@ -30,5 +26,6 @@ redis==3.2.0
requests==2.21.0
six==1.12.0
urllib3==1.24.1
vine==1.2.0
XlsxWriter==1.1.5
django-dramatiq==0.5.0
dramatiq==1.3.0

View File

@@ -38,12 +38,12 @@ startsecs=5
stopwaitsecs = 5
killasgroup=true
[program:celery]
command=celery -A oj worker -l warning --autoscale 2,%(ENV_MAX_WORKER_NUM)s
[program:dramatiq]
command=python3 manage.py rundramatiq --no-reload --processes %(ENV_MAX_WORKER_NUM)s --threads 4
directory=/app/
user=nobody
stdout_logfile=/data/log/celery.log
stderr_logfile=/data/log/celery.log
stdout_logfile=/data/log/dramatiq.log
stderr_logfile=/data/log/dramatiq.log
autostart=true
autorestart=true
startsecs=5