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 2020/07/23 09:57:13 UTC

[shardingsphere] branch master updated: revise docs&sclaing (#6425)

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 5ab9a06  revise docs&sclaing (#6425)
5ab9a06 is described below

commit 5ab9a06d80e4263ab54efac5865bf2456c65920d
Author: kimmking <ki...@163.com>
AuthorDate: Thu Jul 23 17:57:04 2020 +0800

    revise docs&sclaing (#6425)
---
 .../content/features/governance/management/config-center.cn.md     | 4 ++--
 .../content/features/governance/management/config-center.en.md     | 4 ++--
 .../content/quick-start/shardingsphere-scaling-quick-start.cn.md   | 2 +-
 .../content/quick-start/shardingsphere-scaling-quick-start.en.md   | 2 +-
 .../shardingsphere-jdbc/configuration/java-api/governance.cn.md    | 6 +++---
 .../shardingsphere-jdbc/configuration/java-api/governance.en.md    | 6 +++---
 .../type/OrchestrationSpringBootRegistryMasterSlaveTest.java       | 7 ++++---
 .../apache/shardingsphere/scaling/web/HttpServerHandlerTest.java   | 2 +-
 .../src/test/resources/config.json                                 | 2 +-
 shardingsphere-scaling/shardingsphere-scaling-core/pom.xml         | 2 +-
 .../scaling/core/config/utils/ConfigurationYamlConverter.java      | 4 ++--
 .../shardingsphere-scaling-core/src/test/resources/config.json     | 2 +-
 12 files changed, 22 insertions(+), 21 deletions(-)

diff --git a/docs/document/content/features/governance/management/config-center.cn.md b/docs/document/content/features/governance/management/config-center.cn.md
index 1b23f6c..2f2c91d 100644
--- a/docs/document/content/features/governance/management/config-center.cn.md
+++ b/docs/document/content/features/governance/management/config-center.cn.md
@@ -49,7 +49,7 @@ sql.show: true
 多个数据库连接池的集合,不同数据库连接池属性自适配(例如:DBCP,C3P0,Druid, HikariCP)。
 
 ```yaml
-ds_0: !!org.apache.shardingsphere.orchestration.core.configuration.YamlDataSourceConfiguration
+ds_0: !!org.apache.shardingsphere.orchestration.core.common.configuration.YamlDataSourceConfiguration
   dataSourceClassName: com.zaxxer.hikari.HikariDataSource
   props:
     url: jdbc:mysql://127.0.0.1:3306/demo_ds_0?serverTimezone=UTC&useSSL=false
@@ -61,7 +61,7 @@ ds_0: !!org.apache.shardingsphere.orchestration.core.configuration.YamlDataSourc
     minPoolSize: 1
     username: root
     maxLifetimeMilliseconds: 1800000
-ds_1: !!org.apache.shardingsphere.orchestration.core.configuration.YamlDataSourceConfiguration
+ds_1: !!org.apache.shardingsphere.orchestration.core.common.configuration.YamlDataSourceConfiguration
   dataSourceClassName: com.zaxxer.hikari.HikariDataSource
   props:
     url: jdbc:mysql://127.0.0.1:3306/demo_ds_1?serverTimezone=UTC&useSSL=false
diff --git a/docs/document/content/features/governance/management/config-center.en.md b/docs/document/content/features/governance/management/config-center.en.md
index cc0b1c5..da5fcdf 100644
--- a/docs/document/content/features/governance/management/config-center.en.md
+++ b/docs/document/content/features/governance/management/config-center.en.md
@@ -49,7 +49,7 @@ sql.show: true
 A collection of multiple database connection pools, whose properties (e.g. DBCP, C3P0, Druid and HikariCP) are configured by users themselves.
 
 ```yaml
-ds_0: !!org.apache.shardingsphere.orchestration.core.configuration.YamlDataSourceConfiguration
+ds_0: !!org.apache.shardingsphere.orchestration.core.common.configuration.YamlDataSourceConfiguration
   dataSourceClassName: com.zaxxer.hikari.HikariDataSource
   props:
     url: jdbc:mysql://127.0.0.1:3306/demo_ds_0?serverTimezone=UTC&useSSL=false
@@ -61,7 +61,7 @@ ds_0: !!org.apache.shardingsphere.orchestration.core.configuration.YamlDataSourc
     minPoolSize: 1
     username: root
     maxLifetimeMilliseconds: 1800000
-ds_1: !!org.apache.shardingsphere.orchestration.core.configuration.YamlDataSourceConfiguration
+ds_1: !!org.apache.shardingsphere.orchestration.core.common.configuration.YamlDataSourceConfiguration
   dataSourceClassName: com.zaxxer.hikari.HikariDataSource
   props:
     url: jdbc:mysql://127.0.0.1:3306/demo_ds_1?serverTimezone=UTC&useSSL=false
diff --git a/docs/document/content/quick-start/shardingsphere-scaling-quick-start.cn.md b/docs/document/content/quick-start/shardingsphere-scaling-quick-start.cn.md
index 771152a..4c38cf1 100644
--- a/docs/document/content/quick-start/shardingsphere-scaling-quick-start.cn.md
+++ b/docs/document/content/quick-start/shardingsphere-scaling-quick-start.cn.md
@@ -33,7 +33,7 @@ curl -X POST \
   -H 'content-type: application/json' \
   -d '{
    "ruleConfiguration": {
-      "sourceDatasource": "ds_0: !!org.apache.shardingsphere.orchestration.core.configuration.YamlDataSourceConfiguration\n  dataSourceClassName: com.zaxxer.hikari.HikariDataSource\n  props:\n    jdbcUrl: jdbc:mysql://127.0.0.1:3306/test?serverTimezone=UTC&useSSL=false\n    username: root\n    password: '\''123456'\'keyGenerateStrategy
+      "sourceDatasource": "ds_0: !!org.apache.shardingsphere.orchestration.core.common.configuration.YamlDataSourceConfiguration\n  dataSourceClassName: com.zaxxer.hikari.HikariDataSource\n  props:\n    jdbcUrl: jdbc:mysql://127.0.0.1:3306/test?serverTimezone=UTC&useSSL=false\n    username: root\n    password: '\''123456'\'keyGenerateStrategy
 ```
 
 更多管理接口详情请参见[使用手册](/cn/user-manual/shardingsphere-scaling/usage/)。
diff --git a/docs/document/content/quick-start/shardingsphere-scaling-quick-start.en.md b/docs/document/content/quick-start/shardingsphere-scaling-quick-start.en.md
index 0b8f474..851e7d5 100644
--- a/docs/document/content/quick-start/shardingsphere-scaling-quick-start.en.md
+++ b/docs/document/content/quick-start/shardingsphere-scaling-quick-start.en.md
@@ -33,7 +33,7 @@ curl -X POST \
   -H 'content-type: application/json' \
   -d '{
    "ruleConfiguration": {
-      "sourceDatasource": "ds_0: !!org.apache.shardingsphere.orchestration.core.configuration.YamlDataSourceConfiguration\n  dataSourceClassName: com.zaxxer.hikari.HikariDataSource\n  props:\n    jdbcUrl: jdbc:mysql://127.0.0.1:3306/test?serverTimezone=UTC&useSSL=false\n    username: root\n    password: '\''123456'\'keyGenerateStrategy
+      "sourceDatasource": "ds_0: !!org.apache.shardingsphere.orchestration.core.common.configuration.YamlDataSourceConfiguration\n  dataSourceClassName: com.zaxxer.hikari.HikariDataSource\n  props:\n    jdbcUrl: jdbc:mysql://127.0.0.1:3306/test?serverTimezone=UTC&useSSL=false\n    username: root\n    password: '\''123456'\'keyGenerateStrategy
 ```
 
 Please refer to [Configuration Manual](/en/user-manual/shardingsphere-scaling/usage/) for more details. 
diff --git a/docs/document/content/user-manual/shardingsphere-jdbc/configuration/java-api/governance.cn.md b/docs/document/content/user-manual/shardingsphere-jdbc/configuration/java-api/governance.cn.md
index 3a4c833..aa48d40 100644
--- a/docs/document/content/user-manual/shardingsphere-jdbc/configuration/java-api/governance.cn.md
+++ b/docs/document/content/user-manual/shardingsphere-jdbc/configuration/java-api/governance.cn.md
@@ -9,7 +9,7 @@ weight = 6
 
 *配置入口*
 
-类名称:org.apache.shardingsphere.orchestration.center.config.OrchestrationConfiguration
+类名称:org.apache.shardingsphere.orchestration.repository.api.config.OrchestrationConfiguration
 
 可配置属性:
 
@@ -19,7 +19,7 @@ weight = 6
 
 *治理实例配置*
 
-类名称:org.apache.shardingsphere.orchestration.center.config.CenterConfiguration
+类名称:org.apache.shardingsphere.orchestration.repository.api.config.CenterConfiguration
 
 可配置属性:
 
@@ -87,7 +87,7 @@ Nacos 属性配置
 
 *心跳检测配置*
 
-类名称:org.apache.shardingsphere.orchestration.center.config.HeartbeatConfiguration
+类名称:org.apache.shardingsphere.cluster.configuration.config.HeartbeatConfiguration
 
 可配置属性:
 
diff --git a/docs/document/content/user-manual/shardingsphere-jdbc/configuration/java-api/governance.en.md b/docs/document/content/user-manual/shardingsphere-jdbc/configuration/java-api/governance.en.md
index 61e8e83..e763aff 100644
--- a/docs/document/content/user-manual/shardingsphere-jdbc/configuration/java-api/governance.en.md
+++ b/docs/document/content/user-manual/shardingsphere-jdbc/configuration/java-api/governance.en.md
@@ -9,7 +9,7 @@ weight = 6
 
 *Configuration Entrance*
 
-Class name: org.apache.shardingsphere.orchestration.center.config.OrchestrationConfiguration
+Class name: org.apache.shardingsphere.orchestration.repository.api.config.OrchestrationConfiguration
 
 Attributes:
 
@@ -19,7 +19,7 @@ Attributes:
 
 *Orchestration Instance Configuration*
 
-Class name: org.apache.shardingsphere.orchestration.center.config.CenterConfiguration
+Class name: org.apache.shardingsphere.orchestration.repository.api.config.CenterConfiguration
 
 Attributes:
 
@@ -88,7 +88,7 @@ Attributes:
 
 *Heartbeat Detection Configuration*
 
-Class name:org.apache.shardingsphere.orchestration.center.config.HeartbeatConfiguration
+Class name:org.apache.shardingsphere.cluster.configuration.config.HeartbeatConfiguration
 
 Attributes:
 
diff --git a/shardingsphere-jdbc/shardingsphere-jdbc-spring/shardingsphere-jdbc-orchestration-spring/shardingsphere-jdbc-orchestration-spring-boot-starter/src/test/java/org/apache/shardingsphere/spring/boot/orchestration/type/OrchestrationSpringBootRegistryMasterSlaveTest.java b/shardingsphere-jdbc/shardingsphere-jdbc-spring/shardingsphere-jdbc-orchestration-spring/shardingsphere-jdbc-orchestration-spring-boot-starter/src/test/java/org/apache/shardingsphere/spring/boot/orchestration/type/ [...]
index 478242d..f5327f1 100644
--- a/shardingsphere-jdbc/shardingsphere-jdbc-spring/shardingsphere-jdbc-orchestration-spring/shardingsphere-jdbc-orchestration-spring-boot-starter/src/test/java/org/apache/shardingsphere/spring/boot/orchestration/type/OrchestrationSpringBootRegistryMasterSlaveTest.java
+++ b/shardingsphere-jdbc/shardingsphere-jdbc-spring/shardingsphere-jdbc-orchestration-spring/shardingsphere-jdbc-orchestration-spring-boot-starter/src/test/java/org/apache/shardingsphere/spring/boot/orchestration/type/OrchestrationSpringBootRegistryMasterSlaveTest.java
@@ -21,6 +21,7 @@ import lombok.SneakyThrows;
 import org.apache.commons.dbcp2.BasicDataSource;
 import org.apache.shardingsphere.driver.jdbc.core.datasource.ShardingSphereDataSource;
 import org.apache.shardingsphere.driver.orchestration.internal.datasource.OrchestrationShardingSphereDataSource;
+import org.apache.shardingsphere.orchestration.core.common.configuration.YamlDataSourceConfiguration;
 import org.apache.shardingsphere.spring.boot.orchestration.registry.TestCenterRepository;
 import org.apache.shardingsphere.spring.boot.orchestration.util.EmbedTestingServer;
 import org.junit.BeforeClass;
@@ -53,21 +54,21 @@ public class OrchestrationSpringBootRegistryMasterSlaveTest {
         EmbedTestingServer.start();
         TestCenterRepository testCenter = new TestCenterRepository();
         testCenter.persist("/demo_spring_boot_ds_center/config/schema/logic_db/datasource", ""
-                + "ds_master: !!org.apache.shardingsphere.orchestration.core.common.configuration.YamlDataSourceConfiguration\n"
+                + "ds_master: !!" + YamlDataSourceConfiguration.class.getName() + "\n"
                 + "  dataSourceClassName: org.apache.commons.dbcp2.BasicDataSource\n"
                 + "  props:\n"
                 + "    url: jdbc:h2:mem:ds_master;DB_CLOSE_DELAY=-1;DATABASE_TO_UPPER=false;MODE=MYSQL\n"
                 + "    maxTotal: 16\n"
                 + "    password: ''\n"
                 + "    username: root\n"
-                + "ds_slave_0: !!org.apache.shardingsphere.orchestration.core.common.configuration.YamlDataSourceConfiguration\n"
+                + "ds_slave_0: !!" + YamlDataSourceConfiguration.class.getName() + "\n"
                 + "  dataSourceClassName: org.apache.commons.dbcp2.BasicDataSource\n"
                 + "  props:\n"
                 + "    url: jdbc:h2:mem:demo_ds_slave_0;DB_CLOSE_DELAY=-1;DATABASE_TO_UPPER=false;MODE=MYSQL\n"
                 + "    maxTotal: 16\n"
                 + "    password: ''\n"
                 + "    username: root\n"
-                + "ds_slave_1: !!org.apache.shardingsphere.orchestration.core.common.configuration.YamlDataSourceConfiguration\n"
+                + "ds_slave_1: !!" + YamlDataSourceConfiguration.class.getName() + "\n"
                 + "  dataSourceClassName: org.apache.commons.dbcp2.BasicDataSource\n"
                 + "  props:\n"
                 + "    url: jdbc:h2:mem:demo_ds_slave_1;DB_CLOSE_DELAY=-1;DATABASE_TO_UPPER=false;MODE=MYSQL\n"
diff --git a/shardingsphere-scaling/shardingsphere-scaling-bootstrap/src/test/java/org/apache/shardingsphere/scaling/web/HttpServerHandlerTest.java b/shardingsphere-scaling/shardingsphere-scaling-bootstrap/src/test/java/org/apache/shardingsphere/scaling/web/HttpServerHandlerTest.java
index 11f5aa7..b9c1575 100644
--- a/shardingsphere-scaling/shardingsphere-scaling-bootstrap/src/test/java/org/apache/shardingsphere/scaling/web/HttpServerHandlerTest.java
+++ b/shardingsphere-scaling/shardingsphere-scaling-bootstrap/src/test/java/org/apache/shardingsphere/scaling/web/HttpServerHandlerTest.java
@@ -27,7 +27,7 @@ import io.netty.handler.codec.http.FullHttpResponse;
 import io.netty.handler.codec.http.HttpMethod;
 import io.netty.handler.codec.http.HttpVersion;
 import io.netty.util.CharsetUtil;
-import org.apache.shardingsphere.orchestration.core.configuration.YamlDataSourceConfiguration;
+import org.apache.shardingsphere.orchestration.core.common.configuration.YamlDataSourceConfiguration;
 import org.apache.shardingsphere.scaling.core.config.ScalingConfiguration;
 import org.apache.shardingsphere.scaling.core.config.ScalingContext;
 import org.apache.shardingsphere.scaling.core.config.ServerConfiguration;
diff --git a/shardingsphere-scaling/shardingsphere-scaling-bootstrap/src/test/resources/config.json b/shardingsphere-scaling/shardingsphere-scaling-bootstrap/src/test/resources/config.json
index 7c18474..4760ba1 100644
--- a/shardingsphere-scaling/shardingsphere-scaling-bootstrap/src/test/resources/config.json
+++ b/shardingsphere-scaling/shardingsphere-scaling-bootstrap/src/test/resources/config.json
@@ -17,7 +17,7 @@
 
 {
   "ruleConfiguration": {
-    "sourceDatasource": "ds_0: !!org.apache.shardingsphere.orchestration.core.configuration.YamlDataSourceConfiguration\n  dataSourceClassName: com.zaxxer.hikari.HikariDataSource\n  props:\n    jdbcUrl: jdbc:mysql://127.0.0.1:3306/test?serverTimezone=UTC&useSSL=false\n    username: root\n    password: '123456'\n    connectionTimeout: 30000\n    idleTimeout: 60000\n    maxLifetime: 1800000\n    maxPoolSize: 50\n    minPoolSize: 1\n    maintenanceIntervalMilliseconds: 30000\n    readOnly:  [...]
+    "sourceDatasource": "ds_0: !!org.apache.shardingsphere.orchestration.core.common.configuration.YamlDataSourceConfiguration\n  dataSourceClassName: com.zaxxer.hikari.HikariDataSource\n  props:\n    jdbcUrl: jdbc:mysql://127.0.0.1:3306/test?serverTimezone=UTC&useSSL=false\n    username: root\n    password: '123456'\n    connectionTimeout: 30000\n    idleTimeout: 60000\n    maxLifetime: 1800000\n    maxPoolSize: 50\n    minPoolSize: 1\n    maintenanceIntervalMilliseconds: 30000\n    rea [...]
     "sourceRule": "defaultDatabaseStrategy:\n  standard:\n    shardingAlgorithmName: inline\n    shardingColumn: user_id\ntables:\n  t1:\n    actualDataNodes: ds_0.t1\n    keyGenerateStrategy:\n      column: order_id\n    logicTable: t1\n    tableStrategy:\n      standard:\n        shardingAlgorithmName: inline\n        shardingColumn: order_id\n  t2:\n    actualDataNodes: ds_0.t2\n    keyGenerateStrategy:\n      column: order_item_id\n    logicTable: t2\n    tableStrategy:\n      standa [...]
     "destinationDataSources": {
         "name": "dt_0",
diff --git a/shardingsphere-scaling/shardingsphere-scaling-core/pom.xml b/shardingsphere-scaling/shardingsphere-scaling-core/pom.xml
index 38afeb1..f6cb56e 100644
--- a/shardingsphere-scaling/shardingsphere-scaling-core/pom.xml
+++ b/shardingsphere-scaling/shardingsphere-scaling-core/pom.xml
@@ -36,7 +36,7 @@
         </dependency>
         <dependency>
             <groupId>org.apache.shardingsphere</groupId>
-            <artifactId>shardingsphere-orchestration-core-configuration</artifactId>
+            <artifactId>shardingsphere-orchestration-core-common</artifactId>
             <version>${project.version}</version>
         </dependency>
         <dependency>
diff --git a/shardingsphere-scaling/shardingsphere-scaling-core/src/main/java/org/apache/shardingsphere/scaling/core/config/utils/ConfigurationYamlConverter.java b/shardingsphere-scaling/shardingsphere-scaling-core/src/main/java/org/apache/shardingsphere/scaling/core/config/utils/ConfigurationYamlConverter.java
index f3be70a..e16001f 100644
--- a/shardingsphere-scaling/shardingsphere-scaling-core/src/main/java/org/apache/shardingsphere/scaling/core/config/utils/ConfigurationYamlConverter.java
+++ b/shardingsphere-scaling/shardingsphere-scaling-core/src/main/java/org/apache/shardingsphere/scaling/core/config/utils/ConfigurationYamlConverter.java
@@ -21,8 +21,8 @@ import com.google.common.base.Preconditions;
 import com.google.common.collect.Maps;
 import lombok.AccessLevel;
 import lombok.NoArgsConstructor;
-import org.apache.shardingsphere.orchestration.core.configuration.DataSourceConfigurationYamlSwapper;
-import org.apache.shardingsphere.orchestration.core.configuration.YamlDataSourceConfiguration;
+import org.apache.shardingsphere.orchestration.core.common.configuration.DataSourceConfigurationYamlSwapper;
+import org.apache.shardingsphere.orchestration.core.common.configuration.YamlDataSourceConfiguration;
 import org.apache.shardingsphere.sharding.api.config.ShardingRuleConfiguration;
 import org.apache.shardingsphere.sharding.yaml.config.YamlShardingRuleConfiguration;
 import org.apache.shardingsphere.sharding.yaml.swapper.ShardingRuleConfigurationYamlSwapper;
diff --git a/shardingsphere-scaling/shardingsphere-scaling-core/src/test/resources/config.json b/shardingsphere-scaling/shardingsphere-scaling-core/src/test/resources/config.json
index c5f8277..f5fc886 100644
--- a/shardingsphere-scaling/shardingsphere-scaling-core/src/test/resources/config.json
+++ b/shardingsphere-scaling/shardingsphere-scaling-core/src/test/resources/config.json
@@ -17,7 +17,7 @@
 
 {
   "ruleConfiguration": {
-    "sourceDatasource": "ds_0: !!org.apache.shardingsphere.orchestration.core.configuration.YamlDataSourceConfiguration\n  dataSourceClassName: com.zaxxer.hikari.HikariDataSource\n  props:\n    jdbcUrl: jdbc:mysql://127.0.0.1:3306/test?serverTimezone=UTC&useSSL=false\n    username: root\n    password: '123456'\n    connectionTimeout: 30000\n    idleTimeout: 60000\n    maxLifetime: 1800000\n    maxPoolSize: 50\n    minPoolSize: 1\n    maintenanceIntervalMilliseconds: 30000\n    readOnly:  [...]
+    "sourceDatasource": "ds_0: !!org.apache.shardingsphere.orchestration.core.common.configuration.YamlDataSourceConfiguration\n  dataSourceClassName: com.zaxxer.hikari.HikariDataSource\n  props:\n    jdbcUrl: jdbc:mysql://127.0.0.1:3306/test?serverTimezone=UTC&useSSL=false\n    username: root\n    password: '123456'\n    connectionTimeout: 30000\n    idleTimeout: 60000\n    maxLifetime: 1800000\n    maxPoolSize: 50\n    minPoolSize: 1\n    maintenanceIntervalMilliseconds: 30000\n    rea [...]
     "sourceRule": "defaultDatabaseStrategy:\n  standard:\n    shardingAlgorithmName: inline\n    shardingColumn: user_id\ntables:\n  t1:\n    actualDataNodes: ds_0.t1\n    keyGenerateStrategy:\n      column: order_id\n    logicTable: t1\n    tableStrategy:\n      standard:\n        shardingAlgorithmName: inline\n        shardingColumn: order_id\n  t2:\n    actualDataNodes: ds_0.t2\n    keyGenerateStrategy:\n      column: order_item_id\n    logicTable: t2\n    tableStrategy:\n      standa [...]
     "destinationDataSources": {
         "name": "dt_0",