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

zhonghongsheng 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 6e830cc0438 Remove binding table at scaling it. (#17873)
6e830cc0438 is described below

commit 6e830cc043867a33e6d420792bdf6a63073e622d
Author: azexcy <[email protected]>
AuthorDate: Mon May 23 16:18:15 2022 +0800

    Remove binding table at scaling it. (#17873)
---
 .../integration/data/pipeline/cases/base/BaseITCase.java              | 2 +-
 .../integration/data/pipeline/cases/command/CommonSQLCommand.java     | 4 ++--
 .../data/pipeline/cases/general/MySQLGeneralScalingIT.java            | 3 +--
 .../data/pipeline/cases/general/PostgreSQLGeneralScalingIT.java       | 3 +--
 .../src/test/resources/env/common/command.xml                         | 4 ++--
 5 files changed, 7 insertions(+), 9 deletions(-)

diff --git 
a/shardingsphere-test/shardingsphere-integration-test/shardingsphere-integration-test-scaling/src/test/java/org/apache/shardingsphere/integration/data/pipeline/cases/base/BaseITCase.java
 
b/shardingsphere-test/shardingsphere-integration-test/shardingsphere-integration-test-scaling/src/test/java/org/apache/shardingsphere/integration/data/pipeline/cases/base/BaseITCase.java
index af08177c3c6..58189d4406a 100644
--- 
a/shardingsphere-test/shardingsphere-integration-test/shardingsphere-integration-test-scaling/src/test/java/org/apache/shardingsphere/integration/data/pipeline/cases/base/BaseITCase.java
+++ 
b/shardingsphere-test/shardingsphere-integration-test/shardingsphere-integration-test-scaling/src/test/java/org/apache/shardingsphere/integration/data/pipeline/cases/base/BaseITCase.java
@@ -230,7 +230,7 @@ public abstract class BaseITCase {
         Object jobId = scalingListMap.get(0).get("id");
         log.info("jobId: {}", jobId);
         Map<String, String> actualStatusMap = new HashMap<>(2, 1);
-        for (int i = 0; i < 100; i++) {
+        for (int i = 0; i < 15; i++) {
             List<Map<String, Object>> showScalingStatusResMap = 
jdbcTemplate.queryForList(String.format("SHOW SCALING STATUS %s", jobId));
             log.info("actualStatusMap: {}", actualStatusMap);
             boolean finished = true;
diff --git 
a/shardingsphere-test/shardingsphere-integration-test/shardingsphere-integration-test-scaling/src/test/java/org/apache/shardingsphere/integration/data/pipeline/cases/command/CommonSQLCommand.java
 
b/shardingsphere-test/shardingsphere-integration-test/shardingsphere-integration-test-scaling/src/test/java/org/apache/shardingsphere/integration/data/pipeline/cases/command/CommonSQLCommand.java
index 4b2a9bf78cf..5c132e4cda1 100644
--- 
a/shardingsphere-test/shardingsphere-integration-test/shardingsphere-integration-test-scaling/src/test/java/org/apache/shardingsphere/integration/data/pipeline/cases/command/CommonSQLCommand.java
+++ 
b/shardingsphere-test/shardingsphere-integration-test/shardingsphere-integration-test-scaling/src/test/java/org/apache/shardingsphere/integration/data/pipeline/cases/command/CommonSQLCommand.java
@@ -50,8 +50,8 @@ public final class CommonSQLCommand {
     @XmlElement(name = "alter-sharding-table-rule")
     private String alterShardingTableRule;
     
-    @XmlElement(name = "auto-alter-all-sharding-table-rule")
-    private String autoAlterAllShardingTableRule;
+    @XmlElement(name = "auto-alter-order-with-item-sharding-table-rule")
+    private String autoAlterOrderWithItemShardingTableRule;
     
     @XmlElement(name = "auto-alter-order-sharding-table-rule")
     private String autoAlterOrderShardingTableRule;
diff --git 
a/shardingsphere-test/shardingsphere-integration-test/shardingsphere-integration-test-scaling/src/test/java/org/apache/shardingsphere/integration/data/pipeline/cases/general/MySQLGeneralScalingIT.java
 
b/shardingsphere-test/shardingsphere-integration-test/shardingsphere-integration-test-scaling/src/test/java/org/apache/shardingsphere/integration/data/pipeline/cases/general/MySQLGeneralScalingIT.java
index 4d5573aa0d1..1625f0a7ff1 100644
--- 
a/shardingsphere-test/shardingsphere-integration-test/shardingsphere-integration-test-scaling/src/test/java/org/apache/shardingsphere/integration/data/pipeline/cases/general/MySQLGeneralScalingIT.java
+++ 
b/shardingsphere-test/shardingsphere-integration-test/shardingsphere-integration-test-scaling/src/test/java/org/apache/shardingsphere/integration/data/pipeline/cases/general/MySQLGeneralScalingIT.java
@@ -70,7 +70,6 @@ public final class MySQLGeneralScalingIT extends 
BaseExtraSQLITCase {
         assertTrue(waitShardingAlgorithmEffect(15));
         createScalingRule();
         createAllSharingTableRule();
-        bindingShardingRule();
         createNoUseTable();
         createOrderTable();
         createOrderItemTable();
@@ -81,7 +80,7 @@ public final class MySQLGeneralScalingIT extends 
BaseExtraSQLITCase {
         startIncrementTask(new MySQLIncrementTask(getJdbcTemplate(), 
keyGenerateAlgorithm, true));
         assertOriginalSourceSuccess();
         addTargetResource();
-        
getJdbcTemplate().execute(getCommonSQLCommand().getAutoAlterAllShardingTableRule());
+        
getJdbcTemplate().execute(getCommonSQLCommand().getAutoAlterOrderWithItemShardingTableRule());
         assertCheckMatchConsistencySuccess();
     }
 }
diff --git 
a/shardingsphere-test/shardingsphere-integration-test/shardingsphere-integration-test-scaling/src/test/java/org/apache/shardingsphere/integration/data/pipeline/cases/general/PostgreSQLGeneralScalingIT.java
 
b/shardingsphere-test/shardingsphere-integration-test/shardingsphere-integration-test-scaling/src/test/java/org/apache/shardingsphere/integration/data/pipeline/cases/general/PostgreSQLGeneralScalingIT.java
index dcb0b58747d..0ebb764c4f0 100644
--- 
a/shardingsphere-test/shardingsphere-integration-test/shardingsphere-integration-test-scaling/src/test/java/org/apache/shardingsphere/integration/data/pipeline/cases/general/PostgreSQLGeneralScalingIT.java
+++ 
b/shardingsphere-test/shardingsphere-integration-test/shardingsphere-integration-test-scaling/src/test/java/org/apache/shardingsphere/integration/data/pipeline/cases/general/PostgreSQLGeneralScalingIT.java
@@ -75,7 +75,6 @@ public final class PostgreSQLGeneralScalingIT extends 
BaseExtraSQLITCase {
         createScalingRule();
         createSchema("test");
         createAllSharingTableRule();
-        bindingShardingRule();
         createOrderTable();
         createOrderItemTable();
         SnowflakeKeyGenerateAlgorithm keyGenerateAlgorithm = new 
SnowflakeKeyGenerateAlgorithm();
@@ -85,7 +84,7 @@ public final class PostgreSQLGeneralScalingIT extends 
BaseExtraSQLITCase {
         startIncrementTask(new PostgreSQLIncrementTask(getJdbcTemplate(), new 
SnowflakeKeyGenerateAlgorithm(), "test", true));
         assertOriginalSourceSuccess();
         addTargetResource();
-        
getJdbcTemplate().execute(getCommonSQLCommand().getAutoAlterAllShardingTableRule());
+        
getJdbcTemplate().execute(getCommonSQLCommand().getAutoAlterOrderWithItemShardingTableRule());
         assertCheckMatchConsistencySuccess();
     }
 }
diff --git 
a/shardingsphere-test/shardingsphere-integration-test/shardingsphere-integration-test-scaling/src/test/resources/env/common/command.xml
 
b/shardingsphere-test/shardingsphere-integration-test/shardingsphere-integration-test-scaling/src/test/resources/env/common/command.xml
index c142b08a428..4aaa74c549a 100644
--- 
a/shardingsphere-test/shardingsphere-integration-test/shardingsphere-integration-test-scaling/src/test/resources/env/common/command.xml
+++ 
b/shardingsphere-test/shardingsphere-integration-test/shardingsphere-integration-test-scaling/src/test/resources/env/common/command.xml
@@ -72,7 +72,7 @@
         KEY_GENERATE_STRATEGY(COLUMN=order_id,TYPE(NAME=snowflake)))
     </alter-sharding-table-rule>
     
-    <auto-alter-all-sharding-table-rule>
+    <auto-alter-order-with-item-sharding-table-rule>
         ALTER SHARDING TABLE RULE t_order(
         RESOURCES(ds_2, ds_3, ds_4),
         SHARDING_COLUMN=order_id,
@@ -84,7 +84,7 @@
         TYPE(NAME=hash_mod,PROPERTIES("sharding-count"=6)),
         KEY_GENERATE_STRATEGY(COLUMN=order_id,TYPE(NAME=snowflake))
         )
-    </auto-alter-all-sharding-table-rule>
+    </auto-alter-order-with-item-sharding-table-rule>
     
     <auto-alter-order-sharding-table-rule>
         ALTER SHARDING TABLE RULE t_order(

Reply via email to