针对Impala的Airbnb超集数据源配置

时间:2018-01-08 23:24:11

标签: sqlalchemy impala superset

我们正在尝试使用Superset构建仪表板报告并安装它。我们希望基于Impala表构建报告。在尝试配置数据源时,我使用了下面的sqlalchemy URI

impala:// host:port / dbname

测试连接时出现以下错误。出于安全原因屏蔽了主机名。

enter image description here

我们已经安装了impyla

pip install impyla
Collecting impyla
  Downloading impyla-0.14.0.tar.gz (151kB)
    100% |████████████████████████████████| 153kB 4.7MB/s
Requirement already satisfied: six in ./venv/lib/python2.7/site-packages (from impyla)
Collecting bitarray (from impyla)
  Downloading bitarray-0.8.1.tar.gz (46kB)
    100% |████████████████████████████████| 51kB 5.8MB/s
Requirement already satisfied: thrift in ./venv/lib/python2.7/site-packages (from impyla)
Building wheels for collected packages: impyla, bitarray
  Running setup.py bdist_wheel for impyla ... done
  Stored in directory: /root/.cache/pip/wheels/96/fa/d8/40e676f3cead7ec45f20ac43eb373edc471348ac5cb485d6f5
  Running setup.py bdist_wheel for bitarray ... done
  Stored in directory: /root/.cache/pip/wheels/46/63/90/821699390044b2d0c5f2a01f275115e240bd06f0edc6c6a19b
Successfully built impyla bitarray
Installing collected packages: bitarray, impyla
Successfully installed bitarray-0.8.1 impyla-0.14.0 

如果我在这里缺少任何其他配置impala以与Superset一起使用

,请告诉我

感谢, Phani。

1 个答案:

答案 0 :(得分:0)

让一切完美运行的最简单方法是使用泊坞窗图像(https://hub.docker.com/r/amancevice/superset/

如果您想自己安装所有内容,可以直接从官方dockerfile查看需求列表。(https://hub.docker.com/r/amancevice/superset/~/dockerfile/):

特别注意:

apt-get install -y \
    build-essential \
    curl \
    default-libmysqlclient-dev \
    libffi-dev \
    libldap2-dev \
    libpq-dev \
    libsasl2-dev \
    libssl-dev \
    openjdk-8-jdk \
    python3-dev \
    python3-pip && \
apt-get clean && \
rm -r /var/lib/apt/lists/* && \
pip3 install --no-cache-dir \
    flask-cors==3.0.3 \
    flask-mail==0.9.1 \
    flask-oauth==0.12 \
    flask_oauthlib==0.9.3 \
    gevent==1.2.2 \
    impyla==0.14.0 \
    mysqlclient==1.3.7 \
    psycopg2==2.6.1 \
    pyathenajdbc==1.2.0 \
    pyhive==0.5.0 \
    pyldap==2.4.28 \
    redis==2.10.5 \
    sqlalchemy-redshift==0.5.0 \
    sqlalchemy-clickhouse==0.1.1.post3 \
    Werkzeug==0.12.1 \
    superset==${SUPERSET_VERSION}

此外,在数据库字段 my_db.my_table SQLAlchemy URI 字段中写入 impala:// host:port < / em>的