StarRocks
- Problem solved: query fresh, continuously updated data in under a second, with joins across tables, without having to flatten everything into one big denormalized table.
- Era: started in 2020 (fork of Apache Doris named DorisDB), renamed StarRocks and released on 8 September 2021, Apache 2.0 in December 2022, Linux Foundation on 14 February 2023.
- Created by: a team coming almost entirely from Apache Doris, within the company StarRocks Inc. (renamed CelerData in August 2022).
- Publisher: Linux Foundation project (non-Apache), backed by CelerData, Apache 2.0 licence.
- Category: MPP analytical database (OLAP), MySQL-compatible SQL.
Historical context
StarRocks descends from Palo, built at Baidu for the reporting of its advertising business. Baidu open sources Palo in 2017 and hands it to the ASF in July 2018 under the name Apache Doris. According to StarRocks, this journey from Doris to Palo and back to Apache Doris took 13 years.
In early 2020, a team coming almost entirely from Doris founds a company to go further. Its observation: users want ever faster analytics, and the classic architecture can no longer keep up. The starting point of the project: "a fully vectorized compute engine". The product is first called DorisDB, on the PrestoDB model, which gets in the way of Apache Doris graduating from the incubator. On 8 September 2021, DorisDB becomes StarRocks and its code is published: code inherited from Doris stays under Apache 2.0, new code goes under Elastic License 2.0.
The problem targeted is that of the real-time OLAP databases of the time (Druid, Pinot, ClickHouse): fast on one table, but often forcing tables to be merged in advance and handling updates poorly. CelerData sums it up: "the need to denormalize data, the inability to process real-time updates, and the challenge of supporting large numbers of concurrent users". In December 2022, all the code moves to Apache 2.0, and on 14 February 2023 the project joins the Linux Foundation.
Key idea
Keep the strengths of a vectorized columnar engine (SIMD, compression), but add what real-time OLAP databases lacked: a cost-based optimizer able to run fast multi-table joins, and a primary key model that applies updates at write time rather than at read time. One can then query a fresh star schema instead of a recomputed flat table.
How it works
- Two kinds of processes: FEs (frontends) handle metadata, connections and planning; BEs (backends) store data and execute plans. No external component to deploy.
- Replicated metadata: each FE keeps a full copy of the metadata (BDB JE); a leader is elected among followers through Raft, and observers add read capacity.
- Vectorized MPP execution: a logical plan is split into physical plans run in parallel on the BEs that hold the data.
- Cost-based optimizer (CBO): started in December 2019, mature with 2.0 (January 2022) for complex joins.
- Primary Key model: updates are done as delete-and-insert instead of merge-on-read, so that queries do not pay for the merge each time.
- Shared-data (since 3.0, April 2023): BEs are replaced by stateless CNs (compute nodes); data lives on S3 or HDFS and the local disk is used as a cache. CNs can be added or removed within seconds.
- MySQL compatibility: the MySQL protocol lets you connect with an existing client or BI tool.
-- a table updated continuously (Kafka or Flink stream) through its primary key
CREATE TABLE orders (
order_id BIGINT,
customer_id BIGINT,
status VARCHAR(20),
amount DECIMAL(10, 2)
) PRIMARY KEY (order_id)
DISTRIBUTED BY HASH (order_id);
-- join on the fly rather than a precomputed flat table
SELECT c.country, sum(o.amount) AS revenue
FROM orders o JOIN customers c ON o.customer_id = c.customer_id
WHERE o.status = 'paid'
GROUP BY c.country;
By the numbers
| Figure | Context | Source |
|---|---|---|
| 13 years | Length of the Doris, Palo, Apache Doris journey before StarRocks (2021) | Official StarRocks statement |
| 330,000 out of 800,000 | Lines of code inherited from Apache Doris out of StarRocks' total (2021) | COO interview, IT168 |
| 80% | Share of the code rewritten in the two years after the fork (2023) | BigDATAwire |
| 3 to 10 times | Query speed-up in real-time update scenarios with the Primary Key model (2.0, 2022) | StarRocks 2.0 post |
| Over 500 companies | Using StarRocks, including Airbnb and Lenovo (2023) | CelerData press release |
| 60% | Year-over-year TPC-DS query speed-up announced for 4.0 (2025) | StarRocks 2025 review |
| Over 500 contributors | To the main repository, end of 2025 | StarRocks 2025 review |
Milestones
- 2017: Baidu open sources Palo; it enters the Apache incubator in July 2018 as Doris.
- December 2019: development of the cost-based optimizer begins.
- 2020: the DorisDB project starts, a commercial fork of Apache Doris.
- 8 September 2021: DorisDB is renamed StarRocks and its code is published (Apache 2.0 and Elastic License 2.0).
- January 2022: StarRocks 2.0, with the Primary Key model and a mature CBO.
- June 2022: Apache Doris becomes a top-level Apache project.
- July / August 2022: a cloud service is announced, then StarRocks Inc. becomes CelerData.
- December 2022: all the code moves to the Apache 2.0 licence.
- 14 February 2023: CelerData contributes StarRocks to the Linux Foundation.
- 28 April 2023: StarRocks 3.0 separates storage and compute (shared-data).
- 17 October 2025: StarRocks 4.0, with stronger Apache Iceberg support.
Did you know?
- The name: "StarRocks" combines "Star" and "Rocks": looking at the stars while keeping your feet on the ground, according to the team.
- A first name in the PrestoDB style: the team had named its product DorisDB and registered the trademark in China, the United States and Japan. Since the name got in the way of Apache Doris graduating, it committed to changing it.
- Not the ASF: rather than the Apache Software Foundation, already home to Doris, CelerData picks the Linux Foundation to stand apart, with the idea of joining the CNCF some day.
- From warehouse to lakehouse: in 2022, StarRocks still describes itself as a warehouse into which data is imported; 4.0 highlights native writes of Iceberg tables.
Strengths and limitations
| Strengths | Limitations |
|---|---|
| Fast multi-table joins thanks to the CBO: less need to denormalize | Performance figures mostly published by StarRocks and CelerData |
| Real-time updates with the Primary Key model | Shared-data mode is younger: several features arrive later than in shared-nothing (backup, indexes) |
| Simple architecture (FE + BE or CN), no external dependency | Direct competitor of Apache Doris, with which it shares its origin: two close but separate ecosystems |
| MySQL protocol, also queries Iceberg, Hudi, Delta Lake or Hive | Project long governed and maintained by a single company, StarRocks Inc. then CelerData |
Where it fits
- Heir of Apache Doris, listed in the Apache catalogue: same FE / BE architecture and same MySQL protocol, but a rewritten optimizer and executor.
- Competitor of Druid, Pinot and ClickHouse for real-time analytics, with a claimed angle: joins and updates.
- Query engine on the lakehouse, like Trino: it reads Iceberg, Hudi, Delta Lake or Hive tables.
- Fed by streams from Kafka and Flink, hence the value of the primary key model.
- Same home as Delta Lake: a Linux Foundation project rather than an ASF one.
Sources
raw-data/ecosysteme/starrocks/starrocks.md- https://www.globenewswire.com/news-release/2023/02/14/2607982/0/en/CelerData-Contributes-StarRocks-Project-to-the-Linux-Foundation.html
- https://www.starrocks.io/blog/2.0-release.html
- https://docs.starrocks.io/releasenotes/release-3.0/
- https://docs.starrocks.io/docs/introduction/Architecture/
- https://docs.starrocks.io/llms.txt
- https://www.starrocks.io/blog/starrocks-2025-year-in-review
- https://segmentfault.com/a/1190000040662237
- https://www.infoobs.com/article/20211029/50584.html
- https://venturebeat.com/infrastructure/starrocks-analytical-database-heads-to-the-linux-foundation-to-expand-open-source-project-contributions
- https://doris.apache.org/docs/gettingStarted/what-is-apache-doris
- Exact date of StarRocks 2.0.0 and of the December 2022 Apache 2.0 announcement from a primary source outside GitHub.
- Implementation languages (FE, BE) to be sourced.
- Quantified usage at Airbnb, Pinterest or Coinbase to be drawn from their engineering blogs.
- Compare StarRocks and Apache Doris precisely today (both have since added shared storage and lakehouse features).