Skip to content

[db engine] Add support for Elasticsearch - #8441

Merged
dpgaspar merged 11 commits into
apache:masterfrom
preset-io:feature/elasticsearch-support
Oct 28, 2019
Merged

dpgaspar merged 11 commits into
apache:masterfrom
preset-io:feature/elasticsearch-support

Conversation

@dpgaspar

@dpgaspar dpgaspar commented Oct 24, 2019 •

Copy link
Copy Markdown
Member

CATEGORY

Choose one

  • Bug Fix
  • Enhancement (new features, refinement)
  • Refactor
  • Add tests
  • Build / Development Environment
  • Documentation

SUMMARY

Add support for Elasticsearch. Includes a specific engine spec, most work done upstream on elasticsearch-dbapi (https://github.com/preset-io/elasticsearch-dbapi) that implements a PEP-249 DBAPI and SQLAlchemy dialect that "queries" X-Pack SQL (Limited to no support for opendistro yet)

BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF

Example Dashboard:

image

SQLLab:

image

TEST PLAN

ADDITIONAL INFORMATION

REVIEWERS

@dpgaspar
dpgaspar marked this pull request as ready for review October 24, 2019 13:14
@codecov-io

codecov-io commented Oct 24, 2019 •

Copy link
Copy Markdown

Codecov Report

Merging #8441 into master will decrease coverage by 1.08%.
The diff coverage is 81.25%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #8441      +/-   ##
==========================================
- Coverage   67.61%   66.53%   -1.09%     
==========================================
  Files         448      449       +1     
  Lines       22486    22502      +16     
  Branches     2364     2364              
==========================================
- Hits        15204    14971     -233     
- Misses       7144     7393     +249     
  Partials      138      138
Impacted Files Coverage Δ
superset/db_engine_specs/elasticsearch.py 81.25% <81.25%> (ø)
superset/db_engine_specs/presto.py 22.43% <0%> (-42.49%) ⬇️
superset/db_engine_specs/pinot.py 43.33% <0%> (-26.67%) ⬇️
superset/db_engine_specs/hive.py 27.85% <0%> (-12.33%) ⬇️
superset/db_engine_specs/mssql.py 58.33% <0%> (-11.12%) ⬇️
superset/db_engine_specs/postgres.py 83.87% <0%> (-9.68%) ⬇️
superset/db_engine_specs/bigquery.py 45.07% <0%> (-8.46%) ⬇️
superset/models/sql_types/presto_sql_types.py 65.51% <0%> (-6.9%) ⬇️
superset/db_engine_specs/base.py 80.73% <0%> (-4.66%) ⬇️
superset/sql_parse.py 96.12% <0%> (-3.11%) ⬇️
... and 1 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 786d770...04fb4e1. Read the comment docs.

@villebro villebro left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Awesome! 🎉

@mistercrunch mistercrunch left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

❤️

@dpgaspar
dpgaspar requested a review from john-bodley October 26, 2019 18:26
@dpgaspar
dpgaspar merged commit a757b43 into apache:master Oct 28, 2019
@dpgaspar
dpgaspar deleted the feature/elasticsearch-support branch October 28, 2019 16:04
graceguo-supercat pushed a commit that referenced this pull request Nov 13, 2019
* [db engine] Add support for Elasticsearch
@dioptre

dioptre commented Sep 16, 2020

Copy link
Copy Markdown

Wondering if anyone managed to get this working with opendistro?

preset-io/elasticsearch-dbapi#31

@mistercrunch mistercrunch added 🏷️ bot A label used by `supersetbot` to keep track of which PR where auto-tagged with release labels 🚢 0.36.0 First shipped in 0.36.0 labels Feb 28, 2024
qfcwell pushed a commit to qfcwell/superset that referenced this pull request May 12, 2026
* [db engine] Add support for Elasticsearch
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

🏷️ bot A label used by `supersetbot` to keep track of which PR where auto-tagged with release labels size/M 🚢 0.36.0 First shipped in 0.36.0

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants