Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

In the flask application I wrote, when using gunicorn and worker_class = "eventlet", the request sent to the celery task through the interface is always in the pending state. #9016

Open
yc2768 opened this issue May 10, 2024 · 0 comments

Comments

@yc2768
Copy link

yc2768 commented May 10, 2024

gunicorn_config.py
`import multiprocessing

workers = 4
timeout = 120
worker_class = "eventlet"
loglevel = (
"debug"
)
accesslog = "./logs/gunicorn_access.log"
errorlog = "./logs/gunicorn_error.log"
access_log_format = '%(h)s %(l)s %(u)s %(t)s "%(r)s" %(s)s %(b)s "%(f)s" "%(a)s" %(D)s'`

执行下面命令,celery 任务不执行,
gunicorn -b myweb.com:8081 main:app --config gunicorn_config.py&
celery -A mytasks.tasks.celery worker -Q generateImg --loglevel=info --concurrency=1 -n generateImg@myhost -P eventlet &,

gunicorn==22.0.0
celery==5.3.6
eventlet==0.36.1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant