Unverified Commit f8fa7e9e authored by chenqy's avatar chenqy Committed by GitHub
Browse files

Merge pull request #14 from sharding-sphere/dev

update from origin
parents 20c67e61 c8863b07
Loading
Loading
Loading
Loading
+8 −8
Original line number Diff line number Diff line
For English only, other languages we will close it directly.

Please answer these questions before submitting your issue. Thanks!
开源不易,我们希望将精力放在完成新功能和解决有价值的问题上,为了让大家的配合更具有效率,请填写以下列出的全部问题

### Which version of Sharding-Sphere do you using?(您使用的Sharding-Sphere版本为?)
### Which version of Sharding-Sphere do you using?

### Expected behavior (您预期的结果是)
### Expected behavior

### Actual behavior (实际运行的结果是)
### Actual behavior

### Steps to reproduce the behavior (可重现问题的操作步骤)
### Reason analyze

### Please provide the reproduce example codes (such as github link),otherwise we will label the issue as Invalid and close it.(为了节省复现问题的时间,请务必提供可重现的代码,否则我们会将issue直接标记为invalid并关闭)
### Steps to reproduce the behavior

Code should based on https://github.com/sharding-sphere/sharding-sphere-example
(代码请基于 https://github.com/sharding-sphere/sharding-sphere-example)
### Please provide the reproduce example codes (such as a github link).
+29 −30
Original line number Diff line number Diff line
# [Sharding-Sphere - Distributed database middleware ecosphere](http://shardingsphere.io/)
# [Sharding-Sphere - Distributed Database Middleware Ecosphere](http://shardingsphere.io/)

[![License](https://img.shields.io/badge/license-Apache%202-4EB1BA.svg)](https://www.apache.org/licenses/LICENSE-2.0.html)
[![Gitter](https://badges.gitter.im/shardingsphere/shardingsphere.svg)](https://gitter.im/shardingsphere/Lobby)
@@ -18,10 +18,11 @@

## Overview

Sharding-Sphere is an open-sourced distributed database middleware solution suite, which is composite by Sharding-JDBC, Sharding-Proxy and Sharding-Sidecar. Those 3 projects provide consistent features which include data sharding, read-write splitting, orchestration and B.A.S.E transaction. They can suitable for various scenario.
Sharding-Sphere is an open source distributed database middleware solution suite, which consists of Sharding-JDBC, Sharding-Proxy and Sharding-Sidecar. These three sub-projects are suitable for various scenarios and provide consistent functions including data sharding, distributed transaction and database orchestration.

Sharding-Sphere is a Relational Database Middleware which reuse capacity of original databases (such as: compute, storage), but make best simplicity and efficiency on distribute environment. Sharding-Sphere do not want implement a new database.
It can cooperate with NoSQL and NewSQL. NoSQL and NewSQL are good exploration for technology, they are care about what’s going to change. There is another theory which is care about what’s not going to change. Relational Database still is the biggest percentage of market share, it is difficult to estimate trendy in future. So we are focus about how to enhance with Relational Database now.
As a Relational Database Middleware, rather than implementing a new database, Sharding-Sphere is aimed at making the most of original capacities of database (like compute and storage) and making it simpler and more efficient on distribute environment. 
It can cooperate with NoSQL and NewSQL, which keep staying in the cutting edge of technology and recommendable. Meanwhile, Sharding-Sphere focuses on technologies remaining stable and changeless so as to grasp the intrinsic quality. 
Relational Database is still the cornerstone of core business in enterprises and possesses huge market share. It is difficult to estimate trendy in future and now we focus on how to enhance the capacity of Sharding-Sphere with Relational Database.

![Sharding-Sphere Score](http://ovfotjrsi.bkt.clouddn.com/sphere_scope_en.png)

@@ -29,11 +30,12 @@ It can cooperate with NoSQL and NewSQL. NoSQL and NewSQL are good exploration fo

[![Maven Status](https://maven-badges.herokuapp.com/maven-central/io.shardingsphere/sharding-jdbc/badge.svg)](https://maven-badges.herokuapp.com/maven-central/io.shardingsphere/sharding-jdbc)

Use JDBC connect databases without redirect cost for java application, best performance for production.
Sharding-JDBC is positioned as a lightweight Java framework that provides Sharding service in the JDBC layer. 
It directly connects to databases to provide services in the form of jar, with no additional deployment and dependencies, and it can be understood as an enhanced version of the JDBC driver, fully compliant with JDBC and various ORM frameworks.

* ORM compatible. JPA, Hibernate, Mybatis, Spring JDBC Template or JDBC supported.
* Connection-pool compatible. DBCP, C3P0, BoneCP, Druid supported.
* Multi SQL-based databases compatible. Any Database supported theoretically. Support MySQL, Oracle, SQLServer and PostgreSQL right now.
* It is compliant with any Java-based ORM framework, such as JPA, Hibernate, Mybatis and Spring JDBC Template; or you can use JDBC directly.
* It is suitable for connection-pool based on any third party, such as DBCP, C3P0, BoneCP, Druid, HikariCP and so on.
* It supports databases implementing JDBC specification. Supporting MySQL, Oracle, SQLServer and PostgreSQL right now.

![Sharding-JDBC Architecture](http://ovfotjrsi.bkt.clouddn.com/sharding-jdbc-brief.png)

@@ -42,19 +44,21 @@ Use JDBC connect databases without redirect cost for java application, best perf
[![Download](https://img.shields.io/badge/release-download-orange.svg)](https://github.com/sharding-sphere/sharding-sphere-doc/raw/master/dist/sharding-proxy-3.0.0.M1.tar.gz)
[![Docker Pulls](https://img.shields.io/docker/pulls/shardingsphere/sharding-proxy.svg)](https://store.docker.com/community/images/shardingsphere/sharding-proxy)

It is a database proxy. Deploy as a stateless server, support MySQL protocol for now.
Sharding-Proxy is positioned as a transparent database proxy, providing a database server that encapsulates database binary protocol to support heterogeneous languages. 
At present, we provide Sharding-Proxy for MySQL, and you can use any clients compatible with MySQL protocol (such as MySQL Command Client, MySQL Workbench, etc.) to manipulate data.

* Use standard MySQL protocol, application do not care about whether proxy or real MySQL.
* Any MySQL command line and UI workbench supported in theoretically. MySQL Workbench are fully compatible right now.
* It is transparent to application, which can be used as MySQL.
* It is suitable for any clients compatible with MySQL protocol.

![Sharding-Proxy Architecture](http://ovfotjrsi.bkt.clouddn.com/sharding-proxy-brief_v2.png)

### Sharding-Sidecar(TBD)

It can mesh interactions between applications and databases, must run in Kubernetes or Mesos environment.
It is a centre-less solution, can support any languages, we call it as `Database Mesh`.
It is positioned as cloud native database agent of Kubernetes or Mesos environment, in charge of all database access in the form of DaemonSet. 
Through a centre-less and zero-cost solution, it provides mesh layer interacting with database. We call it `Database Mesh`.

Database Mesh is focused on how to connect the distributed data-access-layer and databases together. It pays more attention on interaction, which means the messy interaction among the applications and databases will be effectively orchestrate. By using Database Mesh, applications and databases will form a large grid system, and they just need to be put into the right position on grid system accordingly.
Database Mesh emphasizes how to connect distributed data-access-layer with databases. It pays more attention to interaction, which means the messy interaction between applications and databases will be effectively orchestrated. 
By using Database Mesh, applications and databases will form a large grid system, where they just need to be put into the right position accordingly. They are all governed by mesh layer.

![Sharding-Sidecar Architecture](http://ovfotjrsi.bkt.clouddn.com/sharding-sidecar-brief.png)

@@ -72,27 +76,22 @@ Database Mesh is focused on how to connect the distributed data-access-layer and
### Data sharding

* Both databases and tables sharding.
* Read-write splitting supported.
* Aggregation functions, GROUP BY, ORDER BY, LIMIT, OR, and JOIN DQL supported.
* DML, DDL, TCL and database administrator command supported.
* DML, DDL, TCL and database management command supported.
* Sharding operator `=`, `BETWEEN` and `IN` supported.
* Sharding algorithm customization and inline expression supported.
* Force route by hint.
* Distributed sequence.
* Forced route based on hint.
* Distributed primary key.

### Read-write splitting
### Transaction

* Multiple slaves replica. 
* Data consistency guarantee in same thread.
* Mix read-write splitting and data sharding.
* Force route by hint.
* XA transaction supported.
* Best-Effort-Delivery transaction supported.
* Try-Confirm-Cancel transaction (TBD) supported.

### BASE Transaction
### Database Orchestration

* Best efforts delivery transaction.
* Try confirm cancel transaction (TBD).

### Orchestration

* Configuration center, can refresh dynamically.
* Circuit breaker.
* Configuration center dynamic configuration supported.
* Circuit breaker supported.
* Open tracing supported.
+11 −16
Original line number Diff line number Diff line
@@ -16,7 +16,7 @@

## 概述

Sharding-Sphere是一套开源的分布式数据库中间件解决方案组成的生态圈,它由Sharding-JDBC、Sharding-Proxy和Sharding-Sidecar这3款相互独立的产品组成。他们均提供标准化的数据分片、读写分离、柔性事务和数据治理功能,可适用于如Java同构、异构语言、容器、云原生等各种多样化的应用场景。
Sharding-Sphere是一套开源的分布式数据库中间件解决方案组成的生态圈,它由Sharding-JDBC、Sharding-Proxy和Sharding-Sidecar这3款相互独立的产品组成。他们均提供标准化的数据分片、分布式事务和数据治理功能,可适用于如Java同构、异构语言、容器、云原生等各种多样化的应用场景。

Sharding-Sphere定位为关系型数据库中间件,旨在充分合理地在分布式的场景下利用关系型数据库的计算和存储能力,而并非实现一个全新的关系型数据库。
它与NoSQL和NewSQL是并存而非互斥的关系。NoSQL和NewSQL作为新技术探索的前沿,放眼未来,拥抱变化,是非常值得推荐的。反之,也可以用另一种思路看待问题,放眼未来,关注不变的东西,进而抓住事物本质。关系型数据库当今依然占有巨大市场,是各个公司核心业务的基石,未来也难于撼动,我们目前阶段更加关注在原有基础上的增量,而非颠覆。
@@ -72,6 +72,7 @@ Database Mesh的关注重点在于如何将分布式的数据访问应用与数
### 数据分片

* 分库 + 分表
* 读写分离
* 支持聚合,分组,排序,分页,OR,关联查询等复杂查询语句
* 支持DML,DDL,TCL以及数据库管理语句
* 支持=,BETWEEN,IN的分片操作符
@@ -79,20 +80,14 @@ Database Mesh的关注重点在于如何将分布式的数据访问应用与数
* 基于Hint的强制路由
* 分布式主键

### 读写分离

* 一主多从的读写分离
* 同一线程内的数据一致性
* 支持分库分表与读写分离共同使用
* 基于Hint的强制主库路由

### 柔性事务
### 分布式事务

* XA分布式事务
* 最大努力送达型事务
* TCC型事务(TBD)

### 分布式治理
### 数据库治理

* 配置中心,配置动态化
* 客户端熔断
* 支持Open Tracing协议
* 支持Open Tracing
+3 −0
Original line number Diff line number Diff line
@@ -9,6 +9,8 @@
1. [ISSUE #290](https://github.com/sharding-sphere/sharding-sphere/issues/290) Support batch INSERT statements
1. [ISSUE #501](https://github.com/sharding-sphere/sharding-sphere/issues/501) Support OR statement
1. [ISSUE #862](https://github.com/sharding-sphere/sharding-sphere/issues/862) Support data orchestration in cloud side
1. [ISSUE #980](https://github.com/sharding-sphere/sharding-sphere/issues/980) Support DCL statement
1. [ISSUE #936](https://github.com/sharding-sphere/sharding-sphere/issues/936) Support the registry center for Proxy

### Enhancements

@@ -23,6 +25,7 @@
1. [ISSUE #720](https://github.com/sharding-sphere/sharding-sphere/issues/720) Support Spring bean namespace to inject sharding algorithm objects
1. [ISSUE #773](https://github.com/sharding-sphere/sharding-sphere/issues/773) Support sharding and autoincrement primary key of INSERT statements without column names
1. [ISSUE #916](https://github.com/sharding-sphere/sharding-sphere/issues/916) Support authorization for Sharding Proxy
1. [ISSUE #935](https://github.com/sharding-sphere/sharding-sphere/issues/935) Support to store configuration by using Yaml instead of JSON in registry center.

### Bug Fixes

+3 −0
Original line number Diff line number Diff line
@@ -9,6 +9,8 @@
1. [ISSUE #290](https://github.com/sharding-sphere/sharding-sphere/issues/290) 支持批量INSERT语句
1. [ISSUE #501](https://github.com/sharding-sphere/sharding-sphere/issues/501) 支持OR语句
1. [ISSUE #862](https://github.com/sharding-sphere/sharding-sphere/issues/862) 支持在Cloud端进行数据治理
1. [ISSUE #980](https://github.com/sharding-sphere/sharding-sphere/issues/980) 支持DCL语句
1. [ISSUE #936](https://github.com/sharding-sphere/sharding-sphere/issues/936) 支持Proxy使用注册中心

### 功能提升

@@ -23,6 +25,7 @@
1. [ISSUE #720](https://github.com/sharding-sphere/sharding-sphere/issues/720) 支持Spring bean的方式在命名空间中注入分片算法对象
1. [ISSUE #773](https://github.com/sharding-sphere/sharding-sphere/issues/773) 支持不包含列名的INSERT语句的分片与自增主键
1. [ISSUE #916](https://github.com/sharding-sphere/sharding-sphere/issues/916) 支持Sharding Proxy的登录权限认证
1. [ISSUE #935](https://github.com/sharding-sphere/sharding-sphere/issues/935) 取代JSON格式,而将Yaml格式的配置文件存储在注册中心

### 缺陷修正

Loading