feat: API endpoint to validate databases using separate parameters#14420
Conversation
There was a problem hiding this comment.
No need, raising exceptions in the API get logged by the error handler:
superset/superset/views/base.py
Lines 350 to 361 in 21cf12a
a5ffd8a to
6b9828f
Compare
Codecov Report
@@ Coverage Diff @@
## master #14420 +/- ##
==========================================
- Coverage 77.40% 77.38% -0.02%
==========================================
Files 958 959 +1
Lines 48326 48450 +124
Branches 5677 5680 +3
==========================================
+ Hits 37405 37493 +88
- Misses 10721 10757 +36
Partials 200 200
Flags with carried forward coverage won't be shown. Click here to find out more.
Continue to review full report at Codecov.
|
c5a9205 to
db8afac
Compare
| # Default row limit for SQL Lab queries. Is overridden by setting a new limit in | ||
| # the SQL Lab UI | ||
| DEFAULT_SQLLAB_LIMIT = 1000 | ||
| DEFAULT_SQLLAB_LIMIT = 10000 |
There was a problem hiding this comment.
@betodealmeida any reason for the change from 1,000 to 10,000? We have had a number of employees mention that 10,000 overloads their local storage use and breaks Chrome and thus I'm unsure if the default of 10,000 makes sense.
There was a problem hiding this comment.
I'm not sure, let me change the default back. Sorry for that!
…pache#14420) * feat: new endpoint for validating database parameters * Rebase * Remove broken tests
…pache#14420) * feat: new endpoint for validating database parameters * Rebase * Remove broken tests
…pache#14420) * feat: new endpoint for validating database parameters * Rebase * Remove broken tests
…pache#14420) * feat: new endpoint for validating database parameters * Rebase * Remove broken tests
SUMMARY
This PR adds a new endpoint at
api/v1/database/validate_parametersfor validating separate parameters when adding/editing a database. With this flow, users can add databases by passing DB-specific parameters (username, password, host, port, etc.) instead of the full SQLAlchemy URI.BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF
N/A
TEST PLAN
Added unit tests for the new command
ValidateDatabaseParametersCommand, as well as the new API.ADDITIONAL INFORMATION