Hello,
I'm Duc Nguyen (Duke) and I'm back
If you have not read the previous articles, please read it before practicing this one.
Topic #1, What is Apache Superset used for and how to install it on Windows 11
Topic #2, Superset ARCHITECTURE
Topic #3, Visualization data from CSV data file
Topic #4, Integrate 2D/3D maps into Superset
Topic #5, Automated Alerts and Reporting via Slack/Email in Superset
Today I will guide you how to optimize response speed and query in Superset
1.Optimize the database query side
- Use `JOINs` instead of `subqueries` when possible - Avoid using `SELECT *` and select only necessary columns - Use `EXPLAIN` to analyze queries - Avoid using functions on columns in `WHERE` clauses - Indexing - Materialized views
2.Optimize the Superset side
- Update to the latest version - Set up the `GLOBAL_ASYNC_QUERIES` to use async queries - Set up the `SQLLAB_TIMEOUT` and `SUPERSET_WEBSERVER_TIMEOUT` - Disable unnecessary features by `FEATURE_FLAGS` - Set up the `WSGI` instead of the Flask (eg. `Gunicorn`) - Run `superset db upgrade` to update the metadata database
If you are unclear about anything, please leave a comment and wait for the next topic in the Apache Superset tutorial section.
Top comments (1)
Let me know if you have any question