Connect Superset to StarTree Cloud
To connect Superset to StarTree Cloud, do the following:
- Install prerequisites
- Obtain your Pinot API token, username, and password
- Obtain your Pinot broker and controller URL
- Format your SQLAlchemy URI
- Add the SQLAlchemy URI in Superset
Prerequisites
- Have a running Pinot cluster. Sign up for a StarTree Cloud trial (opens in a new tab) to get up and running on Pinot.
- Have a running Superset instance. For more information about how install and deploy Superset, see What is Apache Superset? (opens in a new tab).
- Make sure your Superset instance has the Pinot database driver installed, which is compatible with StarTree Cloud. For more information, see how to install a database driver for Superset (opens in a new tab).
Obtain your API token, username, and password
To obtain your API token, see Generate an API token, and then to convert your API token to a username and password, see the Superset and Trino users section on the same page.
Obtain your Pinot broker and controller URL
- In StarTree Cloud, go to Data Manager
- Click on any of the datasets
- Copy the "Broker URL". For example your broker URL may look like https://broker.pinot.[Your_URL].startree.cloud:443/query/sql (opens in a new tab)
- Controller URL can be obtained by removing the "broker." from the Broker URL. For the Broker URL above, the Controller URL will look like https://pinot.[Your_URL].startree.cloud:443/ (opens in a new tab)
Format your SQLAlchemy URI
- Encode the Pinot controller URL in UTF-8 format using urlencoder.org (opens in a new tab) or similar site.
- Use the encoded UTF-8 format in the SQLAlchemy URI. See the following example for the correct SQLAlchemy URL format:
Example
- username is
user
- password is
pass
- broker url is
https://broker.pinot.example:443
- controller url is
https://controller.pinot.example:443
StarTree Serverless Trial Users
Copy the name of the workspace from top-left corner of the screen
The url is pinot+https://user:pass@broker.pinot.example:443/query/sql?controller=https%3A%2F%2Fcontroller.pinot.example%3A443%2F&database=<Your Workspace>&verify_ssl=true
StarTree Customers
The url is pinot+https://user:pass@broker.pinot.example:443/query/sql?controller=https%3A%2F%2Fcontroller.pinot.example%3A443%2Fverify_ssl=true
Add the SQLAlchemy URI in Superset
- In Superset, click
+
in the top right, and then select the Connect a database option. - Select Apache Pinot (if not in the list, see instructions in Prerequisites to download the Pinot database driver).
- Paste the SQLAlchemy URI.