docs: various improvements across the docs (#28285)

This commit is contained in:
Maxime Beauchemin 2024-05-03 15:27:40 -07:00 committed by GitHub
parent 517f254726
commit 49231da42f
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
49 changed files with 3803 additions and 3775 deletions

View File

@ -47,7 +47,7 @@ repos:
hooks:
- id: check-docstring-first
- id: check-added-large-files
exclude: \.(geojson)$
exclude: ^.*\.(geojson)$|^docs/static/img/screenshots/.*
- id: check-yaml
exclude: ^helm/superset/templates/
- id: debug-statements

100
README.md
View File

@ -1,3 +1,7 @@
---
hide_title: true
sidebar_position: 1
---
<!--
Licensed to the Apache Software Foundation (ASF) under one
or more contributor license agreements. See the NOTICE file
@ -30,12 +34,14 @@ under the License.
<picture width="500">
<source
width="600"
media="(prefers-color-scheme: dark)"
src="https://github.com/apache/superset/raw/master/superset-frontend/src/assets/branding/superset-logo-horiz-apache-dark.png"
src="https://superset.apache.org/img/superset-logo-horiz-dark.svg"
alt="Superset logo (dark)"
/>
<img
src="https://github.com/apache/superset/raw/master/superset-frontend/src/assets/branding/superset-logo-horiz-apache.png"
width="600"
src="https://superset.apache.org/img/superset-logo-horiz-apache.svg"
alt="Superset logo (light)"
/>
</picture>
@ -45,11 +51,11 @@ A modern, enterprise-ready business intelligence web application.
[**Why Superset?**](#why-superset) |
[**Supported Databases**](#supported-databases) |
[**Installation and Configuration**](#installation-and-configuration) |
[**Release Notes**](RELEASING/README.md#release-notes-for-recent-releases) |
[**Release Notes**](https://github.com/apache/superset/blob/master/RELEASING/README.md#release-notes-for-recent-releases) |
[**Get Involved**](#get-involved) |
[**Contributor Guide**](#contributor-guide) |
[**Resources**](#resources) |
[**Organizations Using Superset**](RESOURCES/INTHEWILD.md)
[**Organizations Using Superset**](https://github.com/apache/superset/blob/master/RESOURCES/INTHEWILD.md)
## Why Superset?
@ -77,19 +83,19 @@ https://superset.staged.apache.org/superset-video-4k.mp4
**Large Gallery of Visualizations**
<kbd><img title="Gallery" src="superset-frontend/src/assets/images/screenshots/gallery.jpg"/></kbd><br/>
<kbd><img title="Gallery" src="https://superset.apache.org/img/screenshots/gallery.jpg"/></kbd><br/>
**Craft Beautiful, Dynamic Dashboards**
<kbd><img title="View Dashboards" src="superset-frontend/src/assets/images/screenshots/slack_dash.jpg"/></kbd><br/>
<kbd><img title="View Dashboards" src="https://superset.apache.org/img/screenshots/slack_dash.jpg"/></kbd><br/>
**No-Code Chart Builder**
<kbd><img title="Slice & dice your data" src="superset-frontend/src/assets/images/screenshots/explore.jpg"/></kbd><br/>
<kbd><img title="Slice & dice your data" src="https://superset.apache.org/img/screenshots/explore.jpg"/></kbd><br/>
**Powerful SQL Editor**
<kbd><img title="SQL Lab" src="superset-frontend/src/assets/images/screenshots/sql_lab.jpg"/></kbd><br/>
<kbd><img title="SQL Lab" src="https://superset.apache.org/img/screenshots/sql_lab.jpg"/></kbd><br/>
## Supported Databases
@ -98,39 +104,39 @@ Superset can query data from any SQL-speaking datastore or data engine (Presto,
Here are some of the major database solutions that are supported:
<p align="center">
<img src="superset-frontend/src/assets/images/redshift.png" alt="redshift" border="0" width="200" height="80"/>
<img src="superset-frontend/src/assets/images/google-biquery.png" alt="google-biquery" border="0" width="200" height="80"/>
<img src="superset-frontend/src/assets/images/snowflake.png" alt="snowflake" border="0" width="200" height="80"/>
<img src="superset-frontend/src/assets/images/trino.png" alt="trino" border="0" width="200" height="80"/>
<img src="superset-frontend/src/assets/images/presto.png" alt="presto" border="0" width="200" height="80"/>
<img src="superset-frontend/src/assets/images/databricks.png" alt="databricks" border="0" width="200" height="80" />
<img src="superset-frontend/src/assets/images/druid.png" alt="druid" border="0" width="200" height="80" />
<img src="superset-frontend/src/assets/images/firebolt.png" alt="firebolt" border="0" width="200" height="80" />
<img src="superset-frontend/src/assets/images/timescale.png" alt="timescale" border="0" width="200" height="80" />
<img src="superset-frontend/src/assets/images/rockset.png" alt="rockset" border="0" width="200" height="80" />
<img src="superset-frontend/src/assets/images/postgresql.png" alt="postgresql" border="0" width="200" height="80" />
<img src="superset-frontend/src/assets/images/mysql.png" alt="mysql" border="0" width="200" height="80" />
<img src="superset-frontend/src/assets/images/mssql-server.png" alt="mssql-server" border="0" width="200" height="80" />
<img src="superset-frontend/src/assets/images/db2.png" alt="db2" border="0" width="200" height="80" />
<img src="superset-frontend/src/assets/images/sqlite.png" alt="sqlite" border="0" width="200" height="80" />
<img src="superset-frontend/src/assets/images/sybase.png" alt="sybase" border="0" width="200" height="80" />
<img src="superset-frontend/src/assets/images/mariadb.png" alt="mariadb" border="0" width="200" height="80" />
<img src="superset-frontend/src/assets/images/vertica.png" alt="vertica" border="0" width="200" height="80" />
<img src="superset-frontend/src/assets/images/oracle.png" alt="oracle" border="0" width="200" height="80" />
<img src="superset-frontend/src/assets/images/firebird.png" alt="firebird" border="0" width="200" height="80" />
<img src="superset-frontend/src/assets/images/greenplum.png" alt="greenplum" border="0" width="200" height="80" />
<img src="superset-frontend/src/assets/images/clickhouse.png" alt="clickhouse" border="0" width="200" height="80" />
<img src="superset-frontend/src/assets/images/exasol.png" alt="exasol" border="0" width="200" height="80" />
<img src="superset-frontend/src/assets/images/monet-db.png" alt="monet-db" border="0" width="200" height="80" />
<img src="superset-frontend/src/assets/images/apache-kylin.png" alt="apache-kylin" border="0" width="200" height="80"/>
<img src="superset-frontend/src/assets/images/hologres.png" alt="hologres" border="0" width="200" height="80"/>
<img src="superset-frontend/src/assets/images/netezza.png" alt="netezza" border="0" width="200" height="80"/>
<img src="superset-frontend/src/assets/images/pinot.png" alt="pinot" border="0" width="200" height="80"/>
<img src="superset-frontend/src/assets/images/teradata.png" alt="teradata" border="0" width="200" height="80"/>
<img src="superset-frontend/src/assets/images/yugabyte.png" alt="yugabyte" border="0" width="200" height="80"/>
<img src="superset-frontend/src/assets/images/databend.png" alt="databend" border="0" width="200" height="80"/>
<img src="superset-frontend/src/assets/images/starrocks.png" alt="starrocks" border="0" width="200" height="80"/>
<img src="superset-frontend/src/assets/images/doris.png" alt="doris" border="0" width="200" height="80"/>
<img src="https://superset.apache.org/img/databases/redshift.png" alt="redshift" border="0" width="200" height="80"/>
<img src="https://superset.apache.org/img/databases/google-biquery.png" alt="google-biquery" border="0" width="200" height="80"/>
<img src="https://superset.apache.org/img/databases/snowflake.png" alt="snowflake" border="0" width="200" height="80"/>
<img src="https://superset.apache.org/img/databases/trino.png" alt="trino" border="0" width="200" height="80"/>
<img src="https://superset.apache.org/img/databases/presto.png" alt="presto" border="0" width="200" height="80"/>
<img src="https://superset.apache.org/img/databases/databricks.png" alt="databricks" border="0" width="200" height="80" />
<img src="https://superset.apache.org/img/databases/druid.png" alt="druid" border="0" width="200" height="80" />
<img src="https://superset.apache.org/img/databases/firebolt.png" alt="firebolt" border="0" width="200" height="80" />
<img src="https://superset.apache.org/img/databases/timescale.png" alt="timescale" border="0" width="200" height="80" />
<img src="https://superset.apache.org/img/databases/rockset.png" alt="rockset" border="0" width="200" height="80" />
<img src="https://superset.apache.org/img/databases/postgresql.png" alt="postgresql" border="0" width="200" height="80" />
<img src="https://superset.apache.org/img/databases/mysql.png" alt="mysql" border="0" width="200" height="80" />
<img src="https://superset.apache.org/img/databases/mssql-server.png" alt="mssql-server" border="0" width="200" height="80" />
<img src="https://superset.apache.org/img/databases/db2.png" alt="db2" border="0" width="200" height="80" />
<img src="https://superset.apache.org/img/databases/sqlite.png" alt="sqlite" border="0" width="200" height="80" />
<img src="https://superset.apache.org/img/databases/sybase.png" alt="sybase" border="0" width="200" height="80" />
<img src="https://superset.apache.org/img/databases/mariadb.png" alt="mariadb" border="0" width="200" height="80" />
<img src="https://superset.apache.org/img/databases/vertica.png" alt="vertica" border="0" width="200" height="80" />
<img src="https://superset.apache.org/img/databases/oracle.png" alt="oracle" border="0" width="200" height="80" />
<img src="https://superset.apache.org/img/databases/firebird.png" alt="firebird" border="0" width="200" height="80" />
<img src="https://superset.apache.org/img/databases/greenplum.png" alt="greenplum" border="0" width="200" height="80" />
<img src="https://superset.apache.org/img/databases/clickhouse.png" alt="clickhouse" border="0" width="200" height="80" />
<img src="https://superset.apache.org/img/databases/exasol.png" alt="exasol" border="0" width="200" height="80" />
<img src="https://superset.apache.org/img/databases/monet-db.png" alt="monet-db" border="0" width="200" height="80" />
<img src="https://superset.apache.org/img/databases/apache-kylin.png" alt="apache-kylin" border="0" width="80"/>
<img src="https://superset.apache.org/img/databases/hologres.png" alt="hologres" border="0" width="80"/>
<img src="https://superset.apache.org/img/databases/netezza.png" alt="netezza" border="0" width="80"/>
<img src="https://superset.apache.org/img/databases/pinot.png" alt="pinot" border="0" width="200" height="80"/>
<img src="https://superset.apache.org/img/databases/teradata.png" alt="teradata" border="0" width="200" height="80"/>
<img src="https://superset.apache.org/img/databases/yugabyte.png" alt="yugabyte" border="0" width="200" height="80"/>
<img src="https://superset.apache.org/img/databases/databend.png" alt="databend" border="0" width="200" height="80"/>
<img src="https://superset.apache.org/img/databases/starrocks.png" alt="starrocks" border="0" width="200" height="80"/>
<img src="https://superset.apache.org/img/databases/doris.png" alt="doris" border="0" width="200" height="80"/>
</p>
**A more comprehensive list of supported databases** along with the configuration instructions can be found [here](https://superset.apache.org/docs/configuration/databases).
@ -159,9 +165,9 @@ how to set up a development environment.
## Resources
- [Superset "In the Wild"](RESOURCES/INTHEWILD.md) - open a PR to add your org to the list!
- [Feature Flags](RESOURCES/FEATURE_FLAGS.md) - the status of Superset's Feature Flags.
- [Standard Roles](RESOURCES/STANDARD_ROLES.md) - How RBAC permissions map to roles.
- [Superset "In the Wild"](https://github.com/apache/superset/blob/master/RESOURCES/INTHEWILD.md) - open a PR to add your org to the list!
- [Feature Flags](https://github.com/apache/superset/blob/master/RESOURCES/FEATURE_FLAGS.md) - the status of Superset's Feature Flags.
- [Standard Roles](https://github.com/apache/superset/blob/master/RESOURCES/STANDARD_ROLES.md) - How RBAC permissions map to roles.
- [Superset Wiki](https://github.com/apache/superset/wiki) - Tons of additional community resources: best practices, community content and other information.
- [Superset SIPs](https://github.com/orgs/apache/projects/170) - The status of Superset's SIPs (Superset Improvement Proposals) for both consensus and implementation status.
@ -198,10 +204,10 @@ Understanding the Superset Points of View
- [Superset API](https://superset.apache.org/docs/rest-api)
## Repo Activity
<a href="https://next.ossinsight.io/widgets/official/compose-last-28-days-stats?repo_id=39464018" target="_blank" style="display: block" align="center">
<a href="https://next.ossinsight.io/widgets/official/compose-last-28-days-stats?repo_id=39464018" target="_blank" align="center">
<picture>
<source media="(prefers-color-scheme: dark)" srcset="https://next.ossinsight.io/widgets/official/compose-last-28-days-stats/thumbnail.png?repo_id=39464018&image_size=auto&color_scheme=dark" width="655" height="auto">
<img alt="Performance Stats of apache/superset - Last 28 days" src="https://next.ossinsight.io/widgets/official/compose-last-28-days-stats/thumbnail.png?repo_id=39464018&image_size=auto&color_scheme=light" width="655" height="auto">
<source media="(prefers-color-scheme: dark)" srcset="https://next.ossinsight.io/widgets/official/compose-last-28-days-stats/thumbnail.png?repo_id=39464018&image_size=auto&color_scheme=dark" width="655" height="auto" />
<img alt="Performance Stats of apache/superset - Last 28 days" src="https://next.ossinsight.io/widgets/official/compose-last-28-days-stats/thumbnail.png?repo_id=39464018&image_size=auto&color_scheme=light" width="655" height="auto" />
</picture>
</a>

BIN
databases/trino.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 10 KiB

3
docs/.gitignore vendored
View File

@ -20,3 +20,6 @@ yarn-debug.log*
yarn-error.log*
docs/.zshrc
# Gets copies from the root of the project at build time (yarn start / yarn build)
docs/intro.md

View File

@ -5,7 +5,7 @@ sidebar_position: 2
version: 2
---
## Alerts and Reports
# Alerts and Reports
Users can configure automated alerts and reports to send dashboards or charts to an email recipient or Slack channel.
@ -14,11 +14,11 @@ Users can configure automated alerts and reports to send dashboards or charts to
Alerts and reports are disabled by default. To turn them on, you need to do some setup, described here.
### Requirements
## Requirements
#### Commons
### Commons
##### In your `superset_config.py` or `superset_config_docker.py`
#### In your `superset_config.py` or `superset_config_docker.py`
- `"ALERT_REPORTS"` [feature flag](/docs/configuration/configuring-superset#feature-flags) must be turned to True.
- `beat_schedule` in CeleryConfig must contain schedule for `reports.scheduler`.
@ -26,11 +26,11 @@ Alerts and reports are disabled by default. To turn them on, you need to do some
- emails: `SMTP_*` settings
- Slack messages: `SLACK_API_TOKEN`
###### Disable dry-run mode
##### Disable dry-run mode
Screenshots will be taken but no messages actually sent as long as `ALERT_REPORTS_NOTIFICATION_DRY_RUN = True`, its default value in `docker/pythonpath_dev/superset_config.py`. To disable dry-run mode and start receiving email/Slack notifications, set `ALERT_REPORTS_NOTIFICATION_DRY_RUN` to `False` in [superset config](https://github.com/apache/superset/blob/master/docker/pythonpath_dev/superset_config.py).
##### In your `Dockerfile`
#### In your `Dockerfile`
- You must install a headless browser, for taking screenshots of the charts and dashboards. Only Firefox and Chrome are currently supported.
> If you choose Chrome, you must also change the value of `WEBDRIVER_TYPE` to `"chrome"` in your `superset_config.py`.
@ -43,7 +43,7 @@ You can either install and configure the headless browser - see "Custom Dockerfi
*Note*: In this context, a "dev image" is the same application software as its corresponding non-dev image, just bundled with additional tools. So an image like `3.1.0-dev` is identical to `3.1.0` when it comes to stability, functionality, and running in production. The actual "in-development" versions of Superset - cutting-edge and unstable - are not tagged with version numbers on Docker Hub and will display version `0.0.0-dev` within the Superset UI.
#### Slack integration
### Slack integration
To send alerts and reports to Slack channels, you need to create a new Slack Application on your workspace.
@ -61,14 +61,14 @@ To send alerts and reports to Slack channels, you need to create a new Slack App
Note: when you configure an alert or a report, the Slack channel list takes channel names without the leading '#' e.g. use `alerts` instead of `#alerts`.
#### Kubernetes-specific
### Kubernetes-specific
- You must have a `celery beat` pod running. If you're using the chart included in the GitHub repository under [helm/superset](https://github.com/apache/superset/tree/master/helm/superset), you need to put `supersetCeleryBeat.enabled = true` in your values override.
- You can see the dedicated docs about [Kubernetes installation](/docs/installation/kubernetes) for more details.
#### Docker Compose specific
### Docker Compose specific
##### You must have in your `docker-compose.yml`
#### You must have in your `docker-compose.yml`
- A Redis message broker
- PostgreSQL DB instead of SQLlite
@ -195,14 +195,14 @@ Please refer to `ExecutorType` in the codebase for other executor types.
its default value of `http://0.0.0.0:8080/`.
### Custom Dockerfile
## Custom Dockerfile
If you're running the dev version of a released Superset image, like `apache/superset:3.1.0-dev`, you should be set with the above.
But if you're building your own image, or starting with a non-dev version, a webdriver (and headless browser) is needed to capture screenshots of the charts and dashboards which are then sent to the recipient.
Here's how you can modify your Dockerfile to take the screenshots either with Firefox or Chrome.
#### Using Firefox
### Using Firefox
```docker
FROM apache/superset:3.1.0
@ -223,7 +223,7 @@ RUN pip install --no-cache gevent psycopg2 redis
USER superset
```
#### Using Chrome
### Using Chrome
```docker
FROM apache/superset:3.1.0
@ -248,21 +248,21 @@ USER superset
Don't forget to set `WEBDRIVER_TYPE` and `WEBDRIVER_OPTION_ARGS` in your config if you use Chrome.
### Troubleshooting
## Troubleshooting
There are many reasons that reports might not be working. Try these steps to check for specific issues.
#### Confirm feature flag is enabled and you have sufficient permissions
### Confirm feature flag is enabled and you have sufficient permissions
If you don't see "Alerts & Reports" under the *Manage* section of the Settings dropdown in the Superset UI, you need to enable the `ALERT_REPORTS` feature flag (see above). Enable another feature flag and check to see that it took effect, to verify that your config file is getting loaded.
Log in as an admin user to ensure you have adequate permissions.
#### Check the logs of your Celery worker
### Check the logs of your Celery worker
This is the best source of information about the problem. In a docker compose deployment, you can do this with a command like `docker logs superset_worker --since 1h`.
#### Check web browser and webdriver installation
### Check web browser and webdriver installation
To take a screenshot, the worker visits the dashboard or chart using a headless browser, then takes a screenshot. If you are able to send a chart as CSV or text but can't send as PNG, your problem may lie with the browser.
@ -270,7 +270,7 @@ Superset docker images that have a tag ending with `-dev` have the Firefox headl
If you are handling the installation of that software on your own, or wish to use Chromium instead, do your own verification to ensure that the headless browser opens successfully in the worker environment.
#### Send a test email
### Send a test email
One symptom of an invalid connection to an email server is receiving an error of `[Errno 110] Connection timed out` in your logs when the report tries to send.
@ -301,7 +301,7 @@ Possible fixes:
- Some cloud hosts disable outgoing unauthenticated SMTP email to prevent spam. For instance, [Azure blocks port 25 by default on some machines](https://learn.microsoft.com/en-us/azure/virtual-network/troubleshoot-outbound-smtp-connectivity). Enable that port or use another sending method.
- Use another set of SMTP credentials that you verify works in this setup.
#### Browse to your report from the worker
### Browse to your report from the worker
The worker may be unable to reach the report. It will use the value of `WEBDRIVER_BASEURL` to browse to the report. If that route is invalid, or presents an authentication challenge that the worker can't pass, the report screenshot will fail.
@ -309,7 +309,7 @@ Check this by attempting to `curl` the URL of a report that you see in the error
In a deployment with authentication measures enabled like HTTPS and Single Sign-On, it may make sense to have the worker navigate directly to the Superset application running in the same location, avoiding the need to sign in. For instance, you could use `WEBDRIVER_BASEURL="http://superset_app:8088"` for a docker compose deployment, and set `"force_https": False,` in your `TALISMAN_CONFIG`.
### Scheduling Queries as Reports
## Scheduling Queries as Reports
You can optionally allow your users to schedule queries directly in SQL Lab. This is done by adding
extra metadata to saved queries, which are then picked up by an external scheduled (like

View File

@ -5,9 +5,9 @@ sidebar_position: 4
version: 1
---
## Async Queries via Celery
# Async Queries via Celery
### Celery
## Celery
On large analytic databases, its common to run queries that execute for minutes or hours. To enable
support for long running queries that execute beyond the typical web requests timeout (30-60
@ -89,7 +89,7 @@ issues arise. Please clear your existing results cache store when upgrading an e
- SQL Lab will _only run your queries asynchronously if_ you enable **Asynchronous Query Execution**
in your database settings (Sources > Databases > Edit record).
### Celery Flower
## Celery Flower
Flower is a web based tool for monitoring the Celery cluster which you can install from pip:

View File

@ -5,7 +5,7 @@ sidebar_position: 3
version: 1
---
## Caching
# Caching
Superset uses [Flask-Caching](https://flask-caching.readthedocs.io/) for caching purposes.
Flask-Caching supports various caching backends, including Redis (recommended), Memcached,
@ -33,7 +33,7 @@ FILTER_STATE_CACHE_CONFIG = {
}
```
### Dependencies
## Dependencies
In order to use dedicated cache stores, additional python libraries must be installed
@ -43,7 +43,7 @@ In order to use dedicated cache stores, additional python libraries must be inst
These libraries can be installed using pip.
### Fallback Metastore Cache
## Fallback Metastore Cache
Note, that some form of Filter State and Explore caching are required. If either of these caches
are undefined, Superset falls back to using a built-in cache that stores data in the metadata
@ -60,7 +60,7 @@ DATA_CACHE_CONFIG = {
}
```
### Chart Cache Timeout
## Chart Cache Timeout
The cache timeout for charts may be overridden by the settings for an individual chart, dataset, or
database. Each of these configurations will be checked in order before falling back to the default
@ -69,7 +69,7 @@ value defined in `DATA_CACHE_CONFIG`.
Note, that by setting the cache timeout to `-1`, caching for charting data can be disabled, either
per chart, dataset or database, or by default if set in `DATA_CACHE_CONFIG`.
### SQL Lab Query Results
## SQL Lab Query Results
Caching for SQL Lab query results is used when async queries are enabled and is configured using
`RESULTS_BACKEND`.
@ -79,7 +79,7 @@ instead requires a cachelib object.
See [Async Queries via Celery](/docs/configuration/async-queries-celery) for details.
### Caching Thumbnails
## Caching Thumbnails
This is an optional feature that can be turned on by activating its [feature flag](/docs/configuration/configuring-superset#feature-flags) on config:

View File

@ -5,28 +5,40 @@ sidebar_position: 1
version: 1
---
## Configuring Superset
# Configuring Superset
### Configuration
## superset_config.py
To configure your application, you need to create a file `superset_config.py`. Add this file to your
Superset exposes hundreds of configurable parameters through its
[config.py module](https://github.com/apache/superset/blob/master/superset/config.py). The
variables and objects exposed act as a public interface of the bulk of what you may want
to configure, alter and interface with. In this python module, you'll find all these
parameters, sensible defaults, as well as rich documentation in the form of comments
`PYTHONPATH` or create an environment variable `SUPERSET_CONFIG_PATH` specifying the full path of the `superset_config.py`.
To configure your application, you need to create you own configuration module, which
will allow you to override few or many of these parameters. Instead of altering the core module,
You'll want to define your own module (typically a file named `superset_config.py`.
Add this file to your `PYTHONPATH` or create an environment variable
`SUPERSET_CONFIG_PATH` specifying the full path of the `superset_config.py`.
For example, if deploying on Superset directly on a Linux-based system where your `superset_config.py` is under `/app` directory, you can run:
For example, if deploying on Superset directly on a Linux-based system where your
`superset_config.py` is under `/app` directory, you can run:
```bash
export SUPERSET_CONFIG_PATH=/app/superset_config.py
```
If you are using your own custom Dockerfile with official Superset image as base image, then you can add your overrides as shown below:
If you are using your own custom Dockerfile with official Superset image as base image,
then you can add your overrides as shown below:
```bash
COPY --chown=superset superset_config.py /app/
ENV SUPERSET_CONFIG_PATH /app/superset_config.py
```
Docker compose deployments handle application configuration differently. See [https://github.com/apache/superset/tree/master/docker#readme](https://github.com/apache/superset/tree/master/docker#readme) for details.
Docker compose deployments handle application configuration differently using specific conventions..
Refer to the [docker-compose tips & configuration](/docs/installation/docker-compose#docker-compose-tips--configuration)
for details.
The following is an example of just a few of the parameters you can set in your `superset_config.py` file:
@ -63,33 +75,39 @@ WTF_CSRF_TIME_LIMIT = 60 * 60 * 24 * 365
MAPBOX_API_KEY = ''
```
All the parameters and default values defined in
[https://github.com/apache/superset/blob/master/superset/config.py](https://github.com/apache/superset/blob/master/superset/config.py)
:::tip
Note that it is typical to copy and paste [only] the portions of the
core [superset/config.py](https://github.com/apache/superset/blob/master/superset/config.py) that
you want to alter, along with the related comments into your own `superset_config.py` file.
:::
All the parameters and default values defined
in [superset/config.py](https://github.com/apache/superset/blob/master/superset/config.py)
can be altered in your local `superset_config.py`. Administrators will want to read through the file
to understand what can be configured locally as well as the default values in place.
Since `superset_config.py` acts as a Flask configuration module, it can be used to alter the
settings Flask itself, as well as Flask extensions like `flask-wtf`, `flask-caching`, `flask-migrate`,
and `flask-appbuilder`. Flask App Builder, the web framework used by Superset, offers many
settings Flask itself, as well as Flask extensions that Superset bundles like
`flask-wtf`, `flask-caching`, `flask-migrate`,
and `flask-appbuilder`. Each one of these extensions offers intricate configurability.
Flask App Builder, the web framework used by Superset, also offers many
configuration settings. Please consult the
[Flask App Builder Documentation](https://flask-appbuilder.readthedocs.org/en/latest/config.html)
for more information on how to configure it.
Make sure to change:
You'll want to change:
- `SQLALCHEMY_DATABASE_URI`: by default it is stored at ~/.superset/superset.db
- `SECRET_KEY`: to a long random string
If you need to exempt endpoints from CSRF (e.g. if you are running a custom auth postback endpoint),
you can add the endpoints to `WTF_CSRF_EXEMPT_LIST`:
- `SQLALCHEMY_DATABASE_URI`: that by default points to sqlite database located at
~/.superset/superset.db
```
WTF_CSRF_EXEMPT_LIST = []
```
### Specifying a SECRET_KEY
## Specifying a SECRET_KEY
#### Adding an initial SECRET_KEY
### Adding an initial SECRET_KEY
Superset requires a user-specified SECRET_KEY to start up. This requirement was [added in version 2.1.0 to force secure configurations](https://preset.io/blog/superset-security-update-default-secret_key-vulnerability/). Add a strong SECRET_KEY to your `superset_config.py` file like:
@ -104,7 +122,7 @@ This key will be used for securely signing session cookies and encrypting sensit
Your deployment must use a complex, unique key.
:::
#### Rotating to a newer SECRET_KEY
### Rotating to a newer SECRET_KEY
If you wish to change your existing SECRET_KEY, add the existing SECRET_KEY to your `superset_config.py` file as
`PREVIOUS_SECRET_KEY = `and provide your new key as `SECRET_KEY =`. You can find your current SECRET_KEY with these
@ -117,9 +135,13 @@ from flask import current_app; print(current_app.config["SECRET_KEY"])
Save your `superset_config.py` with these values and then run `superset re-encrypt-secrets`.
### Using a production metastore
## Setting up a production metadata database
By default, Superset is configured to use SQLite, which is a simple and fast way to get started
Superset needs a database to store the information it manages, like the definitions of
charts, dashboards, and many other things.
By default, Superset is configured to use [SQLite](https://www.sqlite.org/),
a self-contained, single-file database that offers a simple and fast way to get started
(without requiring any installation). However, for production environments,
using SQLite is highly discouraged due to security, scalability, and data integrity reasons.
It's important to use only the supported database engines and consider using a different
@ -139,10 +161,17 @@ Use the following database drivers and connection strings:
| [PostgreSQL](https://www.postgresql.org/) | `pip install psycopg2` | `postgresql://<UserName>:<DBPassword>@<Database Host>/<Database Name>` |
| [MySQL](https://www.mysql.com/) | `pip install mysqlclient` | `mysql://<UserName>:<DBPassword>@<Database Host>/<Database Name>` |
:::tip
Properly setting up metadata store is beyond the scope of this documentation. We recommend
using a hosted managed service such as [Amazon RDS](https://aws.amazon.com/rds/) or
[Google Cloud Databases](https://cloud.google.com/products/databases?hl=en) to handle
service and supporting infrastructure and backup strategy.
:::
To configure Superset metastore set `SQLALCHEMY_DATABASE_URI` config key on `superset_config`
to the appropriate connection string.
### Running on a WSGI HTTP Server
## Running on a WSGI HTTP Server
While you can run Superset on NGINX or Apache, we recommend using Gunicorn in async mode. This
enables impressive concurrency even and is fairly easy to install and configure. Please refer to the
@ -171,12 +200,12 @@ If you're not using Gunicorn, you may want to disable the use of `flask-compress
Currently, Google BigQuery python sdk is not compatible with `gevent`, due to some dynamic monkeypatching on python core library by `gevent`.
So, when you use `BigQuery` datasource on Superset, you have to use `gunicorn` worker type except `gevent`.
### HTTPS Configuration
## HTTPS Configuration
You can configure HTTPS upstream via a load balancer or a reverse proxy (such as nginx) and do SSL/TLS Offloading before traffic reaches the Superset application. In this setup, local traffic from a Celery worker taking a snapshot of a chart for Alerts & Reports can access Superset at a `http://` URL, from behind the ingress point.
You can also configure [SSL in Gunicorn](https://docs.gunicorn.org/en/stable/settings.html#ssl) (the Python webserver) if you are using an official Superset Docker image.
### Configuration Behind a Load Balancer
## Configuration Behind a Load Balancer
If you are running superset behind a load balancer or reverse proxy (e.g. NGINX or ELB on AWS), you
may need to utilize a healthcheck endpoint so that your load balancer knows if your superset
@ -194,7 +223,7 @@ In case the reverse proxy is used for providing SSL encryption, an explicit defi
RequestHeader set X-Forwarded-Proto "https"
```
### Custom OAuth2 Configuration
## Custom OAuth2 Configuration
Superset is built on Flask-AppBuilder (FAB), which supports many providers out of the box
(GitHub, Twitter, LinkedIn, Google, Azure, etc). Beyond those, Superset can be configured to connect
@ -293,19 +322,19 @@ CUSTOM_SECURITY_MANAGER = CustomSsoSecurityManager
]
```
### LDAP Authentication
## LDAP Authentication
FAB supports authenticating user credentials against an LDAP server.
To use LDAP you must install the [python-ldap](https://www.python-ldap.org/en/latest/installing.html) package.
See [FAB's LDAP documentation](https://flask-appbuilder.readthedocs.io/en/latest/security.html#authentication-ldap)
for details.
### Mapping LDAP or OAUTH groups to Superset roles
## Mapping LDAP or OAUTH groups to Superset roles
AUTH_ROLES_MAPPING in Flask-AppBuilder is a dictionary that maps from LDAP/OAUTH group names to FAB roles.
It is used to assign roles to users who authenticate using LDAP or OAuth.
#### Mapping OAUTH groups to Superset roles
### Mapping OAUTH groups to Superset roles
The following `AUTH_ROLES_MAPPING` dictionary would map the OAUTH group "superset_users" to the Superset roles "Gamma" as well as "Alpha", and the OAUTH group "superset_admins" to the Superset role "Admin".
@ -315,7 +344,7 @@ AUTH_ROLES_MAPPING = {
"superset_admins": ["Admin"],
}
```
#### Mapping LDAP groups to Superset roles
### Mapping LDAP groups to Superset roles
The following `AUTH_ROLES_MAPPING` dictionary would map the LDAP DN "cn=superset_users,ou=groups,dc=example,dc=com" to the Superset roles "Gamma" as well as "Alpha", and the LDAP DN "cn=superset_admins,ou=groups,dc=example,dc=com" to the Superset role "Admin".
@ -327,11 +356,11 @@ AUTH_ROLES_MAPPING = {
```
Note: This requires `AUTH_LDAP_SEARCH` to be set. For more details, please see the [FAB Security documentation](https://flask-appbuilder.readthedocs.io/en/latest/security.html).
#### Syncing roles at login
### Syncing roles at login
You can also use the `AUTH_ROLES_SYNC_AT_LOGIN` configuration variable to control how often Flask-AppBuilder syncs the user's roles with the LDAP/OAUTH groups. If `AUTH_ROLES_SYNC_AT_LOGIN` is set to True, Flask-AppBuilder will sync the user's roles each time they log in. If `AUTH_ROLES_SYNC_AT_LOGIN` is set to False, Flask-AppBuilder will only sync the user's roles when they first register.
### Flask app Configuration Hook
## Flask app Configuration Hook
`FLASK_APP_MUTATOR` is a configuration function that can be provided in your environment, receives
the app object and can alter it in any way. For example, add `FLASK_APP_MUTATOR` into your
@ -354,7 +383,7 @@ def FLASK_APP_MUTATOR(app: Flask) -> None:
app.before_request_funcs.setdefault(None, []).append(make_session_permanent)
```
### Feature Flags
## Feature Flags
To support a diverse set of users, Superset has some features that are not enabled by default. For
example, some users have stronger security restrictions, while some others may not. So Superset

View File

@ -1,13 +1,12 @@
---
title: Country Map Tools
hide_title: true
sidebar_position: 10
version: 1
---
import countriesData from '../../data/countries.json';
## The Country Map Visualization
# The Country Map Visualization
The Country Map visualization allows you to plot lightweight choropleth maps of
your countries by province, states, or other subdivision types. It does not rely

View File

@ -1,18 +1,18 @@
---
title: Event Logging
hide_title: true
sidebar_position: 9
version: 1
---
## Logging
# Logging
### Event Logging
## Event Logging
Superset by default logs special action events in its internal database (DBEventLogger). These logs can be accessed
on the UI by navigating to **Security > Action Log**. You can freely customize these logs by
implementing your own event log class.
**When custom log class is enabled DBEventLogger is disabled and logs stop being populated in UI logs view.**
**When custom log class is enabled DBEventLogger is disabled and logs
stop being populated in UI logs view.**
To achieve both, custom log class should extend built-in DBEventLogger log class.
Here's an example of a simple JSON-to-stdout class:
@ -44,9 +44,10 @@ End by updating your config to pass in an instance of the logger you want to use
EVENT_LOGGER = JSONStdOutEventLogger()
```
### StatsD Logging
## StatsD Logging
Superset can be instrumented to log events to StatsD if desired. Most endpoints hit are logged as
Superset can be configured to log events to [StatsD](https://github.com/statsd/statsd)
if desired. Most endpoints hit are logged as
well as key events like query start and end in SQL Lab.
To setup StatsD logging, its a matter of configuring the logger in your `superset_config.py`.

View File

@ -5,7 +5,7 @@ sidebar_position: 11
version: 1
---
## Importing and Exporting Datasources
# Importing and Exporting Datasources
The superset cli allows you to import and export datasources from and to YAML. Datasources include
databases. The data is expected to be organized in the following hierarchy:
@ -26,7 +26,7 @@ databases. The data is expected to be organized in the following hierarchy:
| └── ... (more databases)
```
### Exporting Datasources to YAML
## Exporting Datasources to YAML
You can print your current datasources to stdout by running:
@ -61,7 +61,7 @@ superset export_datasource_schema
As a reminder, you can use the `-b` flag to include back references.
### Importing Datasources
## Importing Datasources
In order to import datasources from a ZIP file, run:
@ -75,9 +75,9 @@ The optional username flag **-u** sets the user used for the datasource import.
superset import_datasources -p <path / filename> -u 'admin'
```
### Legacy Importing Datasources
## Legacy Importing Datasources
#### From older versions of Superset to current version
### From older versions of Superset to current version
When using Superset version 4.x.x to import from an older version (2.x.x or 3.x.x) importing is supported as the command `legacy_import_datasources` and expects a JSON or directory of JSONs. The options are `-r` for recursive and `-u` for specifying a user. Example of legacy import without options:
@ -85,7 +85,7 @@ When using Superset version 4.x.x to import from an older version (2.x.x or 3.x.
superset legacy_import_datasources -p <path or filename>
```
#### From older versions of Superset to older versions
### From older versions of Superset to older versions
When using an older Superset version (2.x.x & 3.x.x) of Superset, the command is `import_datasources`. ZIP and YAML files are supported and to switch between them the feature flag `VERSIONED_EXPORT` is used. When `VERSIONED_EXPORT` is `True`, `import_datasources` expects a ZIP file, otherwise YAML. Example:

View File

@ -1,13 +1,12 @@
---
title: Additional Networking Settings
hide_title: true
title: Network and Security Settings
sidebar_position: 7
version: 1
---
## Additional Networking Settings
# Network and Security Settings
### CORS
## CORS
To configure CORS, or cross-origin resource sharing, the following dependency must be installed:
@ -21,7 +20,37 @@ The following keys in `superset_config.py` can be specified to configure CORS:
- `CORS_OPTIONS`: options passed to Flask-CORS
([documentation](https://flask-cors.corydolphin.com/en/latest/api.html#extension))
### Domain Sharding
## HTTP headers
Note that Superset bundles [flask-talisman](https://pypi.org/project/talisman/)
Self-descried as a small Flask extension that handles setting HTTP headers that can help
protect against a few common web application security issues.
## CSRF settings
Similarly, [flask-wtf](https://flask-wtf.readthedocs.io/en/0.15.x/config/) is used manage
some CSRF configurations. If you need to exempt endpoints from CSRF (e.g. if you are
running a custom auth postback endpoint), you can add the endpoints to `WTF_CSRF_EXEMPT_LIST`:
## SSH Tunneling
1. Turn on feature flag
- Change [`SSH_TUNNELING`](https://github.com/apache/superset/blob/eb8386e3f0647df6d1bbde8b42073850796cc16f/superset/config.py#L489) to `True`
- If you want to add more security when establishing the tunnel we allow users to overwrite the `SSHTunnelManager` class [here](https://github.com/apache/superset/blob/eb8386e3f0647df6d1bbde8b42073850796cc16f/superset/config.py#L507)
- You can also set the [`SSH_TUNNEL_LOCAL_BIND_ADDRESS`](https://github.com/apache/superset/blob/eb8386e3f0647df6d1bbde8b42073850796cc16f/superset/config.py#L508) this the host address where the tunnel will be accessible on your VPC
2. Create database w/ ssh tunnel enabled
- With the feature flag enabled you should now see ssh tunnel toggle.
- Click the toggle to enables ssh tunneling and add your credentials accordingly.
- Superset allows for 2 different type authentication (Basic + Private Key). These credentials should come from your service provider.
3. Verify data is flowing
- Once SSH tunneling has been enabled, go to SQL Lab and write a query to verify data is properly flowing.
## Domain Sharding
Chrome allows up to 6 open connections per domain at a time. When there are more than 6 slices in
dashboard, a lot of time fetch requests are queued up and wait for next available socket.
@ -42,7 +71,7 @@ or add the following setting in your `superset_config.py` file if domain shards
- `SESSION_COOKIE_DOMAIN = '.mydomain.com'`
### Middleware
## Middleware
Superset allows you to add your own middleware. To add your own middleware, update the
`ADDITIONAL_MIDDLEWARE` key in your `superset_config.py`. `ADDITIONAL_MIDDLEWARE` should be a list

View File

@ -4,18 +4,3 @@ hide_title: true
sidebar_position: 8
version: 1
---
## SSH Tunneling
1. Turn on feature flag
- Change [`SSH_TUNNELING`](https://github.com/apache/superset/blob/eb8386e3f0647df6d1bbde8b42073850796cc16f/superset/config.py#L489) to `True`
- If you want to add more security when establishing the tunnel we allow users to overwrite the `SSHTunnelManager` class [here](https://github.com/apache/superset/blob/eb8386e3f0647df6d1bbde8b42073850796cc16f/superset/config.py#L507)
- You can also set the [`SSH_TUNNEL_LOCAL_BIND_ADDRESS`](https://github.com/apache/superset/blob/eb8386e3f0647df6d1bbde8b42073850796cc16f/superset/config.py#L508) this the host address where the tunnel will be accessible on your VPC
2. Create database w/ ssh tunnel enabled
- With the feature flag enabled you should now see ssh tunnel toggle.
- Click the toggle to enables ssh tunneling and add your credentials accordingly.
- Superset allows for 2 different type authentication (Basic + Private Key). These credentials should come from your service provider.
3. Verify data is flowing
- Once SSH tunneling has been enabled, go to SQL Lab and write a query to verify data is properly flowing.

View File

@ -5,9 +5,9 @@ sidebar_position: 5
version: 1
---
## SQL Templating
# SQL Templating
### Jinja Templates
## Jinja Templates
SQL Lab and Explore supports [Jinja templating](https://jinja.palletsprojects.com/en/2.11.x/) in queries.
To enable templating, the `ENABLE_TEMPLATE_PROCESSING` [feature flag](/docs/configuration/configuring-superset#feature-flags) needs to be enabled in
@ -168,7 +168,7 @@ FEATURE_FLAGS = {
The available validators and names can be found in
[sql_validators](https://github.com/apache/superset/tree/master/superset/sql_validators).
### Available Macros
## Available Macros
In this section, we'll walkthrough the pre-defined Jinja macros in Superset.

View File

@ -5,7 +5,7 @@ sidebar_position: 6
version: 1
---
## Timezones
# Timezones
There are four distinct timezone components which relate to Apache Superset,

View File

@ -5,23 +5,29 @@ sidebar_position: 3
version: 1
---
## Using Docker Compose
import useBaseUrl from "@docusaurus/useBaseUrl";
**DO NOT USE THIS FOR PRODUCTION!**
# Using Docker Compose
The fastest way to try Superset locally is using Docker Compose on a Linux or Mac OSX
computer. Superset does not have official support for Windows. It's also the easiest
way to launch a fully functioning **development environment** quickly.
<img src={useBaseUrl("/img/docker-compose.webp" )} width="150" />
<br /><br />
:::caution
Since `docker-compose` is primarily designed to run a set of containers on **a single host**
and can't credibly support **high availability** as a result, we do not support nor recommend
and can't support requirements for **high availability**, we do not support nor recommend
using our `docker-compose` constructs to support production-type use-cases. For single host
environments, we recommend using [minikube](https://minikube.sigs.k8s.io/docs/start/) along
our [installing on k8s](https://superset.apache.org/docs/installation/running-on-kubernetes)
documentation.
:::
As mentioned in our [quickstart guidee](/docs/quickstart), The fastest way to try
Superset locally is using Docker Compose on a Linux or Mac OSX
computer. Superset does not have official support for Windows. It's also the easiest
way to launch a fully functioning **development environment** quickly.
Note that there are 3 major ways we support to run docker-compose:
1. **docker-compose.yml:** for interactive development, where we mount your local folder with the
frontend/backend files that you can edit and experience the changes you
@ -37,14 +43,14 @@ Note that there are 3 major ways we support to run docker-compose:
More on these two approaches after setting up the requirements for either.
### Requirements
## Requirements
Note that this documentation assumes that you have [Docker](https://www.docker.com),
[docker-compose](https://docs.docker.com/compose/), and
[git](https://git-scm.com/) installed.
### 1. Clone Superset's GitHub repository
## 1. Clone Superset's GitHub repository
[Clone Superset's repo](https://github.com/apache/superset) in your terminal with the
following command:
@ -56,7 +62,7 @@ git clone --depth=1 https://github.com/apache/superset.git
Once that command completes successfully, you should see a new `superset` folder in your
current directory.
### 2. Launch Superset Through Docker Compose
## 2. Launch Superset Through Docker Compose
First let's assume you're familiar with docker-compose mechanics. Here we'll refer generally
to `docker compose up` even though in some cases you may want to force a check for newer remote
@ -86,13 +92,13 @@ perform those operations. In this case, we recommend you set the env var
Simply trigger `npm i && npm run dev`, this should be MUCH faster.
:::
### Option #2 - build an immutable image from the local branch
### Option #2 - build a set of immutable images from the local branch
```bash
docker compose -f docker-compose-non-dev.yml up
```
### Option #3 - pull and build a release image from docker-hub
### Option #3 - boot up an official release
```bash
export TAG=3.1.1
@ -103,7 +109,7 @@ Here various release tags, github SHA, and latest `master` can be referenced by
Refer to the docker-related documentation to learn more about existing tags you can point to
from Docker Hub.
## General tips & configuration
## docker-compose tips & configuration
:::caution
All of the content belonging to a Superset instance - charts, dashboards, users, etc. - is stored in
@ -119,7 +125,7 @@ You should see a wall of logging output from the containers being launched on yo
this output slows, you should have a running instance of Superset on your local machine! To avoid
the wall of text on future runs, add the `-d` option to the end of the `docker compose up` command.
#### Configuring Further
### Configuring Further
The following is for users who want to configure how Superset runs in Docker Compose; otherwise, you
can skip to the next section.
@ -170,7 +176,7 @@ To disable the Scarf telemetry pixel, set the `SCARF_ANALYTICS` environment vari
your terminal and/or in your `docker/.env` file.
:::
### 3. Log in to Superset
## 3. Log in to Superset
Your local Superset instance also includes a Postgres server to store your data and is already
pre-loaded with some example datasets that ship with Superset. You can access Superset now via your
@ -187,7 +193,7 @@ username: admin
password: admin
```
### 4. Connecting Superset to your local database instance
## 4. Connecting Superset to your local database instance
When running Superset using `docker` or `docker compose` it runs in its own docker container, as if
the Superset was running in a separate machine entirely. Therefore attempts to connect to your local

View File

@ -5,12 +5,18 @@ sidebar_position: 1
version: 1
---
## Installing on Kubernetes
import useBaseUrl from "@docusaurus/useBaseUrl";
# Installing on Kubernetes
<img src={useBaseUrl("/img/k8s.png" )} width="150" />
<br /><br />
Running Superset on Kubernetes is supported with the provided [Helm](https://helm.sh/) chart
found in the official [Superset helm repository](https://apache.github.io/superset/index.yaml).
### Prerequisites
## Prerequisites
- A Kubernetes cluster
- Helm installed
@ -22,7 +28,7 @@ and works fantastically well with the Helm chart referenced here.
:::
### Running
## Running
1. Add the Superset helm repository
@ -89,9 +95,9 @@ Depending how you configured external access, the URL will vary. Once you've ide
- user: `admin`
- password: `admin`
### Important settings
## Important settings
#### Security settings
### Security settings
Default security settings and passwords are included but you **MUST** update them to run `prod` instances, in particular:
@ -135,7 +141,7 @@ Superset uses [Scarf Gateway](https://about.scarf.sh/scarf-gateway) to collect t
To opt-out of this data collection in your Helm-based installation, edit the `repository:` line in your `helm/superset/values.yaml` file, replacing `apachesuperset.docker.scarf.sh/apache/superset` with `apache/superset` to pull the image directly from Docker Hub.
:::
#### Dependencies
### Dependencies
Install additional packages and do any other bootstrap configuration in the bootstrap script.
For production clusters it's recommended to build own image with this step done in CI.
@ -161,7 +167,7 @@ bootstrapScript: |
if [ ! -f ~/bootstrap ]; then echo "Running Superset with uid {{ .Values.runAsUser }}" > ~/bootstrap; fi
```
#### superset_config.py
### superset_config.py
The default `superset_config.py` is fairly minimal and you will very likely need to extend it. This is done by specifying one or more key/value entries in `configOverrides`, e.g.:
@ -181,7 +187,7 @@ The entire `superset_config.py` will be installed as a secret, so it is safe to
Full python files can be provided by running `helm upgrade --install --values my-values.yaml --set-file configOverrides.oauth=set_oauth.py`
#### Environment Variables
### Environment Variables
Those can be passed as key/values either with `extraEnv` or `extraSecretEnv` if they're sensitive. They can then be referenced from `superset_config.py` using e.g. `os.environ.get("VAR")`.
@ -206,7 +212,7 @@ configOverrides:
SMTP_PASSWORD = os.getenv("SMTP_PASSWORD","superset")
```
#### System packages
### System packages
If new system packages are required, they can be installed before application startup by overriding the container's `command`, e.g.:
@ -225,7 +231,7 @@ supersetWorker:
. {{ .Values.configMountPath }}/superset_bootstrap.sh; celery --app=superset.tasks.celery_app:app worker
```
#### Data sources
### Data sources
Data source definitions can be automatically declared by providing key/value yaml definitions in `extraConfigs`:
@ -246,9 +252,9 @@ extraConfigs:
Those will also be mounted as secrets and can include sensitive parameters.
### Configuration Examples
## Configuration Examples
#### Setting up OAuth
### Setting up OAuth
:::note
@ -302,11 +308,11 @@ configOverrides:
AUTH_USER_REGISTRATION_ROLE = "Admin"
```
#### Enable Alerts and Reports
### Enable Alerts and Reports
For this, as per the [Alerts and Reports doc](/docs/configuration/alerts-reports), you will need to:
##### Install a supported webdriver in the Celery worker
#### Install a supported webdriver in the Celery worker
This is done either by using a custom image that has the webdriver pre-installed, or installing at startup time by overriding the `command`. Here's a working example for `chromedriver`:
@ -335,7 +341,7 @@ supersetWorker:
. {{ .Values.configMountPath }}/superset_bootstrap.sh; celery --app=superset.tasks.celery_app:app worker
```
##### Run the Celery beat
#### Run the Celery beat
This pod will trigger the scheduled tasks configured in the alerts and reports UI section:
@ -344,7 +350,7 @@ supersetCeleryBeat:
enabled: true
```
##### Configure the appropriate Celery jobs and SMTP/Slack settings
#### Configure the appropriate Celery jobs and SMTP/Slack settings
```yaml
extraEnv:
@ -428,7 +434,7 @@ configOverrides:
"--disable-extensions",
]
```
#### Load the Examples data and dashboards
### Load the Examples data and dashboards
If you are trying Superset out and want some data and dashboards to explore, you can load some examples by creating a `my_values.yaml` and deploying it as described above in the **Configure your setting overrides** step of the **Running** section.
To load the examples, add the following to the `my_values.yaml` file:
```yaml

View File

@ -5,11 +5,16 @@ sidebar_position: 2
version: 1
---
## Installing Superset from PyPI
import useBaseUrl from "@docusaurus/useBaseUrl";
# Installing Superset from PyPI
<img src={useBaseUrl("/img/pypi.png" )} width="150" />
<br /><br />
This page describes how to install Superset using the `apache-superset` package [published on PyPI](https://pypi.org/project/apache-superset/).
### OS Dependencies
## OS Dependencies
Superset stores database connection information in its metadata database. For that purpose, we use
the cryptography Python library to encrypt connection passwords. Unfortunately, this library has OS
@ -91,7 +96,7 @@ export CFLAGS="-I$(brew --prefix openssl)/include"
These will now be available when pip installing requirements.
### Python Virtual Environment
## Python Virtual Environment
We highly recommend installing Superset inside of a virtual environment. Python ships with
`virtualenv` out of the box. If you're using [pyenv](https://github.com/pyenv/pyenv), you can install [pyenv-virtualenv](https://github.com/pyenv/pyenv-virtualenv). Or you can install it with `pip`:

View File

@ -5,9 +5,9 @@ sidebar_position: 4
version: 1
---
## Upgrading Superset
# Upgrading Superset
### Docker Compose
## Docker Compose
First make sure to wind down the running containers in Docker Compose:
@ -27,7 +27,7 @@ Then, restart the containers and any changed Docker images will be automatically
docker compose up
```
### Updating Superset Manually
## Updating Superset Manually
To upgrade superset in a native installation, run the following commands:
@ -35,7 +35,7 @@ To upgrade superset in a native installation, run the following commands:
pip install apache-superset --upgrade
```
## Upgrading Metadata Database
## Upgrading the Metadata Database
Migrate the metadata database by running:

View File

@ -1,67 +0,0 @@
---
title: Introduction
hide_title: true
sidebar_position: 1
---
## What is Apache Superset?
Apache Superset is a modern, enterprise-ready business intelligence web application. It
is fast, lightweight, intuitive, and loaded with options that make it easy for users of all skill
sets to explore and visualize their data, from simple pie charts to highly detailed deck.gl
geospatial charts.
Here are a **few different ways you can get started with Superset**:
- Try a [Quickstart deployment](/docs/quickstart), powered by [Docker Compose](https://docs.docker.com/compose/)
- Install Superset [from PyPI](/docs/installation/pypi/)
- Deploy Superset [with Kubernetes](/docs/installation/kubernetes)
- Download the [source code from Apache Foundation's website](https://dist.apache.org/repos/dist/release/superset/)
#### Video Overview
<video src="https://superset.staged.apache.org/superset-video-4k.mp4" width="100%" height="auto" controls preload="none">
https://superset.staged.apache.org/superset-video-4k.mp4
</video>
#### Features
Superset provides:
- An intuitive interface for visualizing datasets and crafting interactive dashboards
- A wide array of beautiful visualizations to showcase your data
- Code-free visualization builder to extract and present datasets
- A world-class SQL IDE for preparing data for visualization, including a rich metadata browser
- A lightweight semantic layer which empowers data analysts to quickly define custom dimensions and metrics
- Out-of-the-box support for [most SQL-speaking databases](http://localhost:3000/docs/configuration/databases#installing-database-drivers)
- Seamless, in-memory asynchronous caching and queries
- An extensible security model that allows configuration of very intricate rules on who can access which product features and datasets.
- Integration with major authentication backends (database, OpenID, LDAP, OAuth, REMOTE_USER, etc)
- The ability to add custom visualization plugins
- An API for programmatic customization
- A cloud-native architecture designed from the ground up for scale
#### Backend Technology
Superset is cloud-native and designed to be highly available. It was designed to scale out to large,
distributed environments and works very well inside containers. While you can easily test drive
Superset on a modest setup or simply on your laptop, theres virtually no limit around scaling out
the platform.
Superset is also cloud-native in the sense that it is flexible and lets you choose the:
- Web server (Gunicorn, Nginx, Apache),
- Metadata database engine (PostgreSQL, MySQL, MariaDB),
- Message queue (Celery, Redis, RabbitMQ, SQS, etc.),
- Results backend (Redis, S3, Memcached, etc.),
- Caching layer (Redis, Memcached, etc.)
Superset also works well with [event-logging](/docs/configuration/event-logging/)
services like StatsD, NewRelic, and DataDog.
Superset is currently run at scale at many companies. For example, Superset is run in Airbnbs
production environment inside Kubernetes and serves 600+ daily active users viewing over 100K charts
a day.
You can find a partial list of industries and companies embracing Superset
[on this page in GitHub](https://github.com/apache/superset/blob/master/RESOURCES/INTHEWILD.md).

View File

@ -231,6 +231,7 @@ const config = {
items: [
{
label: 'Documentation',
to: '/docs/intro',
items: [
{
label: 'Getting Started',
@ -244,6 +245,7 @@ const config = {
},
{
label: 'Community',
to: '/community',
items: [
{
label: 'Resources',

View File

@ -5,8 +5,9 @@
"license": "Apache-2.0",
"scripts": {
"docusaurus": "docusaurus",
"start": "docusaurus start",
"build": "docusaurus build",
"_init": "cp ../README.md docs/intro.md",
"start": "npm run _init && docusaurus start",
"build": "npm run _init && docusaurus build",
"swizzle": "docusaurus swizzle",
"deploy": "docusaurus deploy",
"clear": "docusaurus clear",

View File

@ -16,6 +16,7 @@
* specific language governing permissions and limitations
* under the License.
*/
// @ts-nocheck
import React, { useRef, useState, useEffect } from 'react';
import Layout from '@theme/Layout';
import Link from '@docusaurus/Link';
@ -28,6 +29,8 @@ import SectionHeader from '../components/SectionHeader';
import BlurredSection from '../components/BlurredSection';
import '../styles/main.less';
// @ts-ignore
const features = [
{
image: 'powerful-yet-easy.jpg',

View File

@ -39,6 +39,12 @@
font-weight: 700;
font-style: bold;
}
/* Hiding ugly linkout icons */
ul.dropdown__menu svg {
display: none;
}
:root {
--ifm-color-primary: #20a7c9;
--ifm-color-primary-dark: #1985a0;
@ -60,4 +66,6 @@
--ifm-border-color: #ededed;
--ifm-primary-text: #484848;
--ifm-secondary-text: #5f5f5f;
--ifm-code-padding-vertical: 3px;
--ifm-code-padding-horizontal: 5px;
}

View File

@ -63,3 +63,5 @@ RewriteRule ^docs/installation/async-queries-celery/$ /docs/configuration/async-
RewriteRule ^docs/installation/event-logging/$ /docs/configuration/event-logging [R=301,L]
RewriteRule ^docs/databases.*$ /docs/configuration/databases [R=301,L]
RewriteRule ^docs/configuration/setup-ssh-tunneling$ /docs/configuration/networking-settings [R=301,L]

BIN
docs/static/img/databases/databend.png vendored Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.1 KiB

BIN
docs/static/img/databases/db2.png vendored Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.3 KiB

BIN
docs/static/img/databases/firebolt.png vendored Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 8.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 15 KiB

BIN
docs/static/img/databases/mariadb.png vendored Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 9.4 KiB

BIN
docs/static/img/databases/monet-db.png vendored Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 14 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 10 KiB

BIN
docs/static/img/databases/mysql.png vendored Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 9.1 KiB

BIN
docs/static/img/databases/pinot.png vendored Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.0 KiB

BIN
docs/static/img/databases/postgresql.png vendored Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 16 KiB

BIN
docs/static/img/databases/presto.png vendored Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 11 KiB

BIN
docs/static/img/databases/redshift.png vendored Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 11 KiB

BIN
docs/static/img/databases/snowflake.png vendored Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 15 KiB

BIN
docs/static/img/databases/sybase.png vendored Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 18 KiB

BIN
docs/static/img/docker-compose.png vendored Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 160 KiB

BIN
docs/static/img/docker-compose.webp vendored Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 28 KiB

BIN
docs/static/img/k8s.png vendored Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 85 KiB

BIN
docs/static/img/pypi.png vendored Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.8 KiB

BIN
docs/static/img/screenshots/explore.jpg vendored Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 636 KiB

BIN
docs/static/img/screenshots/gallery.jpg vendored Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 943 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 494 KiB

BIN
docs/static/img/screenshots/sql_lab.jpg vendored Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 444 KiB

View File

@ -3,5 +3,11 @@
"extends": "@tsconfig/docusaurus/tsconfig.json",
"compilerOptions": {
"baseUrl": "."
},
"jsx": "react-jsx",
"moduleResolution": "node",
"baseUrl": "./",
"paths": {
"*": ["src/*", "node_modules/*"]
}
}

File diff suppressed because it is too large Load Diff