shardingsphere is a free, open source data engineering & integration project written in Java and released under Apache-2.0. It has 20,817 GitHub stars, 6,906 forks and 197 open issues, and was last pushed 13 hours ago. On this registry it ranks #4 of 53 tracked projects in Data Engineering & Integration, with 5 head-to-head comparisons available. It gained 12 stars over the last 30 tracked days.

What is shardingsphere?

Apache ShardingSphere is an Apache-2.0 licensed, Java-based distributed database ecosystem positioned as Database Plus — a standards and enhancement layer that sits above heterogeneous databases so applications can connect to, govern, and compute across them as if they were one database, aimed at enterprise data architects and developers running sharded, multi-database estates.

What it is

ShardingSphere is positioned as Database Plus: a standard and ecosystem built on top of heterogeneous databases. It does not create a new database. It acts as an operating system layer above databases, focused on maximizing the computing capability of the databases an organisation already runs, and it provides unified data access plus enhanced computing on top of them. Three pillars define it: Connect, Enhance, and Pluggable.

The problem it solves is heterogeneity. Databases of different engines, protocols, SQL dialects, and storage formats are difficult to use together, and ShardingSphere makes heterogeneous databases as simple to use as a single one. It does this by supplying unified governance and distributed computing capability for enterprise data architectures, and by offering enterprise-grade functions — distributed computing, data security, traffic control, observability — transparently rather than requiring changes to the underlying databases. Within the data access path, the ecosystem it occupies is database middleware and database gateway tooling, and the README positions it as a replacement for traditional middleware, which it contrasts as having richer features, a more complete ecosystem, and a more flexible architecture.

Key capabilities

  • Connect pillar: adapts database protocols, SQL dialects, and storage formats to join applications with multi-modal heterogeneous databases, with MySQL among the listed topics.
  • Enhance pillar distributed computing: data sharding, readwrite-splitting, and SQL federation.
  • Data security: encryption, masking, and audit, reflected in the data-encryption and encrypt topics.
  • Traffic control: circuit breaker and rate limiting at the gateway layer.
  • Observability: monitoring, tracing, and analysis.
  • Distributed transaction support, tagged under distributed-transaction.
  • Pluggable architecture: micro-kernel plus a 3-layer pluggable design that decouples kernel, functional components, and ecosystem integration, so developers can assemble custom data architecture solutions.

Who uses it and how

  • Enterprise data architecture teams that must unify access across multi-modal heterogeneous database estates without replacing the databases themselves.
  • Teams that need sharding, readwrite-splitting, and distributed SQL across existing databases rather than a migration to a new engine.
  • Developers building bespoke data architectures on the pluggable kernel, customising components instead of adopting a fixed product surface.
  • Organisations deploying multi-cloud and wanting to avoid technology binding and vendor lock-in, described in the README as autonomous and controllable.
  • Adopters working in the big data and data pipeline space, indicated by the bigdata, data-pipeline, database-gateway, database-cluster, and distributed-sql-database topics; the repository shows 20,799 stars, 6,900 forks, and 197 open issues.

Getting started

The README excerpt provided does not name an install command, package, Docker image, or compose file; it points to the official website at https://shardingsphere.apache.org/ and to the GitHub releases page at https://github.com/apache/shardingsphere/releases. Start there for the current distribution and deployment instructions.

How it compares

No comparable open-source tool is named in the facts, so on this registry page ShardingSphere stands alone. The README frames its differentiation at the category level: against distributed databases it is described as more lightweight, preserving existing investment and avoiding vendor lock-in; against traditional middleware, as richer in features, larger in ecosystem, and more flexible in architecture; and against cloud vendor solutions, as multi-cloud capable and free of technology binding, at no licence cost under Apache-2.0.

When to use it — and when not

A self-hoster must still run and operate the underlying heterogeneous databases, because ShardingSphere is a layer above them and does not create a database of its own. Teams that want a single self-contained database, or that lack the appetite to operate a database gateway in front of existing engines, should not pick it. The README content available here is positioning-heavy and does not state an install or run procedure, so evaluators should confirm the deployment path, current release, and licence terms directly from the official website and releases page before committing.

project readme (upstream, from github) — read inline

Apache ShardingSphere - Enterprise Distributed Database Ecosystem

Building the standards and ecosystem on top of heterogeneous databases, empowering enterprise data architecture transformation

Official Website: https://shardingsphere.apache.org/

GitHub Release Lines of Code

CI Quality Gate Status Technical Debt Maintainability Rating Security Rating codecov

OpenSSF Best Practices

Gitter

X

OVERVIEW


Apache ShardingSphere is positioned as Database Plus, a standard and ecosystem built on top of heterogeneous databases. As an operating system layer above databases, ShardingSphere does not create new databases but focuses on maximizing the computing capabilities of existing databases, providing unified data access and enhanced computing capabilities.

Database Plus Core Concept: By building a standardized and scalable enhancement layer above databases, it makes heterogeneous databases as simple to use as a single database, providing unified governance capabilities and distributed computing capabilities for enterprise data architectures.

