geido commented on a change in pull request #17593:
URL: https://github.com/apache/superset/pull/17593#discussion_r760155330



##########
File path: docs/src/pages/docs/Connecting to Databases/trino.mdx
##########
@@ -8,20 +8,77 @@ version: 1
 
 ## Trino
 
-Supported trino version 352 and higher
-
-The [sqlalchemy-trino](https://pypi.org/project/sqlalchemy-trino/) library is 
the recommended way to connect to Trino through SQLAlchemy.
-
-The expected connection string is formatted as follows:
+SuperSet supports Trino >=352 via SQLAlchemy by using 
[sqlalchemy-trino](https://pypi.org/project/sqlalchemy-trino/) library.
 
+### Connection String
+The connection string format is as follows:
 ```
 trino://{username}:{password}@{hostname}:{port}/{catalog}
 ```
-If you are running trino with docker on local machine please use the following 
connection URL
 
+If you are running Trino with docker on local machine, please use the 
following connection URL
 ```
 trino://[email protected]:8080
 ```
 
-Reference:
-[Trino-Superset-Podcast](https://trino.io/episodes/12.html)
+### Authentications
+#### 1. Basic Authentication
+You can provide `username`/`password` in connection string or in `Secure 
Extra` field at `Advanced / Security`
+* In Connection String
+    ```
+    trino://{username}:{password}@{hostname}:{port}/{catalog}
+    ```
+
+* In `Secure Extra` field
+    ```json
+    {
+        "auth_method": "basic",
+        "auth_params": {
+            "username": "<username>",
+            "password": "<password>"
+        }
+    }
+    ```
+
+NOTE: if both are provided, `Secure Extra` always take higher priority.

Review comment:
       ```suggestion
   NOTE: if both are provided, `Secure Extra` always takes higher priority.
   ```

##########
File path: docs/src/pages/docs/Connecting to Databases/trino.mdx
##########
@@ -8,20 +8,77 @@ version: 1
 
 ## Trino
 
-Supported trino version 352 and higher
-
-The [sqlalchemy-trino](https://pypi.org/project/sqlalchemy-trino/) library is 
the recommended way to connect to Trino through SQLAlchemy.
-
-The expected connection string is formatted as follows:
+SuperSet supports Trino >=352 via SQLAlchemy by using 
[sqlalchemy-trino](https://pypi.org/project/sqlalchemy-trino/) library.

Review comment:
       ```suggestion
   SuperSet supports Trino >=352 via SQLAlchemy by using the 
[sqlalchemy-trino](https://pypi.org/project/sqlalchemy-trino/) library.
   ```

##########
File path: docs/src/pages/docs/Connecting to Databases/trino.mdx
##########
@@ -8,20 +8,77 @@ version: 1
 
 ## Trino
 
-Supported trino version 352 and higher
-
-The [sqlalchemy-trino](https://pypi.org/project/sqlalchemy-trino/) library is 
the recommended way to connect to Trino through SQLAlchemy.
-
-The expected connection string is formatted as follows:
+SuperSet supports Trino >=352 via SQLAlchemy by using 
[sqlalchemy-trino](https://pypi.org/project/sqlalchemy-trino/) library.
 
+### Connection String
+The connection string format is as follows:
 ```
 trino://{username}:{password}@{hostname}:{port}/{catalog}
 ```
-If you are running trino with docker on local machine please use the following 
connection URL
 
+If you are running Trino with docker on local machine, please use the 
following connection URL
 ```
 trino://[email protected]:8080
 ```
 
-Reference:
-[Trino-Superset-Podcast](https://trino.io/episodes/12.html)
+### Authentications
+#### 1. Basic Authentication
+You can provide `username`/`password` in connection string or in `Secure 
Extra` field at `Advanced / Security`
+* In Connection String
+    ```
+    trino://{username}:{password}@{hostname}:{port}/{catalog}
+    ```
+
+* In `Secure Extra` field
+    ```json
+    {
+        "auth_method": "basic",
+        "auth_params": {
+            "username": "<username>",
+            "password": "<password>"
+        }
+    }
+    ```
+
+NOTE: if both are provided, `Secure Extra` always take higher priority.
+
+#### 2. Kerberos Authentication
+In `Secure Extra` field, config as following example:
+```json
+{
+    "auth_method": "kerberos",
+    "auth_params": {
+        "service_name": "SuperSet",
+        "config": "/path/to/krb5.config",
+        ...
+    }
+}
+```
+
+All fields in `auth_params` are passed directly to 
[`KerberosAuthentication`](https://github.com/trinodb/trino-python-client/blob/0.306.0/trino/auth.py#L40)
 class.

Review comment:
       ```suggestion
   All fields in `auth_params` are passed directly to the 
[`KerberosAuthentication`](https://github.com/trinodb/trino-python-client/blob/0.306.0/trino/auth.py#L40)
 class.
   ```




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to