An introduction to Redash
2020-08-01 / modified at 2025-02-11 / 474 words / 2 mins
Redash is a free, open source, lightweight business intellegince tool connecting to any data source, query and visualization.
Why Redash
Comparison Matrix
- Compare on visualization only, while data processing is not included (e.g. ETL/OLAP/lakehouse).
- Only structure data is involved.
- Free and open source.
Competitiveness analysis
Here are the four famous opensource BI tools
| BI Tools | Metabase(OSS) | Redash(OSS) | Grafana(OSS) | superset |
|---|---|---|---|---|
| Demo site | N, but can be created by heroku | Link | link | link |
| License | AGPL(Restricted) | BSD2 | Apache | Apache |
| Frontend | react | react, redash@viz-library | react, angular | react, d3 |
| Backend | Clojure | Python(Flask) | Go | Python(FAB) |
| HA support | ||||
| Cluster | N(In progress) | N(Buy SaaS) | Y(Session based) | N(Celery is not) |
| Depends | Postgres | Postgres,Redis(as MQ) | Postgres | Postgres, Redis(as MQ) |
| Datasource | ||||
| Engine & Drivers | Self-developed | QRDS(SQLAlchemy/ pystache,RQ-Queue) | Self-developed | SQLAlchemy, Celery |
| Result caching | Y | Y | N | Y |
| AuthZ | ||||
| Folder & Group | Y | Hidden(multi_org) | Y | N |
| RBAC | Y | N | N | N |
| Row-level security | N(Commercial Only) | N | N | N |
| AuthN | ||||
| Forward auth | N | Y | Y | Y |
| Visualization | ||||
| Iframe embedding Token | Y | N(always public) | Y | Y |
| Pivot table | Y | Y(A little hard) | Y(Plugin required) | Y |
Here is my choice strategy
In our scenario (Backend stack), the following is the main reason for Redash
- No source code modification required.
- Raw SQL support (but with injection, no sql pre-compile), which is easier to intergrade with format agnostic computational databases.
- Query definitions && low code visualization support
Here are more talks between different teams.
Redash Inside
Architecture
Redash use a asynchronous connection to fetch and cache results.
Scalability & High availability
Liebig’s law of redash
- python-rq uses Redis as a queue implementation, but lacks cluster support. So the redis instance requires AOF/RDB setup.
- Session/authorization: require shared sessions for multiple Flask apps(redis/db/traefik).
- Scheduler: only single instance per Redis.
Production
For production use, you must deploy redash instances behinds a ELB.
However, there are no OSS HA solution available, buying a SaaS version may be a better way for less maintance and also a way to contribute for open source.
One more thing
- Redash use Jinja as its template engine, NO sql injection protection is provided.
- Redash front is NOT a low code solution, we have verified the productivity of redash with Echart.js +vue, it showed that it’s faster to write js manually than edit json layout in redash.