![将 Apache Drill 与 Apache Superset 集成](https://linux22.com/image/1605262/%E5%B0%86%20Apache%20Drill%20%E4%B8%8E%20Apache%20Superset%20%E9%9B%86%E6%88%90.png)
我通过钻探文档。Apache Drill 运行良好。我还使用 docker 安装并运行了 Apache Superset。Superset 也运行良好。
但我的目标是将 Superset 和 Drill 整合在一起。我能找到的唯一教程是来自 Dataist 的教程。按照本教程操作时,他们要求我们添加一个数据库。
由于我在本地机器上运行 Drill 和 Superset,他们要求我们输入drill+sadrill://localhost:8047/dfs/test?use_ssl=False
SQLAlchemy URI。他们要求我们按测试连接来测试连接。
按下测试连接时,我收到如下错误消息。
ERROR: {"error": "Connection failed!
The error message returned was:
Can't load plugin: sqlalchemy.dialects:drill.sadrill", "stacktrace": "Traceback (most recent call last):
File \"/home/superset/superset/views/core.py\", line 1755, in testconn
engine = database.get_sqla_engine(user_name=username)
File \"/home/superset/superset/utils/core.py\", line 132, in __call__
value = self.func(*args, **kwargs)
File \"/home/superset/superset/models/core.py\", line 911, in get_sqla_engine
return create_engine(url, **params)
File \"/usr/local/lib/python3.6/site-packages/sqlalchemy/engine/__init__.py\", line 435, in create_engine
return strategy.create(*args, **kwargs)
File \"/usr/local/lib/python3.6/site-packages/sqlalchemy/engine/strategies.py\", line 61, in create
entrypoint = u._get_entrypoint()
File \"/usr/local/lib/python3.6/site-packages/sqlalchemy/engine/url.py\", line 172, in _get_entrypoint
cls = registry.load(name)
File \"/usr/local/lib/python3.6/site-packages/sqlalchemy/util/langhelpers.py\", line 240, in load
\"Can't load plugin: %s:%s\" % (self.group, name)
sqlalchemy.exc.NoSuchModuleError: Can't load plugin: sqlalchemy.dialects:drill.sadrill
"}
有人能弄清楚我为什么会收到此错误吗?此外,是否有其他教程可以更好地了解如何设置 Drill 和 superset。
答案1
我认为您必须为 Drill 安装 SQLAlchemy Dialect:
git clone https://github.com/JohnOmernik/sqlalchemy-drill
cd sqlalchemy-drill
python3 setup.py install
(看https://superset.incubator.apache.org/installation.html#apache-drill)