Repository navigation
[trino] Fix the basic Trino connector and restrict custom connectors - #4393
Merged
Merged
Conversation
…ify, trino_user, all result pages, cancel - Use basic authentication only over HTTPS and fall back to the global credentials when the options are empty - Add the ssl_verify and trino_user options and default the port from the URL scheme - Read every page of the metadata queries, quote the catalog in SHOW SCHEMAS and skip USE without a database - Fix has_more on the last page, add cancel and fix the Python 3 error handler
…ent by API clients Custom snippets let an API client choose the interface and options and so the host the server connects to. They are now disabled by default and can be enabled with [notebook] enable_custom_connectors. The RDBMS and JDBC importer builds its own custom snippets on the server and is not affected.
…e ini templates and docs
|
✅ Test files were modified. Ensure that the tests cover all relevant changes. ✅ |
Harshg999
enabled auto-merge (rebase)
October 30, 2026 07:40
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What changes are proposed in this pull request?
Fixes a set of problems in the native Trino connector (
interface=trino) so that basic Trino support works reliably, and adds an opt-in switch for API-defined custom connectors.Trino connector (
notebook/connectors/trino.py)http://the credentials are ignored with a warning instead of failing. Emptyauth_username/auth_passwordoptions fall back to the global defaults.ssl_verify(true,falseor a CA bundle path) andtrino_user(user sent to Trino, defaults to the Hue user).SHOW CATALOGS, tables, columns, schemas, sample data, explain) read all result pages. They previously read only the first page, so large results were cut.SHOW SCHEMAS FROMquotes the catalog name, andUSEis skipped when no database is given.has_moreis correct when the last fetched page still has rows to return.cancel(), which deletes the Trino next URI.ex.message.create_sessionno longer shares a mutablepropertiesdefault.[notebook] enable_custom_connectors(defaultfalse)customlets an API client choose the interface and options, so the host the Hue server connects to. It is now disabled by default and can be enabled by an admin.hue.iniare not affected.customsnippets on the server and bypasses the flag.customsnippets needenable_custom_connectors=true.Docs and config
hue.iniandpseudo-distributed.ini.tmpland the connectors documentation. Added the new flag.How was this patch tested?
notebookandindexer, including new tests for auth,ssl_verify,trino_user, paging,cancel, the gate and the interpreter config. Added a jest test forsqlUtils.backTickIfNeededwith the trino dialect (6 tests).ruffis clean on the changed files.trinodb/trino:476through the notebook API:USER_CANCELEDon the server)ssl_verifyasfalse, as a CA bundle path and as the default (refused for a self-signed certificate),auth_password_script, and a wrong password (clean 401)trino_userhttp://: ignored with a warningNot covered: Kerberos, JWT and OAuth (not supported by this connector) and the browser UI itself.