Connect, Enhance, and Pluggable are the three core pillars of Apache ShardingSphere:

  • Connect: Building database upper-layer standards, quickly connecting applications with multi-modal heterogeneous databases through flexible adaptation of database protocols, SQL dialects, and storage formats, providing unified data access experience;

  • Enhance: As a database computing enhancement engine, transparently providing enterprise-grade capabilities including distributed computing (data sharding, readwrite-splitting, SQL federation), data security (encryption, masking, audit), traffic control (circuit breaker, rate limiting), and observability (monitoring, tracing, analysis);

  • Pluggable: Adopting a micro-kernel + 3-layer pluggable architecture to achieve complete decoupling of kernel, functional components, and ecosystem integration. Developers can flexibly customize unique data architecture solutions that meet enterprise needs, just like building with LEGO blocks.

Differentiation Advantages:

  • vs Distributed Databases: More lightweight, protecting existing investments, avoiding vendor lock-in
  • vs Traditional Middleware: Richer features, more complete ecosystem, more flexible architecture
  • vs Cloud Vendor Solutions: Support multi-cloud deployment, avoid technology binding, autonomous and controllable

ShardingSphere became an Apache Top-Level Project on April 16, 2020, and has been adopted by 19,000+ projects worldwide.

DUAL-ACCESS ARCHITECTURE DESIGN


ShardingSphere adopts a unique dual-access architecture design, providing two access ends - JDBC and Proxy - that can be deployed independently or in hybrid deployment, meeting diverse requirements for different scenarios.

ShardingSphere-JDBC: Lightweight Access End

Positioning: Lightweight Java framework, enhanced JDBC driver

Core Features:

  • Client-side direct connection: Shares resources with applications, decentralized architecture
  • High performance, low overhead: Direct database connection with minimal performance loss
  • Complete compatibility: Compatible with all ORM frameworks (MyBatis, JPA, Hibernate, etc.)
  • Zero additional deployment: Provided as JAR package, no independent deployment and dependencies required

Use Cases: High-performance Java applications, integrated deployment with business applications, pursuing ultimate performance

ShardingSphere-Proxy: Enterprise Access End

Positioning: Transparent database proxy, independently deployed server-side

Core Features:

  • Static entry point: Independent deployment from applications, providing stable database access entry
  • Heterogeneous language support: Supports any MySQL/PostgreSQL protocol compatible client
  • DBA friendly: Database operation and maintenance management interface, convenient for O&M personnel
  • Enterprise-grade features: Supports cluster deployment, load balancing, failover

Use Cases: Heterogeneous language environments, database operation and maintenance management, enterprise applications requiring unified access entry

Hybrid Architecture Advantages

By hybridizing ShardingSphere-JDBC and ShardingSphere-Proxy with unified configuration through the same registry center, you can flexibly build application systems suitable for various scenarios:

  • Architectural flexibility: Architects can freely adjust the optimal system architecture
  • Scenario adaptability: Select the most suitable access method according to different business scenarios
  • Unified management: Single configuration, multi-end collaboration, simplifying O&M complexity
  • Progressive evolution: Support smooth evolution path from JDBC to Proxy

AI ABSTRACTION

DeepWiki zread

DOCUMENTATION📜


EN doc CN doc

For full documentation & more details, visit: Docs

CONTRIBUTION🚀🧑💻


For guides on how to get started and setup your environment, contributor & committer guides, visit: Contribution Guidelines

Team


We deeply appreciate community contributors for their dedication to Apache ShardingSphere.

COMMUNITY & SUPPORT💝🖤


:link: Mailing List. Best for: Apache community updates, releases, changes.

:link: GitHub Issues. Best for: design discussions, bug reports, or anything development related.

:link: X. Best for: keeping up to date on everything ShardingSphere.

:link: LinkedIn. Best for: professional networking and career development with other ShardingSphere contributors.

PROJECT STATUS


:white_check_mark: Version 5.5.4-SNAPSHOT: Actively under development :tada:

🔗 For the release notes, follow this link to the relevant GitHub page.

:soon: Version 5.5.4

We are currently developing version 5.5.4, which includes multiple security enhancements and performance optimizations. Keep an eye on the milestones page of this repo for the latest development progress.

