-
Notifications
You must be signed in to change notification settings - Fork 14.5k
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
Celery Executor: Issue with broker connection when 'celery_ssl_active' is True #39210
Comments
Thanks for opening your first issue here! Be sure to follow the issue template! If you are willing to raise PR to address this issue please do so, no need to wait for approval. |
Are you able to try to reproduce on the latest version of the celery provider (3.6.2)? |
Wouldn't the See https://www.rabbitmq.com/docs/uri-spec#the-amqps-uri-scheme
And disabling TLS would then go with switching back to the |
@NBardelot My mistake... actually in the above steps to reproduce there is one correction... In stead of False it is True. |
@RNHTTR We install all the required packages using below command: Tried with celery provider (3.6.2). Observing same error. Below is Traceback: During handling of the above exception, another exception occurred: Traceback (most recent call last): |
Apache Airflow version
Other Airflow 2 version (please specify below)
If "Other Airflow 2 version" selected, which one?
2.7.2
What happened?
Basically in our airflow setup we had implemented rabbitmq broker url connection for celery executor. Later on, due to certain vulnerabilities issue, we had implemented SSL for rabbitmq connection. To handle same we changed the value of below config variables as per documentation:
"AIRFLOW__CELERY__BROKER_URL": "amqps://user:password@ip:port/"
"AIRFLOW__CELERY__SSL_ACTIVE": "True"
"AIRFLOW__CELERY__SSL_CACERT": "/path/to/cacert.pem"
But still we were observing airflow exception:
raise AirflowException(
airflow.exceptions.AirflowException: Exception: There was an unknown Celery SSL Error. Please ensure you want to use SSL and/or have all necessary certs and key (The broker you configured does not support SSL_ACTIVE to be True. Please use RabbitMQ or Redis if you would like to use SSL for broker.).
Then after going through source code we found below:
Due to the condition >>"amqp://" in broker_url << the exception was getting raised. When tried by updating the condition and also commenting the "keyfile" and "certfile" in broker_use_ssl, we were able to connect to rabbitmq and proceed.
What you think should happen instead?
The condition when 'celery_ssl_active' is True should be revisited and updated. As the condition if "amqp://" in broker_url is not justified.
How to reproduce
Implement SSL for rabbitmq broker. Update below variables:
"AIRFLOW__CELERY__BROKER_URL": "amqps://user:password@ip:port/"
"AIRFLOW__CELERY__SSL_ACTIVE": "True"
"AIRFLOW__CELERY__SSL_CACERT": "/path/to/cacert.pem"
and try to connect broker.
Operating System
linux
Versions of Apache Airflow Providers
apache-airflow-providers-celery==3.3.4
Deployment
Other Docker-based deployment
Deployment details
No response
Anything else?
No response
Are you willing to submit PR?
Code of Conduct
The text was updated successfully, but these errors were encountered: