toncek87 commented on issue #3162: Redshift could not connect to the server
URL: 
https://github.com/apache/incubator-superset/issues/3162#issuecomment-316648559
 
 
   - I installed Redis
   `pip3 install redis`
   
   - dependencies
   `pip install -U "celery[redis]"`
   - run Redis
   `redise-server`
   
   Paste this code to /usr/local/lib/python3.4/dist-packages/superset/config.py
   Configure the class "CeleryConfig", by adding the URL of your Redis 
installation (in my case, localhost:6379):
   ```
   class CeleryConfig(object):
     BROKER_URL =  'redis://localhost:6379/'
     CELERY_IMPORTS = ('superset.sql_lab', )
     CELERY_RESULT_BACKEND =  'redis://localhost:6379/'
     CELERY_ANNOTATIONS = {'tasks.add': {'rate_limit': '10/s'}}
   CELERY_CONFIG = CeleryConfig
   HTTP_HEADERS = {
       'super': 'header!'
   }
   
   # comment the current RESULTS_BACKEND value
   #RESULTS_BACKEND = None
   
   # assign a new value to RESULTS_BACKEND
   RESULTS_BACKEND = FileSystemCache('/tmp/sqllab_cache', 
default_timeout=60*24*7)
   ```
   When i try superset worker
   
   Starting SQL Celery worker.
   Traceback (most recent call last):
     File "/home/rko/venv/bin/superset", line 15, in <module>
       manager.run()
     File 
"/home/rko/venv/lib/python3.4/site-packages/flask_script/__init__.py", line 
412, in run
       result = self.handle(sys.argv[0], sys.argv[1:])
     File 
"/home/rko/venv/lib/python3.4/site-packages/flask_script/__init__.py", line 
383, in handle
       res = handle(*args, **config)
     File 
"/home/rko/venv/lib/python3.4/site-packages/flask_script/commands.py", line 
216, in __call__
       return self.run(*args, **kwargs)
     File "/home/rko/venv/lib/python3.4/site-packages/superset/cli.py", line 
189, in worker
       'broker': config.get('CELERY_CONFIG').BROKER_URL,
   AttributeError: 'NoneType' object has no attribute 'BROKER_URL'
   
   Can you give me any tips?
 
----------------------------------------------------------------
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:
[email protected]


With regards,
Apache Git Services

Reply via email to