Doris
Apache Doris is an easy-to-use, high performance and unified analytics database.
Last verified:
What is Doris?
Apache Doris is an open-source, real-time analytical database based on MPP (Massively Parallel Processing) architecture, known for its extreme query speed and ease of use. It returns sub-second query results on large datasets and supports both high-concurrency point queries and high-throughput complex analysis. Doris can be used for report analysis, ad-hoc queries, unified data warehouse construction, and data lake query acceleration.
Key features include real-time data ingestion with second-level freshness, columnar storage engine with high compression ratios, vectorized query execution engine delivering 5-10x performance gains, support for MySQL protocol and standard SQL syntax, multiple data models (Detail, Primary Key, Aggregate), materialized views for automatic optimization, extensive catalog support for Iceberg/Delta Lake/Hudi, and built-in hybrid search capabilities for JSON, text, and vector data. It offers both coupled storage-compute architecture for classic MPP deployments and decoupled cloud-native architecture with stateless compute groups over shared object storage.
Apache Doris is designed for data engineers, data analysts, database administrators, and organizations needing real-time analytics. It serves companies building user behavior analysis platforms, A/B testing systems, log analysis tools, user profile analysis, e-commerce order analysis, customer-facing analytics, observability platforms, and AI applications requiring vector search and RAG capabilities. The database has been adopted by over 5,000 companies worldwide including TikTok, Baidu, Tencent, NetEase, Xiaomi, JD.com, Ford, Samsung, and many others across finance, retail, telecommunications, energy, manufacturing, and gaming industries.
The system supports 50+ connectors for databases, streaming platforms, lakehouse formats, BI tools, AI agents, and observability tools. It integrates seamlessly with BI tools like Tableau, Power BI, Apache Superset, Metabase, FineBI, and Grafana. Doris enables federated queries across multiple data sources, eliminating data silos and simplifying architecture.
Doris pricing
Pricing model: Freemium
Apache Doris is open-source software released under the Apache License V2.0, making it completely free to use with no licensing fees. Users can download the source code and binary packages from the Apache website for free. The software can be self-hosted on bare metal, virtual machines, or cloud infrastructure at your own cost. There are no paid tiers or subscription plans from the Apache Doris project itself. Third-party managed cloud services may charge for hosting and managed operations, but the database software remains free. The community provides free support through Slack, Discord, mailing lists, and GitHub.
Doris pros
- Sub-second query results on large datasets even under high concurrency
- Second-level data ingestion freshness from Kafka and database CDC
- Fully compatible with MySQL protocol and standard SQL syntax
- Simple two-node architecture with only FE and BE processes
- Vectorized execution engine provides 5-10x performance over non-vectorized engines
- Columnar storage with high compression ratios reduces IO and CPU usage
- Multiple indexes including BloomFilter, inverted index, and sorted compound key
- Automatic single-table materialized views require no manual intervention
- Supports Iceberg, Delta Lake, and Hudi tables with no data copy required
- Built-in hybrid search for JSON, text BM25, and vector HNSW/IVF indexes
- Horizontal scalability supporting hundreds of machines and petabytes of storage
- High availability with multi-replica data storage and quorum protocol
- Cross-region disaster recovery with dual-cluster master-slave modes
- Pre-aggregation models significantly improve aggregation performance
- Runtime filter optimization pushes filters to probe side for better join performance
- Pipeline execution engine addresses thread explosion and leverages multi-core CPUs
- Three optimizer types: CBO, RBO, and HBO for optimal query plans
- Primary Key model enables row-level updates with unique key enforcement
Doris cons
- Learning curve for users new to real-time analytics or distributed systems
- Integration with external dashboards like Grafana can be tricky
- Docker deployment causes data loss when containers are destroyed
- Single-replica configurations lack data redundancy for production use
- Only supports UTF-8 character set encoding, causing issues with non-UTF-8 data
- BE process virtual memory can be too large due to Jemalloc metadata retention
- Requires regular BE process restarts to address virtual memory issues
- Memory leaks typically require upgrading to latest version to fix
- Complex partition and bucket management can lead to excessive tablets
- Cross-region setup requires careful configuration for disaster recovery
Frequently asked questions about Doris
What is Apache Doris used for?
Apache Doris is used for real-time data analysis, real-time reporting and decision-making, ad-hoc analysis, user profiling and behavior analysis, lakehouse analytics, lakehouse query acceleration, federated analytics across multiple data sources, real-time data processing, SQL-based observability, and log/event analysis in distributed systems. It powers applications for user behavior analysis, A/B testing platforms, e-commerce order analysis, customer-facing analytics, and AI agents with RAG capabilities.
How does Apache Doris compare to ClickHouse and Snowflake?
Apache Doris aims to be a unified data engine that can replace multiple tools in the data stack. Unlike ClickHouse which excels at single-table analytics, Doris provides better multi-table join capabilities with distributed shuffle join. Compared to Snowflake, Doris is open-source and free, can query data lakes directly without data copy, and offers both coupled and decoupled deployment modes. Doris consolidates what would typically require Kafka for streaming, Elasticsearch for search, and a separate warehouse for analytics into one engine.
What deployment architectures does Doris support?
Doris supports two deployment architectures: Compute-Storage Coupled (classic MPP with compute and storage co-located on each node for maximum local I/O and lowest query latency) and Compute-Storage Decoupled (cloud-native architecture with stateless compute groups over shared object storage that allows scaling compute on demand and isolating workloads). The coupled architecture is ideal for traditional deployments while the decoupled architecture is designed for cloud environments.
What data models does Apache Doris support?
Apache Doris supports three data models: Detail Model (Duplicate Key Model) for detailed storage of fact tables, Primary Key Model (Unique Key Model) which ensures unique keys and enables row-level data updates by overwriting data with the same key, and Aggregate Model (Aggregate Key Model) which merges value columns with the same key for pre-aggregation that significantly improves performance. Users can choose the model based on their specific scenario requirements.
How does Doris handle high availability and disaster recovery?
Apache Doris achieves high availability through multi-replica storage for both metadata and data, synchronizing data logs via the quorum protocol. Data write succeeds once a majority of replicas complete the write, ensuring cluster availability even if some nodes fail. FE nodes can be deployed in multiple copies with Master, Follower, and Observer roles for metadata redundancy. Doris supports both same-city and cross-region disaster recovery with dual-cluster master-slave modes. The cluster automatically isolates faulty nodes without affecting overall availability.
What BI tools integrate with Apache Doris?
Apache Doris seamlessly integrates with BI tools including Smartbi, DataEase, FineBI, Tableau, Power BI, Apache Superset, Metabase, and any BI tool that supports the MySQL protocol. Since Doris is highly compatible with the MySQL protocol and supports standard SQL, users can connect using MySQL Client tools for operations and maintenance. The database works as a data source for any BI tool supporting MySQL protocol connections.
Can Doris query data lakes without loading data?
Yes, Apache Doris supports extensive catalog access for Iceberg, Delta Lake, and Hudi tables, enabling queries directly on open lake formats with no data copy required. The vectorized execution engine and smart metadata caching make lake queries fast. Doris also supports incremental bi-directional sync to stream data both ways between open lake formats and Doris internal storage, enabling real-time analytics applied directly to your lakehouse.
What indexes does Doris use for query optimization?
Apache Doris supports multiple index structures: Sorted Compound Key Index (users specify up to three columns for compound sort key to prune data for concurrent reporting), Min/Max Index (effective for equivalence and range queries of numeric types), BloomFilter Index (effective for equivalence filtering of high-cardinality columns), and Inverted Index (enables fast searching for any field). These indexes minimize data scans and optimize query performance.
How does Doris achieve sub-second query performance?
Doris achieves sub-second performance through several mechanisms: MPP architecture for parallel execution between and within nodes, fully vectorized query engine with columnar memory layout reducing virtual function calls and increasing cache hit rates, SIMD instruction utilization, Pipeline execution engine breaking queries into parallel sub-tasks leveraging multi-core CPUs, columnar storage with efficient encoding and compression, multiple index types for data pruning, adaptive query execution with runtime filters pushed to scan nodes, and combined CBO/RBO/HBO optimization strategy for optimal execution plans.
What is the Doris community size and adoption?
By 2024, the Apache Doris community has gathered more than 600 contributors from hundreds of companies across different industries, with over 120 monthly active contributors. Apache Doris has been used in production environments of over 5,000 companies worldwide, with trusted users including TikTok, Baidu, Tencent, NetEase, Xiaomi, JD.com, Ford, Samsung, miHoYo, Luckin Coffee, Meituan, and many others. The project graduated from Apache incubator as a Top-Level Project in June 2022 and is now trusted by 10,000+ users globally.