You can use Superset to query and visualize data.
- Superset 1.5.3 and later
- Dremio SQLAlchemy connector 3.0.2 and later
Supported Authentication Method
Use a personal access token (PAT) created in a Sonar project. To create one, follow the steps in the section Creating a Token. After you obtain a PAT, it is recommended that you URL-encode it. To encode it locally on your system, you can follow these steps:
- In a browser window, right-click an empty area of the page and select Inspect or Inspect Element, depending on your browser.
- In the top bar of the inspection pane, click Console.
<PAT>is the personal access token that you obtained from Dremio Cloud. The URL-encoded PAT appears in red on the next line. You can highlight it and copy it to your clipboard.
If you installed Superset according to the instructions for installing from scratch, install the Dremio SQLAlchemy Connector on the system or in the VM where Apache Superset is running. Instructions are in the sqlalchemy_dremio repository in GitHub.
Creating a Connection
If you are using a version of Superset earlier than 2.1.0, follow these steps:
- Select Data > Databases in the menu bar at the top of the screen.
- Click the Database button in the top-right corner of the screen.
If you are using version 2.1.0 or later of Superset, follow these steps:
- Click Datasets in the menu bar at the top of the screen.
- Click the plus (+) icon in the top-right corner.
- Select Data > Connect database.
In the Connect a Database dialog, follow these steps:
- Select Other from the Supported Databases field.
- In the Display Name field, name the new connection.
- In the SQLALCHEMY URI field, specify a URI that is in this format. Use an ampersand in front of each additional property that you add:
<schema>: The name of the database schema to use by default when a schema is not given in a query. Providing a schema is optional. Specifying a schema does not prevent queries from being issued for other schemas; such queries must explicitly include the schema.
<PAT>: The URL-encoded personal access token that you obtained from Dremio Cloud. See Supported Authentication Method.
[&<option>=<value>[&...]]is one or more optional properties from the SSL connection properties and Advanced properties tables below. Separate each property with an ampersand (
4. Test the connection. If the test fails, check the syntax and values in the connection URI. 5. Click Connect.
SSL Connection Properties
Use the following properties to configure SSL encryption and verification methods:
|UseEncryption||integer||Forces the client to use an SSL-encrypted connection to communicate with Sonar. Accepted value: ||true|
|disableCertificateVerification||integer||Specifies whether to verify the host certificate against the trust store. Accepted values: ||false|
|trustedCerts||string||The full path of the .pem file containing certificates trusted by a CA, for the purpose of verifying the server. If this option is not set, defaults to using the trusted CA certificates .pem file. The TLS connection fails if you do not specify a value when UseEncryption is true and disableCertificateVerification is false.||N/A|
|routing_engine||string||The engine to route queries to while a connection remains open.||N/A||No|
|routing_tag||string||The tag to be associated with all queries executed within a connection session.||N/A||No|