behanjc opened a new issue #3406: Connection Error with Celery and Redis URL: https://github.com/apache/incubator-superset/issues/3406 Make sure these boxes are checked before submitting your issue - thank you! - [x] I have checked the superset logs for python stacktraces and included it here as text if 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 ### Superset version 0.19.0 ### Expected results Able to use Redis/Celery for async backend ### Actual results ConnectionError: Error 8 connecting to redis://XXXXX-dashboard-001.0wmvle.0001.use1.cache.amazonaws.com:6379. nodename nor servname provided, or not known. ### Steps to reproduce Error received when trying to run any query on a database with the async box checked I know this is almost certainly not a superset bug, and something to do with my network environment, but I am hoping someone here can help troubleshoot as I am not sure how to proceed. I have the same redis instance (on AWS elasticache), configured for both the flask-cache and the celery_config. The flask-cache part is working fine, so I have no idea why only the celery would give a connection issue. I am also able to use the redis CLI locally to connect to the instance with no issues. In my superset-config I have the following: ``` class CeleryConfig(object): BROKER_URL = 'redis://XXXXX-dashboard.0wmvle.ng.0001.use1.cache.amazonaws.com/0' CELERY_IMPORTS = ('superset.sql_lab', ) CELERY_RESULT_BACKEND = 'redis://XXXXX-dashboard.0wmvle.ng.0001.use1.cache.amazonaws.com/0' CELERY_ANNOTATIONS = {'tasks.add': {'rate_limit': '10/s'}} CELERY_CONFIG = CeleryConfig RESULTS_BACKEND = RedisCache( host='redis://XXXXX-dashboard.0wmvle.ng.0001.use1.cache.amazonaws.com', port=6379, key_prefix='superset_results') CACHE_CONFIG = {'CACHE_TYPE': 'redis', 'CACHE_REDIS_HOST': 'redis://XXXXX-dashboard-001.0wmvle.0001.use1.cache.amazonaws.com', 'CACHE_REDIS_PORT': 6379, 'CACHE_REDIS_DB': 0, 'CACHE_REDIS_URL': 'redis://XXXXX-dashboard-001.0wmvle.0001.use1.cache.amazonaws.com:6379/0'} ``` I have a superset worker running, and when I try to run a query in SQL Lab, I get the following: ``` Traceback (most recent call last): File "/Users/XXXXXX/anaconda/envs/superset/lib/python3.5/site-packages/superset/sql_lab.py", line 91, in get_sql_results ctask, query_id, return_results, store_results) File "/Users/XXXXXX/anaconda/envs/superset/lib/python3.5/site-packages/superset/sql_lab.py", line 239, in execute_sql results_backend.set(key, utils.zlib_compress(json_payload)) File "/Users/XXXXXX/anaconda/envs/superset/lib/python3.5/site-packages/werkzeug/contrib/cache.py", line 617, in set value=dump, time=timeout) File "/Users/XXXXXX/anaconda/envs/superset/lib/python3.5/site-packages/redis/client.py", line 2278, in setex return self.execute_command('SETEX', name, time, value) File "/Users/XXXXXX/anaconda/envs/superset/lib/python3.5/site-packages/redis/client.py", line 673, in execute_command connection.send_command(*args) File "/Users/XXXXXX/anaconda/envs/superset/lib/python3.5/site-packages/redis/connection.py", line 610, in send_command self.send_packed_command(self.pack_command(*args)) File "/Users/XXXXXX/anaconda/envs/superset/lib/python3.5/site-packages/redis/connection.py", line 585, in send_packed_command self.connect() File "/Users/XXXXXX/anaconda/envs/superset/lib/python3.5/site-packages/redis/connection.py", line 489, in connect raise ConnectionError(self._error_message(e)) redis.exceptions.ConnectionError: Error 8 connecting to redis://XXXXX-dashboard-001.0wmvle.0001.use1.cache.amazonaws.com:6379. nodename nor servname provided, or not known. ``` I have no idea why the connection works for the flask-cache but not for the Celery worker. Any ideas would be greatly appreciated ---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: us...@infra.apache.org
With regards, Apache Git Services