comment: (### NIGHTLY BUILDS:)

comment: (A nightly build of ShardingSphere from the latest master branch is available. )

comment: (The package is updated daily and is available [here](http://117.48.121.24:8080).)

comment: (‼️ Notice:)

comment: (Use this nightly build at your own risk! )

comment: (The branch is not always fully tested. )

comment: (The nightly build may contain bugs, and there may be new features added which may cause problems with your environment. )

TECHNICAL ARCHITECTURE EVOLUTION


Apache ShardingSphere adopts a micro-kernel + 3-layer pluggable architecture, achieving complete decoupling of the kernel, functional components, and ecosystem integration, providing developers with ultimate flexibility and extensibility.

Micro-Kernel + 3-Layer Pluggable Model

Core Layer:

  • Query optimizer: Intelligent SQL routing and execution plan optimization
  • Distributed transaction: ACID transaction guarantees and consistency coordination
  • Execution engine: Efficient distributed execution and result aggregation

Feature Layer:

  • Data sharding, readwrite-splitting, federation query
  • Data encryption, data masking, SQL audit
  • Shadow database, observability, traffic control

Ecosystem Layer:

  • Database protocol adaptation (MySQL, PostgreSQL, Oracle, etc.)
  • Registry center integration (ZooKeeper, ETCD, etc.)
  • Configuration management, service discovery, monitoring integration
Technical Innovation Highlights

Complete Decoupling Architecture:

  • Database types completely decoupled, supporting rapid integration of new databases
  • Functional modules completely decoupled, supporting on-demand feature combination

Apache ShardingSphere consists of two access ends - JDBC and Proxy - that can be deployed independently or in hybrid deployment, providing unified distributed database solutions for diverse application scenarios including Java isomorphism, heterogeneous languages, and cloud-native environments.

ShardingSphere-JDBC


Maven Status

A lightweight Java framework providing extra services at the Java JDBC layer. With the client end connecting directly to the database, it provides services in the form of a jar and requires no extra deployment and dependence.

:link: For more details, follow this link to the official website.

Note: When using ShardingSphere-JDBC adapter, pay attention to your application's memory configuration. Antlr uses an internal cache to improve performance during SQL parsing. If your application has too many SQL templates, the cache will continue to grow, occupying a large amount of heap memory. According to feedback from the ANTLR official issue#4232, this issue has not yet been optimized. When connecting your application to ShardingSphere-JDBC, it is recommended to set a reasonable heap memory size using the -Xmx parameter to avoid OOM errors caused by insufficient memory.

ShardingSphere-Proxy


Nightly-Download Download Docker Pulls

A transparent database proxy, providing a database server that encapsulates the database binary protocol to support heterogeneous languages. Friendlier to DBAs, the MariaDB, MySQL and PostgreSQL version now provided can use any kind of terminal.

:link: For more details, follow this link to the official website.

Hybrid Architecture


ShardingSphere-JDBC adopts a decentralized architecture, applicable to high-performance light-weight OLTP applications developed with Java. ShardingSphere-Proxy provides static entry and all languages support, suitable for an OLAP application and sharding databases management and operation.

Through the combination of ShardingSphere-JDBC & ShardingSphere-Proxy together with a unified sharding strategy by the same registry center, the ShardingSphere ecosystem can build an application system suitable to all kinds of scenarios.

:link: More details can be found following this link to the official website.

CORE FEATURE MATRIX


Distributed Database Core Capabilities
  • Data Sharding: Horizontal sharding, vertical sharding, custom sharding strategies, automatic sharding routing
  • Read/Write Splitting: Master-slave replication, load balancing, failover, read weight configuration
  • Distributed Transaction: XA transactions, BASE transactions, transaction propagation
Data Security & Governance
  • Data Encryption: Field-level encryption, transparent encryption, key management, encryption algorithm support
  • Data Masking: Sensitive data protection, masking strategy customization, dynamic masking rules
  • Access Control: Fine-grained permissions, access control, SQL firewall, security policies
Database Gateway Capabilities
  • Heterogeneous Databases: MySQL, PostgreSQL, Oracle, SQL Server, Firebird, etc.
  • SQL Dialect Translation: Cross-database SQL compatibility, dialect adaptation, syntax conversion
  • Protocol Adaptation: Database protocol conversion, multi-protocol support, communication optimization
Full-link Stress Testing & Observability
  • Shadow Database: Stress testing data isolation, environment separation, real data simulation
  • Observability: Performance monitoring, distributed tracing, QoS analysis, metrics collection
  • Traffic Analysis: SQL performance analysis, traffic statistics, bottleneck identification
Enterprise-grade Features
  • High Availability: Cluster deployment, fault recovery, service discovery, health checks
  • Cloud Native: Containerized deployment, Kubernetes integration, native image support
  • Monitoring & Alerting: Real-time monitoring, alert notifications, performance metrics, O&M dashboard

Roadmap


Roadmap

How to Build Apache ShardingSphere


Check out Wiki section for details on how to build Apache ShardingSphere and a full guide on how to get started and setup your local dev environment.

Landscapes




  

Apache ShardingSphere enriches the CNCF CLOUD NATIVE Landscape.

Frequently asked questions

Is shardingsphere free to use?

shardingsphere is open source under the Apache-2.0 licence. There is no licence fee and no seat count — you can self-host it or, where the project offers one, pay a vendor for a managed version instead.

What does shardingsphere do?

Empowering Data Intelligence with Distributed SQL for Sharding, Scalability, and Security Across All Databases.

What is shardingsphere written in?

shardingsphere is primarily written in Java. Its source is publicly available at https://github.com/apache/shardingsphere, and it has 20,817 GitHub stars.