shawnzhu opened a new issue #14925:
URL: https://github.com/apache/superset/issues/14925


   A clear and concise description of what the bug is.
   
   ### Expected results
   
   When using latest superset from master branch, I expects the celery worker 
could be started successfully when using Redis 6 with ACL as both broker and 
result backend:
   
   ```Python
   # Celery configuration
   class CeleryConfig:  # pylint: disable=too-few-public-methods
       BROKER_URL = '{}/0?ssl_cert_reqs={}&ssl_ca_certs={}'.format(
           os.environ['REDIS_URI'],
           'required',
           '/app/pythonpath/redis-ca.crt',
       )
       CELERY_RESULT_BACKEND = '{}/0?ssl_cert_reqs={}&ssl_ca_certs={}'.format(
           os.environ['REDIS_URI'],
           'required',
           '/app/pythonpath/redis-ca.crt',
       )
   ```
   
   
   ### Actual results
   
   when starting the celery worker, I've got:
   
   ```
   [2021-05-31 23:28:07,904: ERROR/MainProcess] consumer: Cannot connect to 
rediss://xxxx:**@redis-host:32451/0: WRONGPASS invalid username-password pair.
   Trying again in 2.00 seconds... (1/100)
   
   [2021-05-31 23:28:10,021: ERROR/MainProcess] consumer: Cannot connect to 
rediss://xxxx:**@redis-host:32451/0: WRONGPASS invalid username-password pair.
   Trying again in 4.00 seconds... (2/100)
   
   [2021-05-31 23:28:14,279: ERROR/MainProcess] consumer: Cannot connect to 
rediss://xxxx:**@redis-host:32451/0: WRONGPASS invalid username-password pair.
   Trying again in 6.00 seconds... (3/100)
   ```
   
   The environment variable `REDIS_URI` itself works with below test case:
   
   ```Python
   import redis
   import os
   
   redis_uri = '{}/0?ssl_cert_reqs={}&ssl_ca_certs={}'.format(
           os.environ['REDIS_URI'],
           'required',
           '/app/pythonpath/redis-ca.crt',
       )
   
   redis = redis.Redis.from_url(redis_uri)
   
   # redis.set('mykey', 'Hello from Python!')
   value = redis.get('mykey')
   print(value)
   
   #redis.zadd('vehicles', {'car' : 0})
   #redis.zadd('vehicles', {'bike' : 0})
   vehicles = redis.zrange('vehicles', 0, -1)
   print(vehicles)
   ``` 
   
   #### Screenshots
   
   If applicable, add screenshots to help explain your problem.
   
   #### How to reproduce the bug
   
   1. configure celery worker with ACL enabled Redis 6 as broker/backend
   2. start celery worker
   
   ### Environment
   
   (please complete the following information):
   
   - superset version: `0.999.0.dev0` - master branch
   - python version: `Python 3.7.9`
   - node.js version: `node -v`
   
   ### Checklist
   
   Make sure to follow these steps before submitting your issue - thank you!
   
   - [x] I have checked the superset logs for python stacktraces and included 
it here as text if there are any.
   - [x] I have reproduced the issue with at least the latest released version 
of superset.
   - [x] I have checked the issue tracker for the same issue and I haven't 
found one similar.
   
   ### Additional context
   
   This should be a problem of celery itself. see 
https://github.com/celery/celery/issues/6422
   
   So I would suggest upgrading celery to v5.1.0+


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
[email protected]



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to