Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[database] new, API table metadata #9002

Merged
merged 14 commits into from Jan 29, 2020

Conversation

dpgaspar
Copy link
Member

@dpgaspar dpgaspar commented Jan 23, 2020

CATEGORY

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

SUMMARY

Migrate /table/<database_id>/<table_name>/<schema>/ to /api/v1/database/<database_id>/table/<table_name>/<schema_name>/ resource.

  • Guarantees database filtering based on the user permissions
  • Full OpenAPI spec
  • Better error handling

Response spec from swagger UI:
image

ADDITIONAL INFORMATION

  • Has associated issue:
  • Changes UI
  • Requires DB Migration.
  • Confirm DB Migration upgrade and downgrade tested.
  • Introduces new feature or API
  • Removes existing feature or API

REVIEWERS

@dpgaspar dpgaspar marked this pull request as ready for review January 23, 2020 17:04
from superset.views.database.validators import sqlalchemy_uri_validator


def get_table_schema_info(
Copy link
Member Author

Choose a reason for hiding this comment

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

Not very happy with placing this here...

@dpgaspar dpgaspar changed the title [database] new, API table schema info [database] new, API table matadata Jan 23, 2020
@dpgaspar dpgaspar changed the title [database] new, API table matadata [database] new, API table metadata Jan 23, 2020
@codecov-io
Copy link

codecov-io commented Jan 24, 2020

Codecov Report

Merging #9002 into master will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##           master    #9002   +/-   ##
=======================================
  Coverage   59.15%   59.15%           
=======================================
  Files         367      367           
  Lines       11686    11686           
  Branches     2866     2866           
=======================================
  Hits         6913     6913           
  Misses       4594     4594           
  Partials      179      179

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 16b539c...651b28c. Read the comment docs.

Copy link
Member

@craig-rueda craig-rueda left a comment

Choose a reason for hiding this comment

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

LGTM

Copy link
Member

@villebro villebro left a comment

Choose a reason for hiding this comment

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

One small nit/question, other than that LGTM

superset/views/database/api.py Outdated Show resolved Hide resolved
@dpgaspar dpgaspar merged commit d5dbfc8 into apache:master Jan 29, 2020
@dpgaspar dpgaspar deleted the fix/api-superset-table branch January 29, 2020 09:51
@mistercrunch mistercrunch added 🏷️ bot A label used by `supersetbot` to keep track of which PR where auto-tagged with release labels 🚢 0.36.0 labels Feb 28, 2024
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/XL 🚢 0.36.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants