[CHANGE] Updating celery.py to prevent deprecation warning

```
[2023-08-14 06:41:04,904: WARNING/MainProcess] /mnt/sda1/Development/Python/AllianceAuth/venv-3.11/lib/python3.11/site-packages/celery/worker/consumer/consumer.py:498: CPendingDeprecationWarning: The broker_connection_retry configuration setting will no longer determine
whether broker connection retries are made during startup in Celery 6.0 and above.
If you wish to retain the existing behavior for retrying connections on startup,
you should set broker_connection_retry_on_startup to True.
```
This commit is contained in:
Peter Pfeufer 2023-09-15 11:42:47 +02:00
parent 36b3077caa
commit 380c41400b
No known key found for this signature in database
GPG Key ID: 6051D2C6AD4EBC27

View File

@ -13,6 +13,10 @@ app = Celery('{{ project_name }}')
# the configuration object to child processes.
app.config_from_object('django.conf:settings')
# Automatically try to establish the connection to the AMQP broker on
# Celery startup if it is unavailable.
app.conf.broker_connection_retry_on_startup = True
# setup priorities ( 0 Highest, 9 Lowest )
app.conf.broker_transport_options = {
'priority_steps': list(range(10)), # setup que to have 10 steps