You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@shardingsphere.apache.org by pa...@apache.org on 2021/02/02 11:16:31 UTC

[shardingsphere] branch master updated: Update readme of example (#9276)

This is an automated email from the ASF dual-hosted git repository.

panjuan pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/shardingsphere.git


The following commit(s) were added to refs/heads/master by this push:
     new b1c757f  Update readme of example (#9276)
b1c757f is described below

commit b1c757f0f96b00e394649f228d57f1cea00b1a1e
Author: Liang Zhang <te...@163.com>
AuthorDate: Tue Feb 2 19:16:09 2021 +0800

    Update readme of example (#9276)
    
    * Add mixed rules menu
    
    * Update readme of example
    
    * Update readme of example
---
 examples/README.md    | 44 ++++++++++++++++++++++----------------------
 examples/README_ZH.md | 47 ++++++++++++++++++++++++-----------------------
 2 files changed, 46 insertions(+), 45 deletions(-)

diff --git a/examples/README.md b/examples/README.md
index aed47f4..5ace1ea 100644
--- a/examples/README.md
+++ b/examples/README.md
@@ -4,31 +4,31 @@ Example for 1.x please see tags in `https://github.com/apache/shardingsphere/tre
 
 Example for 2.x or 3.x or 4.x please see tags in `https://github.com/apache/shardingsphere-example/tree/${tag}`
 
-**Need attention**
+**Notices**
 
 - *Please do not use `dev` branch to run your example, example of `dev` branch is not released yet.*
 
-- *The manual schema initial script is in `https://github.com/apache/shardingsphere-example/blob/dev/src/resources/manual_schema.sql`, please execute it before you first run the example.*
+- *Please execute [initial script](https://github.com/apache/shardingsphere/blob/master/examples/src/resources/manual_schema.sql) before you first run the example if using manual mode.*
 
-- *Please make sure primary replica data replication sync on MySQL is running correctly. Otherwise this example will query empty data from the replica.*
+- *Please make sure primary replica data replication sync on MySQL is running correctly. Otherwise, primary-replica example will query empty data from the replica.*
 
-## Before start the example if you want use `dev` branch
+## Using `dev` branch
 
-Please make sure some dependencies from [shardingsphere](https://github.com/apache/shardingsphere) has been installed since some examples depend on that.
-if you are a newbie for shardingsphere, you could prepare the dependencies as following: 
+Please make sure some dependencies from [Apache ShardingSphere](https://github.com/apache/shardingsphere) has been installed since examples depend on that.
+if you are a newbie for Apache ShardingSphere, you could prepare the dependencies as following: 
 
-1.download and install [shardingsphere](https://github.com/apache/shardingsphere): 
+1. download and install [Apache ShardingSphere](https://github.com/apache/shardingsphere): 
 
 ```bash
-## download the code of shardingsphere
+## download source code
 git clone https://github.com/apache/shardingsphere.git
 
-## install the dependencies
+## compile source code
 cd shardingsphere/examples
 mvn clean install -Prelease
 ```
 
-## shardingsphere-example module design
+## Module design
 
 ### project structure
 
@@ -66,15 +66,15 @@ shardingsphere-example
 
 ## Available Examples
 
-| Example | Description |
-|---------|-------------|
-| [sharding](shardingsphere-jdbc-example/sharding-example) | show how to use sharding-table\sharding-database\replica-query with ShardingSphere-JDBC |
-| [springboot jpa](shardingsphere-jdbc-example/sharding-example/sharding-spring-boot-jpa-example) | show how to use SpringBoot JPA with ShardingSphere |
-| [springboot mybatis](shardingsphere-jdbc-example/sharding-example/sharding-spring-boot-mybatis-example) | show how to use SpringBoot Mybatis with ShardingSphere |
-| [governance](shardingsphere-jdbc-example/governance-example) | show how to use ShardingSphere governance |
-| [transaction](shardingsphere-jdbc-example/transaction-example) | show how to use ShardingSphere transaction |
-| [hint](shardingsphere-jdbc-example/other-feature-example/hint-example) | show how to use ShardingSphere hint |
-| [encryption](shardingsphere-jdbc-example/other-feature-example/encrypt-example) | show how to use ShardingSphere encryption |
-| APM(Pending) | show how to use APM in ShardingSphere |
-| proxy(Pending) | show how to use sharding proxy |
-| [docker](./docker/docker-compose.md) | show how to use docker to setup the environment for ShardingSphere |
+| Example                                                                                                 | Description                                                                             |
+|---------------------------------------------------------------------------------------------------------|-----------------------------------------------------------------------------------------|
+| [sharding](shardingsphere-jdbc-example/sharding-example)                                                | show how to use table sharding\database sharding\replica-query with ShardingSphere-JDBC |
+| [springboot jpa](shardingsphere-jdbc-example/sharding-example/sharding-spring-boot-jpa-example)         | show how to use SpringBoot JPA with ShardingSphere-JDBC                                 |
+| [springboot mybatis](shardingsphere-jdbc-example/sharding-example/sharding-spring-boot-mybatis-example) | show how to use SpringBoot Mybatis with ShardingSphere-JDBC                             |
+| [governance](shardingsphere-jdbc-example/governance-example)                                            | show how to use ShardingSphere-JDBC governance                                          |
+| [transaction](shardingsphere-jdbc-example/transaction-example)                                          | show how to use ShardingSphere-JDBC transaction                                         |
+| [hint](shardingsphere-jdbc-example/other-feature-example/hint-example)                                  | show how to use ShardingSphere-JDBC hint                                                |
+| [encryption](shardingsphere-jdbc-example/other-feature-example/encrypt-example)                         | show how to use ShardingSphere-JDBC encryption                                          |
+| APM(Pending)                                                                                            | show how to use APM in ShardingSphere                                                   |
+| proxy(Pending)                                                                                          | show how to use ShardingSphere-Proxy                                                    |
+| [docker](./docker/docker-compose.md)                                                                    | show how to use docker to setup the environment for ShardingSphere                      |
diff --git a/examples/README_ZH.md b/examples/README_ZH.md
index 88bc919..d6eedc0 100644
--- a/examples/README_ZH.md
+++ b/examples/README_ZH.md
@@ -1,33 +1,34 @@
-# ShardingSphere示例
+# Apache ShardingSphere 示例
 
-1.x的示例,请参阅 `https://github.com/apache/shardingsphere/tree/${tag}/shardingsphere-jdbc-example`
+1.x 版本示例,请参阅 `https://github.com/apache/shardingsphere/tree/${tag}/shardingsphere-jdbc-example`
 
-2.x或3.x或4.x的示例,请参见 `https://github.com/apache/shardingsphere-example/tree/${tag}`
+2.x,3.x 或 4.x 版本示例,请参见 `https://github.com/apache/shardingsphere-example/tree/${tag}`
 
-**需要注意**
+**注意事项**
 
 - *请不要使用`dev`分支来运行您的示例,`dev`分支的示例尚未发布。*
 
-- *手动模式初始脚本位于 `https://github.com/apache/shardingsphere-example/blob/dev/src/resources/manual_schema.sql`,请在首次运行示例之前执行它。*
+- *如果采用手动模式,请在首次运行示例之前执行[初始化脚本](https://github.com/apache/shardingsphere/blob/master/examples/src/resources/manual_schema.sql)。*
 
-- *请确保MySQL上的主从数据同步正确运行。否则,此示例查询从库数据将是空。*
+- *请确保MySQL上的主从数据同步正确运行。否则,读写分离示例查询从库数据为空。*
 
-## 如果要使用`dev`分支,请在开始该example之前
+## 使用 `dev` 分支
 
-请确保已安装了来自[shardingsphere](https://github.com/apache/shardingsphere) 的某些依赖项,因为某些示例依赖于此。如果您是shardingsphere的新手,您可以准备如下依赖:
+请在开始该示例之前,请确保已安装了来自 [Apache ShardingSphere](https://github.com/apache/shardingsphere) 的全部依赖项。
+如果您是 ShardingSphere 的新手,您可以准备如下依赖:
 
-1.下载并安装[shardingsphere](https://github.com/apache/shardingsphere):
+1. 下载并安装 [Apache ShardingSphere](https://github.com/apache/shardingsphere): 
 
 ```bash
-## 下载shardingsphere代码
+## 下载源码
 git clone https://github.com/apache/shardingsphere.git
 
-## 安装依赖
+## 编译源码
 cd shardingsphere/examples
 mvn clean install -Prelease
 ```
 
-## shardingsphere-example模块设计
+## 模块设计
 
 ### 项目结构
 
@@ -66,14 +67,14 @@ shardingsphere-example
 ## 用例列表
 
 | 例子 | 描述 |
-|---------|-------------|
-| [分片](shardingsphere-jdbc-example/sharding-example) | 演示了如何通过 ShardingSphere-JDBC 进行分库、分表、主从等 |
-| [springboot jpa](shardingsphere-jdbc-example/sharding-example/sharding-spring-boot-jpa-example) | 演示了如何通过 SpringBoot JPA 对接 ShardingSphere |
-| [springboot mybatis](shardingsphere-jdbc-example/sharding-example/sharding-spring-boot-mybatis-example) | 演示了如何通过 SpringBoot Mybatis 对接 ShardingSphere |
-| [governance](shardingsphere-jdbc-example/governance-example) | 演示了如何在 ShardingSphere 中使用 governance |
-| [事务](shardingsphere-jdbc-example/transaction-example) | 演示了如何在 ShardingSphere 中使用事务 |
-| [hint](shardingsphere-jdbc-example/other-feature-example/hint-example) | 演示了如何在 ShardingSphere 中使用 hint |
-| [加密](shardingsphere-jdbc-example/other-feature-example/encrypt-example) | 演示了如何在 ShardingSphere 中使用加密 |
-| APM监控(Pending) | 演示了如何在 ShardingSphere 中使用 APM 监控 |
-| proxy(Pending) | 演示了如何使用 sharding proxy |
-| [docker](./docker/docker-compose.md) | 演示了如何通过 docker 创建 ShardingSphere 所依赖的环境 |
+|--------------------------------------------------------------------------------------------------------|-------------------------------------------------------|
+| [分片](shardingsphere-jdbc-example/sharding-example)                                                    | 演示通过 ShardingSphere-JDBC 进行分库、分表、主从等      |
+| [springboot jpa](shardingsphere-jdbc-example/sharding-example/sharding-spring-boot-jpa-example)         | 演示通过 SpringBoot JPA 对接 ShardingSphere-JDBC      |
+| [springboot mybatis](shardingsphere-jdbc-example/sharding-example/sharding-spring-boot-mybatis-example) | 演示通过 SpringBoot Mybatis 对接 ShardingSphere-JDBC  |
+| [治理](shardingsphere-jdbc-example/governance-example)                                                  | 演示在 ShardingSphere-JDBC 中使用治理                  |
+| [事务](shardingsphere-jdbc-example/transaction-example)                                                 | 演示在 ShardingSphere-JDBC 中使用事务                  |
+| [hint](shardingsphere-jdbc-example/other-feature-example/hint-example)                                  | 演示在 ShardingSphere-JDBC 中使用 hint                |
+| [加密](shardingsphere-jdbc-example/other-feature-example/encrypt-example)                               | 演示在 ShardingSphere-JDBC 中使用加密                  |
+| APM监控(Pending)                                                                                        | 演示在 ShardingSphere 中使用 APM 监控                  |
+| proxy(Pending)                                                                                          | 演示使用 ShardingSphere-Proxy                         |
+| [docker](./docker/docker-compose.md)                                                                    | 演示通过 docker 创建 ShardingSphere 所依赖的环境        |