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 9047fc2577b Refactor DatabaseRuleRDLExecutor (#29781)
9047fc2577b is described below
commit 9047fc2577beb22bc771a38907d985aa0e7594cc
Author: Liang Zhang <[email protected]>
AuthorDate: Fri Jan 19 21:13:35 2024 +0800
Refactor DatabaseRuleRDLExecutor (#29781)
---
.../update/CreateBroadcastTableRuleExecutor.java | 4 ++--
.../update/DropBroadcastTableRuleExecutor.java | 4 ++--
.../handler/update/AlterEncryptRuleExecutor.java | 4 ++--
.../handler/update/CreateEncryptRuleExecutor.java | 4 ++--
.../handler/update/DropEncryptRuleExecutor.java | 4 ++--
.../handler/update/AlterMaskRuleExecutor.java | 4 ++--
.../handler/update/CreateMaskRuleExecutor.java | 4 ++--
.../handler/update/DropMaskRuleExecutor.java | 4 ++--
.../AlterReadwriteSplittingRuleExecutor.java | 4 ++--
.../CreateReadwriteSplittingRuleExecutor.java | 4 ++--
.../update/DropReadwriteSplittingRuleExecutor.java | 4 ++--
.../AlterDefaultShadowAlgorithmExecutor.java | 4 ++--
.../handler/update/AlterShadowRuleExecutor.java | 4 ++--
.../CreateDefaultShadowAlgorithmExecutor.java | 4 ++--
.../handler/update/CreateShadowRuleExecutor.java | 4 ++--
.../update/DropDefaultShadowAlgorithmExecutor.java | 4 ++--
.../update/DropShadowAlgorithmExecutor.java | 4 ++--
.../handler/update/DropShadowRuleExecutor.java | 4 ++--
.../AlterDefaultShardingStrategyExecutor.java | 4 ++--
.../AlterShardingTableReferenceRuleExecutor.java | 4 ++--
.../update/AlterShardingTableRuleExecutor.java | 4 ++--
.../CreateDefaultShardingStrategyExecutor.java | 4 ++--
.../CreateShardingTableReferenceRuleExecutor.java | 4 ++--
.../update/CreateShardingTableRuleExecutor.java | 4 ++--
.../DropDefaultShardingStrategyExecutor.java | 4 ++--
.../update/DropShardingAlgorithmExecutor.java | 4 ++--
.../update/DropShardingAuditorExecutor.java | 4 ++--
.../update/DropShardingKeyGeneratorExecutor.java | 4 ++--
.../update/DropShardingTableReferenceExecutor.java | 4 ++--
.../update/DropShardingTableRuleExecutor.java | 4 ++--
.../query/ConvertRuleConfigurationProvider.java | 8 +++----
...utor.java => DatabaseRuleRDLAlterExecutor.java} | 4 ++--
...tor.java => DatabaseRuleRDLCreateExecutor.java} | 4 ++--
...cutor.java => DatabaseRuleRDLDropExecutor.java} | 4 ++--
.../handler/update/LoadSingleTableExecutor.java | 4 ++--
.../SetDefaultSingleTableStorageUnitExecutor.java | 4 ++--
.../handler/update/UnloadSingleTableExecutor.java | 4 ++--
.../rdl/rule/NewRuleDefinitionBackendHandler.java | 28 ++++++++++++----------
.../rdl/rule/RuleDefinitionBackendHandler.java | 26 ++++++++++----------
.../fixture/FixtureDatabaseRuleCreateExecutor.java | 4 ++--
40 files changed, 105 insertions(+), 105 deletions(-)
diff --git
a/features/broadcast/distsql/handler/src/main/java/org/apache/shardingsphere/broadcast/distsql/handler/update/CreateBroadcastTableRuleExecutor.java
b/features/broadcast/distsql/handler/src/main/java/org/apache/shardingsphere/broadcast/distsql/handler/update/CreateBroadcastTableRuleExecutor.java
index 0d45de201dc..3cfc4aa6dd9 100644
---
a/features/broadcast/distsql/handler/src/main/java/org/apache/shardingsphere/broadcast/distsql/handler/update/CreateBroadcastTableRuleExecutor.java
+++
b/features/broadcast/distsql/handler/src/main/java/org/apache/shardingsphere/broadcast/distsql/handler/update/CreateBroadcastTableRuleExecutor.java
@@ -21,7 +21,7 @@ import
org.apache.shardingsphere.broadcast.api.config.BroadcastRuleConfiguration
import
org.apache.shardingsphere.broadcast.distsql.statement.CreateBroadcastTableRuleStatement;
import
org.apache.shardingsphere.distsql.handler.exception.rule.DuplicateRuleException;
import
org.apache.shardingsphere.distsql.handler.exception.storageunit.EmptyStorageUnitException;
-import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleCreateExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleRDLCreateExecutor;
import
org.apache.shardingsphere.infra.exception.core.ShardingSpherePreconditions;
import
org.apache.shardingsphere.infra.metadata.database.ShardingSphereDatabase;
@@ -31,7 +31,7 @@ import java.util.LinkedHashSet;
/**
* Create broadcast table rule executor.
*/
-public final class CreateBroadcastTableRuleExecutor implements
DatabaseRuleCreateExecutor<CreateBroadcastTableRuleStatement,
BroadcastRuleConfiguration> {
+public final class CreateBroadcastTableRuleExecutor implements
DatabaseRuleRDLCreateExecutor<CreateBroadcastTableRuleStatement,
BroadcastRuleConfiguration> {
@Override
public void checkSQLStatement(final ShardingSphereDatabase database, final
CreateBroadcastTableRuleStatement sqlStatement, final
BroadcastRuleConfiguration currentRuleConfig) {
diff --git
a/features/broadcast/distsql/handler/src/main/java/org/apache/shardingsphere/broadcast/distsql/handler/update/DropBroadcastTableRuleExecutor.java
b/features/broadcast/distsql/handler/src/main/java/org/apache/shardingsphere/broadcast/distsql/handler/update/DropBroadcastTableRuleExecutor.java
index 75d141f8fe8..8914e454605 100644
---
a/features/broadcast/distsql/handler/src/main/java/org/apache/shardingsphere/broadcast/distsql/handler/update/DropBroadcastTableRuleExecutor.java
+++
b/features/broadcast/distsql/handler/src/main/java/org/apache/shardingsphere/broadcast/distsql/handler/update/DropBroadcastTableRuleExecutor.java
@@ -20,7 +20,7 @@ package
org.apache.shardingsphere.broadcast.distsql.handler.update;
import
org.apache.shardingsphere.broadcast.api.config.BroadcastRuleConfiguration;
import
org.apache.shardingsphere.broadcast.distsql.statement.DropBroadcastTableRuleStatement;
import
org.apache.shardingsphere.distsql.handler.exception.rule.MissingRequiredRuleException;
-import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleDropExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleRDLDropExecutor;
import
org.apache.shardingsphere.infra.metadata.database.ShardingSphereDatabase;
import
org.apache.shardingsphere.infra.exception.core.ShardingSpherePreconditions;
@@ -31,7 +31,7 @@ import java.util.stream.Collectors;
/**
* Drop broadcast table rule executor.
*/
-public final class DropBroadcastTableRuleExecutor implements
DatabaseRuleDropExecutor<DropBroadcastTableRuleStatement,
BroadcastRuleConfiguration> {
+public final class DropBroadcastTableRuleExecutor implements
DatabaseRuleRDLDropExecutor<DropBroadcastTableRuleStatement,
BroadcastRuleConfiguration> {
@Override
public void checkSQLStatement(final ShardingSphereDatabase database, final
DropBroadcastTableRuleStatement sqlStatement, final BroadcastRuleConfiguration
currentRuleConfig) {
diff --git
a/features/encrypt/distsql/handler/src/main/java/org/apache/shardingsphere/encrypt/distsql/handler/update/AlterEncryptRuleExecutor.java
b/features/encrypt/distsql/handler/src/main/java/org/apache/shardingsphere/encrypt/distsql/handler/update/AlterEncryptRuleExecutor.java
index 2c7757006b7..2eecd18464d 100644
---
a/features/encrypt/distsql/handler/src/main/java/org/apache/shardingsphere/encrypt/distsql/handler/update/AlterEncryptRuleExecutor.java
+++
b/features/encrypt/distsql/handler/src/main/java/org/apache/shardingsphere/encrypt/distsql/handler/update/AlterEncryptRuleExecutor.java
@@ -20,7 +20,7 @@ package
org.apache.shardingsphere.encrypt.distsql.handler.update;
import com.google.common.base.Preconditions;
import
org.apache.shardingsphere.distsql.handler.exception.rule.InvalidRuleConfigurationException;
import
org.apache.shardingsphere.distsql.handler.exception.rule.MissingRequiredRuleException;
-import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleAlterExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleRDLAlterExecutor;
import org.apache.shardingsphere.distsql.segment.AlgorithmSegment;
import org.apache.shardingsphere.encrypt.api.config.EncryptRuleConfiguration;
import
org.apache.shardingsphere.encrypt.api.config.rule.EncryptColumnItemRuleConfiguration;
@@ -42,7 +42,7 @@ import java.util.stream.Collectors;
/**
* Alter encrypt rule executor.
*/
-public final class AlterEncryptRuleExecutor implements
DatabaseRuleAlterExecutor<AlterEncryptRuleStatement, EncryptRuleConfiguration> {
+public final class AlterEncryptRuleExecutor implements
DatabaseRuleRDLAlterExecutor<AlterEncryptRuleStatement,
EncryptRuleConfiguration> {
@Override
public void checkSQLStatement(final ShardingSphereDatabase database, final
AlterEncryptRuleStatement sqlStatement, final EncryptRuleConfiguration
currentRuleConfig) {
diff --git
a/features/encrypt/distsql/handler/src/main/java/org/apache/shardingsphere/encrypt/distsql/handler/update/CreateEncryptRuleExecutor.java
b/features/encrypt/distsql/handler/src/main/java/org/apache/shardingsphere/encrypt/distsql/handler/update/CreateEncryptRuleExecutor.java
index adbf03641b0..28f2a0be51d 100644
---
a/features/encrypt/distsql/handler/src/main/java/org/apache/shardingsphere/encrypt/distsql/handler/update/CreateEncryptRuleExecutor.java
+++
b/features/encrypt/distsql/handler/src/main/java/org/apache/shardingsphere/encrypt/distsql/handler/update/CreateEncryptRuleExecutor.java
@@ -21,7 +21,7 @@ import
org.apache.shardingsphere.distsql.handler.exception.algorithm.InvalidAlgo
import
org.apache.shardingsphere.distsql.handler.exception.rule.DuplicateRuleException;
import
org.apache.shardingsphere.distsql.handler.exception.rule.InvalidRuleConfigurationException;
import
org.apache.shardingsphere.distsql.handler.exception.storageunit.EmptyStorageUnitException;
-import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleCreateExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleRDLCreateExecutor;
import org.apache.shardingsphere.distsql.segment.AlgorithmSegment;
import org.apache.shardingsphere.encrypt.api.config.EncryptRuleConfiguration;
import
org.apache.shardingsphere.encrypt.api.config.rule.EncryptTableRuleConfiguration;
@@ -42,7 +42,7 @@ import java.util.stream.Collectors;
/**
* Create encrypt rule executor.
*/
-public final class CreateEncryptRuleExecutor implements
DatabaseRuleCreateExecutor<CreateEncryptRuleStatement,
EncryptRuleConfiguration> {
+public final class CreateEncryptRuleExecutor implements
DatabaseRuleRDLCreateExecutor<CreateEncryptRuleStatement,
EncryptRuleConfiguration> {
@Override
public void checkSQLStatement(final ShardingSphereDatabase database, final
CreateEncryptRuleStatement sqlStatement, final EncryptRuleConfiguration
currentRuleConfig) {
diff --git
a/features/encrypt/distsql/handler/src/main/java/org/apache/shardingsphere/encrypt/distsql/handler/update/DropEncryptRuleExecutor.java
b/features/encrypt/distsql/handler/src/main/java/org/apache/shardingsphere/encrypt/distsql/handler/update/DropEncryptRuleExecutor.java
index 8177acafeb5..7dfdb0722e8 100644
---
a/features/encrypt/distsql/handler/src/main/java/org/apache/shardingsphere/encrypt/distsql/handler/update/DropEncryptRuleExecutor.java
+++
b/features/encrypt/distsql/handler/src/main/java/org/apache/shardingsphere/encrypt/distsql/handler/update/DropEncryptRuleExecutor.java
@@ -18,7 +18,7 @@
package org.apache.shardingsphere.encrypt.distsql.handler.update;
import
org.apache.shardingsphere.distsql.handler.exception.rule.MissingRequiredRuleException;
-import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleDropExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleRDLDropExecutor;
import org.apache.shardingsphere.encrypt.api.config.EncryptRuleConfiguration;
import
org.apache.shardingsphere.encrypt.api.config.rule.EncryptColumnItemRuleConfiguration;
import
org.apache.shardingsphere.encrypt.api.config.rule.EncryptTableRuleConfiguration;
@@ -38,7 +38,7 @@ import java.util.stream.Collectors;
/**
* Drop encrypt rule executor.
*/
-public final class DropEncryptRuleExecutor implements
DatabaseRuleDropExecutor<DropEncryptRuleStatement, EncryptRuleConfiguration> {
+public final class DropEncryptRuleExecutor implements
DatabaseRuleRDLDropExecutor<DropEncryptRuleStatement, EncryptRuleConfiguration>
{
@Override
public void checkSQLStatement(final ShardingSphereDatabase database, final
DropEncryptRuleStatement sqlStatement, final EncryptRuleConfiguration
currentRuleConfig) {
diff --git
a/features/mask/distsql/handler/src/main/java/org/apache/shardingsphere/mask/distsql/handler/update/AlterMaskRuleExecutor.java
b/features/mask/distsql/handler/src/main/java/org/apache/shardingsphere/mask/distsql/handler/update/AlterMaskRuleExecutor.java
index 132cdf4ee95..4251f299e81 100644
---
a/features/mask/distsql/handler/src/main/java/org/apache/shardingsphere/mask/distsql/handler/update/AlterMaskRuleExecutor.java
+++
b/features/mask/distsql/handler/src/main/java/org/apache/shardingsphere/mask/distsql/handler/update/AlterMaskRuleExecutor.java
@@ -18,7 +18,7 @@
package org.apache.shardingsphere.mask.distsql.handler.update;
import
org.apache.shardingsphere.distsql.handler.exception.rule.MissingRequiredRuleException;
-import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleAlterExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleRDLAlterExecutor;
import org.apache.shardingsphere.infra.config.algorithm.AlgorithmConfiguration;
import
org.apache.shardingsphere.infra.metadata.database.ShardingSphereDatabase;
import
org.apache.shardingsphere.infra.exception.core.ShardingSpherePreconditions;
@@ -38,7 +38,7 @@ import java.util.stream.Collectors;
/**
* Alter mask rule executor.
*/
-public final class AlterMaskRuleExecutor implements
DatabaseRuleAlterExecutor<AlterMaskRuleStatement, MaskRuleConfiguration> {
+public final class AlterMaskRuleExecutor implements
DatabaseRuleRDLAlterExecutor<AlterMaskRuleStatement, MaskRuleConfiguration> {
@Override
public void checkSQLStatement(final ShardingSphereDatabase database, final
AlterMaskRuleStatement sqlStatement, final MaskRuleConfiguration
currentRuleConfig) {
diff --git
a/features/mask/distsql/handler/src/main/java/org/apache/shardingsphere/mask/distsql/handler/update/CreateMaskRuleExecutor.java
b/features/mask/distsql/handler/src/main/java/org/apache/shardingsphere/mask/distsql/handler/update/CreateMaskRuleExecutor.java
index e7645e8cbc6..1a6ab8a5728 100644
---
a/features/mask/distsql/handler/src/main/java/org/apache/shardingsphere/mask/distsql/handler/update/CreateMaskRuleExecutor.java
+++
b/features/mask/distsql/handler/src/main/java/org/apache/shardingsphere/mask/distsql/handler/update/CreateMaskRuleExecutor.java
@@ -18,7 +18,7 @@
package org.apache.shardingsphere.mask.distsql.handler.update;
import
org.apache.shardingsphere.distsql.handler.exception.rule.DuplicateRuleException;
-import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleCreateExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleRDLCreateExecutor;
import
org.apache.shardingsphere.infra.metadata.database.ShardingSphereDatabase;
import
org.apache.shardingsphere.infra.exception.core.ShardingSpherePreconditions;
import org.apache.shardingsphere.infra.spi.type.typed.TypedSPILoader;
@@ -38,7 +38,7 @@ import java.util.stream.Collectors;
/**
* Create mask rule executor.
*/
-public final class CreateMaskRuleExecutor implements
DatabaseRuleCreateExecutor<CreateMaskRuleStatement, MaskRuleConfiguration> {
+public final class CreateMaskRuleExecutor implements
DatabaseRuleRDLCreateExecutor<CreateMaskRuleStatement, MaskRuleConfiguration> {
private boolean ifNotExists;
diff --git
a/features/mask/distsql/handler/src/main/java/org/apache/shardingsphere/mask/distsql/handler/update/DropMaskRuleExecutor.java
b/features/mask/distsql/handler/src/main/java/org/apache/shardingsphere/mask/distsql/handler/update/DropMaskRuleExecutor.java
index 468b3e710d8..11597754335 100644
---
a/features/mask/distsql/handler/src/main/java/org/apache/shardingsphere/mask/distsql/handler/update/DropMaskRuleExecutor.java
+++
b/features/mask/distsql/handler/src/main/java/org/apache/shardingsphere/mask/distsql/handler/update/DropMaskRuleExecutor.java
@@ -18,7 +18,7 @@
package org.apache.shardingsphere.mask.distsql.handler.update;
import
org.apache.shardingsphere.distsql.handler.exception.rule.MissingRequiredRuleException;
-import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleDropExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleRDLDropExecutor;
import org.apache.shardingsphere.infra.config.algorithm.AlgorithmConfiguration;
import
org.apache.shardingsphere.infra.metadata.database.ShardingSphereDatabase;
import
org.apache.shardingsphere.infra.exception.core.ShardingSpherePreconditions;
@@ -38,7 +38,7 @@ import java.util.stream.Collectors;
/**
* Drop mask rule statement executor.
*/
-public final class DropMaskRuleExecutor implements
DatabaseRuleDropExecutor<DropMaskRuleStatement, MaskRuleConfiguration> {
+public final class DropMaskRuleExecutor implements
DatabaseRuleRDLDropExecutor<DropMaskRuleStatement, MaskRuleConfiguration> {
@Override
public void checkSQLStatement(final ShardingSphereDatabase database, final
DropMaskRuleStatement sqlStatement, final MaskRuleConfiguration
currentRuleConfig) {
diff --git
a/features/readwrite-splitting/distsql/handler/src/main/java/org/apache/shardingsphere/readwritesplitting/distsql/handler/update/AlterReadwriteSplittingRuleExecutor.java
b/features/readwrite-splitting/distsql/handler/src/main/java/org/apache/shardingsphere/readwritesplitting/distsql/handler/update/AlterReadwriteSplittingRuleExecutor.java
index 56a20dbb4a3..d5b720e49d6 100644
---
a/features/readwrite-splitting/distsql/handler/src/main/java/org/apache/shardingsphere/readwritesplitting/distsql/handler/update/AlterReadwriteSplittingRuleExecutor.java
+++
b/features/readwrite-splitting/distsql/handler/src/main/java/org/apache/shardingsphere/readwritesplitting/distsql/handler/update/AlterReadwriteSplittingRuleExecutor.java
@@ -18,7 +18,7 @@
package org.apache.shardingsphere.readwritesplitting.distsql.handler.update;
import com.google.common.base.Preconditions;
-import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleAlterExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleRDLAlterExecutor;
import org.apache.shardingsphere.infra.config.algorithm.AlgorithmConfiguration;
import
org.apache.shardingsphere.infra.metadata.database.ShardingSphereDatabase;
import
org.apache.shardingsphere.readwritesplitting.api.ReadwriteSplittingRuleConfiguration;
@@ -38,7 +38,7 @@ import java.util.stream.Collectors;
/**
* Alter readwrite-splitting rule executor.
*/
-public final class AlterReadwriteSplittingRuleExecutor implements
DatabaseRuleAlterExecutor<AlterReadwriteSplittingRuleStatement,
ReadwriteSplittingRuleConfiguration> {
+public final class AlterReadwriteSplittingRuleExecutor implements
DatabaseRuleRDLAlterExecutor<AlterReadwriteSplittingRuleStatement,
ReadwriteSplittingRuleConfiguration> {
@Override
public void checkSQLStatement(final ShardingSphereDatabase database, final
AlterReadwriteSplittingRuleStatement sqlStatement, final
ReadwriteSplittingRuleConfiguration currentRuleConfig) {
diff --git
a/features/readwrite-splitting/distsql/handler/src/main/java/org/apache/shardingsphere/readwritesplitting/distsql/handler/update/CreateReadwriteSplittingRuleExecutor.java
b/features/readwrite-splitting/distsql/handler/src/main/java/org/apache/shardingsphere/readwritesplitting/distsql/handler/update/CreateReadwriteSplittingRuleExecutor.java
index b80931ef33b..ced25e237ae 100644
---
a/features/readwrite-splitting/distsql/handler/src/main/java/org/apache/shardingsphere/readwritesplitting/distsql/handler/update/CreateReadwriteSplittingRuleExecutor.java
+++
b/features/readwrite-splitting/distsql/handler/src/main/java/org/apache/shardingsphere/readwritesplitting/distsql/handler/update/CreateReadwriteSplittingRuleExecutor.java
@@ -17,7 +17,7 @@
package org.apache.shardingsphere.readwritesplitting.distsql.handler.update;
-import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleCreateExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleRDLCreateExecutor;
import
org.apache.shardingsphere.infra.metadata.database.ShardingSphereDatabase;
import
org.apache.shardingsphere.readwritesplitting.api.ReadwriteSplittingRuleConfiguration;
import
org.apache.shardingsphere.readwritesplitting.api.rule.ReadwriteSplittingDataSourceRuleConfiguration;
@@ -33,7 +33,7 @@ import java.util.stream.Collectors;
/**
* Create readwrite-splitting rule executor.
*/
-public final class CreateReadwriteSplittingRuleExecutor implements
DatabaseRuleCreateExecutor<CreateReadwriteSplittingRuleStatement,
ReadwriteSplittingRuleConfiguration> {
+public final class CreateReadwriteSplittingRuleExecutor implements
DatabaseRuleRDLCreateExecutor<CreateReadwriteSplittingRuleStatement,
ReadwriteSplittingRuleConfiguration> {
@Override
public void checkSQLStatement(final ShardingSphereDatabase database, final
CreateReadwriteSplittingRuleStatement sqlStatement, final
ReadwriteSplittingRuleConfiguration currentRuleConfig) {
diff --git
a/features/readwrite-splitting/distsql/handler/src/main/java/org/apache/shardingsphere/readwritesplitting/distsql/handler/update/DropReadwriteSplittingRuleExecutor.java
b/features/readwrite-splitting/distsql/handler/src/main/java/org/apache/shardingsphere/readwritesplitting/distsql/handler/update/DropReadwriteSplittingRuleExecutor.java
index 3237caef2d2..7b3e7c990bf 100644
---
a/features/readwrite-splitting/distsql/handler/src/main/java/org/apache/shardingsphere/readwritesplitting/distsql/handler/update/DropReadwriteSplittingRuleExecutor.java
+++
b/features/readwrite-splitting/distsql/handler/src/main/java/org/apache/shardingsphere/readwritesplitting/distsql/handler/update/DropReadwriteSplittingRuleExecutor.java
@@ -19,7 +19,7 @@ package
org.apache.shardingsphere.readwritesplitting.distsql.handler.update;
import
org.apache.shardingsphere.distsql.handler.exception.rule.MissingRequiredRuleException;
import
org.apache.shardingsphere.distsql.handler.exception.rule.RuleInUsedException;
-import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleDropExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleRDLDropExecutor;
import org.apache.shardingsphere.infra.config.algorithm.AlgorithmConfiguration;
import org.apache.shardingsphere.infra.datanode.DataNode;
import
org.apache.shardingsphere.infra.metadata.database.ShardingSphereDatabase;
@@ -44,7 +44,7 @@ import java.util.stream.Collectors;
/**
* Drop readwrite-splitting rule executor.
*/
-public final class DropReadwriteSplittingRuleExecutor implements
DatabaseRuleDropExecutor<DropReadwriteSplittingRuleStatement,
ReadwriteSplittingRuleConfiguration> {
+public final class DropReadwriteSplittingRuleExecutor implements
DatabaseRuleRDLDropExecutor<DropReadwriteSplittingRuleStatement,
ReadwriteSplittingRuleConfiguration> {
@Override
public void checkSQLStatement(final ShardingSphereDatabase database, final
DropReadwriteSplittingRuleStatement sqlStatement, final
ReadwriteSplittingRuleConfiguration currentRuleConfig) {
diff --git
a/features/shadow/distsql/handler/src/main/java/org/apache/shardingsphere/shadow/distsql/handler/update/AlterDefaultShadowAlgorithmExecutor.java
b/features/shadow/distsql/handler/src/main/java/org/apache/shardingsphere/shadow/distsql/handler/update/AlterDefaultShadowAlgorithmExecutor.java
index 96eeacb360d..dd7116ae991 100644
---
a/features/shadow/distsql/handler/src/main/java/org/apache/shardingsphere/shadow/distsql/handler/update/AlterDefaultShadowAlgorithmExecutor.java
+++
b/features/shadow/distsql/handler/src/main/java/org/apache/shardingsphere/shadow/distsql/handler/update/AlterDefaultShadowAlgorithmExecutor.java
@@ -20,7 +20,7 @@ package
org.apache.shardingsphere.shadow.distsql.handler.update;
import com.google.common.base.Strings;
import
org.apache.shardingsphere.distsql.handler.exception.algorithm.InvalidAlgorithmConfigurationException;
import
org.apache.shardingsphere.distsql.handler.exception.algorithm.MissingRequiredAlgorithmException;
-import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleAlterExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleRDLAlterExecutor;
import org.apache.shardingsphere.distsql.segment.AlgorithmSegment;
import org.apache.shardingsphere.infra.config.algorithm.AlgorithmConfiguration;
import
org.apache.shardingsphere.infra.metadata.database.ShardingSphereDatabase;
@@ -38,7 +38,7 @@ import java.util.Map;
/**
* Alter default shadow algorithm executor.
*/
-public final class AlterDefaultShadowAlgorithmExecutor implements
DatabaseRuleAlterExecutor<AlterDefaultShadowAlgorithmStatement,
ShadowRuleConfiguration> {
+public final class AlterDefaultShadowAlgorithmExecutor implements
DatabaseRuleRDLAlterExecutor<AlterDefaultShadowAlgorithmStatement,
ShadowRuleConfiguration> {
private static final String DEFAULT_ALGORITHM_NAME =
"default_shadow_algorithm";
diff --git
a/features/shadow/distsql/handler/src/main/java/org/apache/shardingsphere/shadow/distsql/handler/update/AlterShadowRuleExecutor.java
b/features/shadow/distsql/handler/src/main/java/org/apache/shardingsphere/shadow/distsql/handler/update/AlterShadowRuleExecutor.java
index c3fa3e2418e..c0ada89fa79 100644
---
a/features/shadow/distsql/handler/src/main/java/org/apache/shardingsphere/shadow/distsql/handler/update/AlterShadowRuleExecutor.java
+++
b/features/shadow/distsql/handler/src/main/java/org/apache/shardingsphere/shadow/distsql/handler/update/AlterShadowRuleExecutor.java
@@ -20,7 +20,7 @@ package
org.apache.shardingsphere.shadow.distsql.handler.update;
import
org.apache.shardingsphere.distsql.handler.exception.algorithm.AlgorithmInUsedException;
import
org.apache.shardingsphere.distsql.handler.exception.rule.DuplicateRuleException;
import
org.apache.shardingsphere.distsql.handler.exception.rule.MissingRequiredRuleException;
-import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleAlterExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleRDLAlterExecutor;
import
org.apache.shardingsphere.infra.metadata.database.ShardingSphereDatabase;
import org.apache.shardingsphere.infra.spi.type.typed.TypedSPILoader;
import org.apache.shardingsphere.shadow.api.config.ShadowRuleConfiguration;
@@ -40,7 +40,7 @@ import java.util.Map;
/**
* Alter shadow rule executor.
*/
-public final class AlterShadowRuleExecutor implements
DatabaseRuleAlterExecutor<AlterShadowRuleStatement, ShadowRuleConfiguration> {
+public final class AlterShadowRuleExecutor implements
DatabaseRuleRDLAlterExecutor<AlterShadowRuleStatement, ShadowRuleConfiguration>
{
@Override
public ShadowRuleConfiguration buildToBeAlteredRuleConfiguration(final
AlterShadowRuleStatement sqlStatement) {
diff --git
a/features/shadow/distsql/handler/src/main/java/org/apache/shardingsphere/shadow/distsql/handler/update/CreateDefaultShadowAlgorithmExecutor.java
b/features/shadow/distsql/handler/src/main/java/org/apache/shardingsphere/shadow/distsql/handler/update/CreateDefaultShadowAlgorithmExecutor.java
index 7ca3afecd0a..030301a36d1 100644
---
a/features/shadow/distsql/handler/src/main/java/org/apache/shardingsphere/shadow/distsql/handler/update/CreateDefaultShadowAlgorithmExecutor.java
+++
b/features/shadow/distsql/handler/src/main/java/org/apache/shardingsphere/shadow/distsql/handler/update/CreateDefaultShadowAlgorithmExecutor.java
@@ -20,7 +20,7 @@ package
org.apache.shardingsphere.shadow.distsql.handler.update;
import com.google.common.base.Strings;
import
org.apache.shardingsphere.distsql.handler.exception.algorithm.DuplicateAlgorithmException;
import
org.apache.shardingsphere.distsql.handler.exception.algorithm.InvalidAlgorithmConfigurationException;
-import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleCreateExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleRDLCreateExecutor;
import org.apache.shardingsphere.distsql.segment.AlgorithmSegment;
import org.apache.shardingsphere.infra.config.algorithm.AlgorithmConfiguration;
import
org.apache.shardingsphere.infra.metadata.database.ShardingSphereDatabase;
@@ -39,7 +39,7 @@ import java.util.stream.Stream;
/**
* Create default shadow algorithm statement executor.
*/
-public final class CreateDefaultShadowAlgorithmExecutor implements
DatabaseRuleCreateExecutor<CreateDefaultShadowAlgorithmStatement,
ShadowRuleConfiguration> {
+public final class CreateDefaultShadowAlgorithmExecutor implements
DatabaseRuleRDLCreateExecutor<CreateDefaultShadowAlgorithmStatement,
ShadowRuleConfiguration> {
@Override
public void checkSQLStatement(final ShardingSphereDatabase database, final
CreateDefaultShadowAlgorithmStatement sqlStatement, final
ShadowRuleConfiguration currentRuleConfig) {
diff --git
a/features/shadow/distsql/handler/src/main/java/org/apache/shardingsphere/shadow/distsql/handler/update/CreateShadowRuleExecutor.java
b/features/shadow/distsql/handler/src/main/java/org/apache/shardingsphere/shadow/distsql/handler/update/CreateShadowRuleExecutor.java
index fd8332fb3c0..ff86629f9ce 100644
---
a/features/shadow/distsql/handler/src/main/java/org/apache/shardingsphere/shadow/distsql/handler/update/CreateShadowRuleExecutor.java
+++
b/features/shadow/distsql/handler/src/main/java/org/apache/shardingsphere/shadow/distsql/handler/update/CreateShadowRuleExecutor.java
@@ -18,7 +18,7 @@
package org.apache.shardingsphere.shadow.distsql.handler.update;
import
org.apache.shardingsphere.distsql.handler.exception.rule.DuplicateRuleException;
-import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleCreateExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleRDLCreateExecutor;
import
org.apache.shardingsphere.infra.metadata.database.ShardingSphereDatabase;
import
org.apache.shardingsphere.infra.exception.core.ShardingSpherePreconditions;
import org.apache.shardingsphere.infra.spi.type.typed.TypedSPILoader;
@@ -38,7 +38,7 @@ import java.util.Map;
/**
* Create shadow rule executor.
*/
-public final class CreateShadowRuleExecutor implements
DatabaseRuleCreateExecutor<CreateShadowRuleStatement, ShadowRuleConfiguration> {
+public final class CreateShadowRuleExecutor implements
DatabaseRuleRDLCreateExecutor<CreateShadowRuleStatement,
ShadowRuleConfiguration> {
@Override
public void checkSQLStatement(final ShardingSphereDatabase database, final
CreateShadowRuleStatement sqlStatement, final ShadowRuleConfiguration
currentRuleConfig) {
diff --git
a/features/shadow/distsql/handler/src/main/java/org/apache/shardingsphere/shadow/distsql/handler/update/DropDefaultShadowAlgorithmExecutor.java
b/features/shadow/distsql/handler/src/main/java/org/apache/shardingsphere/shadow/distsql/handler/update/DropDefaultShadowAlgorithmExecutor.java
index cae0dcbd760..2551b551eea 100644
---
a/features/shadow/distsql/handler/src/main/java/org/apache/shardingsphere/shadow/distsql/handler/update/DropDefaultShadowAlgorithmExecutor.java
+++
b/features/shadow/distsql/handler/src/main/java/org/apache/shardingsphere/shadow/distsql/handler/update/DropDefaultShadowAlgorithmExecutor.java
@@ -18,7 +18,7 @@
package org.apache.shardingsphere.shadow.distsql.handler.update;
import
org.apache.shardingsphere.distsql.handler.exception.algorithm.MissingRequiredAlgorithmException;
-import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleDropExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleRDLDropExecutor;
import
org.apache.shardingsphere.infra.metadata.database.ShardingSphereDatabase;
import
org.apache.shardingsphere.infra.exception.core.ShardingSpherePreconditions;
import org.apache.shardingsphere.shadow.api.config.ShadowRuleConfiguration;
@@ -30,7 +30,7 @@ import java.util.Collections;
/**
* Drop default shadow algorithm executor.
*/
-public final class DropDefaultShadowAlgorithmExecutor implements
DatabaseRuleDropExecutor<DropDefaultShadowAlgorithmStatement,
ShadowRuleConfiguration> {
+public final class DropDefaultShadowAlgorithmExecutor implements
DatabaseRuleRDLDropExecutor<DropDefaultShadowAlgorithmStatement,
ShadowRuleConfiguration> {
@Override
public void checkSQLStatement(final ShardingSphereDatabase database, final
DropDefaultShadowAlgorithmStatement sqlStatement, final ShadowRuleConfiguration
currentRuleConfig) {
diff --git
a/features/shadow/distsql/handler/src/main/java/org/apache/shardingsphere/shadow/distsql/handler/update/DropShadowAlgorithmExecutor.java
b/features/shadow/distsql/handler/src/main/java/org/apache/shardingsphere/shadow/distsql/handler/update/DropShadowAlgorithmExecutor.java
index 4a039327cba..64aee5726df 100644
---
a/features/shadow/distsql/handler/src/main/java/org/apache/shardingsphere/shadow/distsql/handler/update/DropShadowAlgorithmExecutor.java
+++
b/features/shadow/distsql/handler/src/main/java/org/apache/shardingsphere/shadow/distsql/handler/update/DropShadowAlgorithmExecutor.java
@@ -20,7 +20,7 @@ package
org.apache.shardingsphere.shadow.distsql.handler.update;
import
org.apache.shardingsphere.infra.exception.core.external.sql.type.kernel.category.DistSQLException;
import
org.apache.shardingsphere.distsql.handler.exception.algorithm.AlgorithmInUsedException;
import
org.apache.shardingsphere.distsql.handler.exception.algorithm.MissingRequiredAlgorithmException;
-import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleDropExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleRDLDropExecutor;
import
org.apache.shardingsphere.infra.metadata.database.ShardingSphereDatabase;
import
org.apache.shardingsphere.infra.exception.core.ShardingSpherePreconditions;
import org.apache.shardingsphere.shadow.api.config.ShadowRuleConfiguration;
@@ -39,7 +39,7 @@ import java.util.stream.Collectors;
/**
* Drop shadow algorithm executor.
*/
-public final class DropShadowAlgorithmExecutor implements
DatabaseRuleDropExecutor<DropShadowAlgorithmStatement, ShadowRuleConfiguration>
{
+public final class DropShadowAlgorithmExecutor implements
DatabaseRuleRDLDropExecutor<DropShadowAlgorithmStatement,
ShadowRuleConfiguration> {
@Override
public void checkSQLStatement(final ShardingSphereDatabase database, final
DropShadowAlgorithmStatement sqlStatement, final ShadowRuleConfiguration
currentRuleConfig) {
diff --git
a/features/shadow/distsql/handler/src/main/java/org/apache/shardingsphere/shadow/distsql/handler/update/DropShadowRuleExecutor.java
b/features/shadow/distsql/handler/src/main/java/org/apache/shardingsphere/shadow/distsql/handler/update/DropShadowRuleExecutor.java
index f15fdcfca1b..b44fcc6c1ad 100644
---
a/features/shadow/distsql/handler/src/main/java/org/apache/shardingsphere/shadow/distsql/handler/update/DropShadowRuleExecutor.java
+++
b/features/shadow/distsql/handler/src/main/java/org/apache/shardingsphere/shadow/distsql/handler/update/DropShadowRuleExecutor.java
@@ -18,7 +18,7 @@
package org.apache.shardingsphere.shadow.distsql.handler.update;
import
org.apache.shardingsphere.distsql.handler.exception.rule.MissingRequiredRuleException;
-import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleDropExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleRDLDropExecutor;
import
org.apache.shardingsphere.infra.exception.core.ShardingSpherePreconditions;
import
org.apache.shardingsphere.infra.metadata.database.ShardingSphereDatabase;
import org.apache.shardingsphere.shadow.api.config.ShadowRuleConfiguration;
@@ -39,7 +39,7 @@ import java.util.stream.Collectors;
/**
* Drop shadow rule executor.
*/
-public final class DropShadowRuleExecutor implements
DatabaseRuleDropExecutor<DropShadowRuleStatement, ShadowRuleConfiguration> {
+public final class DropShadowRuleExecutor implements
DatabaseRuleRDLDropExecutor<DropShadowRuleStatement, ShadowRuleConfiguration> {
@Override
public void checkSQLStatement(final ShardingSphereDatabase database, final
DropShadowRuleStatement sqlStatement, final ShadowRuleConfiguration
currentRuleConfig) {
diff --git
a/features/sharding/distsql/handler/src/main/java/org/apache/shardingsphere/sharding/distsql/handler/update/AlterDefaultShardingStrategyExecutor.java
b/features/sharding/distsql/handler/src/main/java/org/apache/shardingsphere/sharding/distsql/handler/update/AlterDefaultShardingStrategyExecutor.java
index 5e55f3c097c..8a6762c959c 100644
---
a/features/sharding/distsql/handler/src/main/java/org/apache/shardingsphere/sharding/distsql/handler/update/AlterDefaultShardingStrategyExecutor.java
+++
b/features/sharding/distsql/handler/src/main/java/org/apache/shardingsphere/sharding/distsql/handler/update/AlterDefaultShardingStrategyExecutor.java
@@ -20,7 +20,7 @@ package
org.apache.shardingsphere.sharding.distsql.handler.update;
import
org.apache.shardingsphere.distsql.handler.exception.algorithm.InvalidAlgorithmConfigurationException;
import
org.apache.shardingsphere.distsql.handler.exception.algorithm.MissingRequiredAlgorithmException;
import
org.apache.shardingsphere.distsql.handler.exception.rule.MissingRequiredRuleException;
-import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleAlterExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleRDLAlterExecutor;
import org.apache.shardingsphere.distsql.segment.AlgorithmSegment;
import org.apache.shardingsphere.infra.config.algorithm.AlgorithmConfiguration;
import
org.apache.shardingsphere.infra.metadata.database.ShardingSphereDatabase;
@@ -38,7 +38,7 @@ import java.util.Optional;
/**
* Alter default sharding strategy executor.
*/
-public final class AlterDefaultShardingStrategyExecutor implements
DatabaseRuleAlterExecutor<AlterDefaultShardingStrategyStatement,
ShardingRuleConfiguration> {
+public final class AlterDefaultShardingStrategyExecutor implements
DatabaseRuleRDLAlterExecutor<AlterDefaultShardingStrategyStatement,
ShardingRuleConfiguration> {
@Override
public void checkSQLStatement(final ShardingSphereDatabase database, final
AlterDefaultShardingStrategyStatement sqlStatement, final
ShardingRuleConfiguration currentRuleConfig) {
diff --git
a/features/sharding/distsql/handler/src/main/java/org/apache/shardingsphere/sharding/distsql/handler/update/AlterShardingTableReferenceRuleExecutor.java
b/features/sharding/distsql/handler/src/main/java/org/apache/shardingsphere/sharding/distsql/handler/update/AlterShardingTableReferenceRuleExecutor.java
index df4501763b6..d5d959f8902 100644
---
a/features/sharding/distsql/handler/src/main/java/org/apache/shardingsphere/sharding/distsql/handler/update/AlterShardingTableReferenceRuleExecutor.java
+++
b/features/sharding/distsql/handler/src/main/java/org/apache/shardingsphere/sharding/distsql/handler/update/AlterShardingTableReferenceRuleExecutor.java
@@ -20,7 +20,7 @@ package
org.apache.shardingsphere.sharding.distsql.handler.update;
import
org.apache.shardingsphere.distsql.handler.exception.rule.DuplicateRuleException;
import
org.apache.shardingsphere.distsql.handler.exception.rule.InvalidRuleConfigurationException;
import
org.apache.shardingsphere.distsql.handler.exception.rule.MissingRequiredRuleException;
-import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleAlterExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleRDLAlterExecutor;
import
org.apache.shardingsphere.infra.metadata.database.ShardingSphereDatabase;
import
org.apache.shardingsphere.infra.exception.core.ShardingSpherePreconditions;
import org.apache.shardingsphere.sharding.api.config.ShardingRuleConfiguration;
@@ -40,7 +40,7 @@ import java.util.stream.Collectors;
/**
* Alter sharding table reference rule executor.
*/
-public final class AlterShardingTableReferenceRuleExecutor implements
DatabaseRuleAlterExecutor<AlterShardingTableReferenceRuleStatement,
ShardingRuleConfiguration> {
+public final class AlterShardingTableReferenceRuleExecutor implements
DatabaseRuleRDLAlterExecutor<AlterShardingTableReferenceRuleStatement,
ShardingRuleConfiguration> {
@Override
public void checkSQLStatement(final ShardingSphereDatabase database, final
AlterShardingTableReferenceRuleStatement sqlStatement, final
ShardingRuleConfiguration currentRuleConfig) {
diff --git
a/features/sharding/distsql/handler/src/main/java/org/apache/shardingsphere/sharding/distsql/handler/update/AlterShardingTableRuleExecutor.java
b/features/sharding/distsql/handler/src/main/java/org/apache/shardingsphere/sharding/distsql/handler/update/AlterShardingTableRuleExecutor.java
index fe71396324d..708f1735bee 100644
---
a/features/sharding/distsql/handler/src/main/java/org/apache/shardingsphere/sharding/distsql/handler/update/AlterShardingTableRuleExecutor.java
+++
b/features/sharding/distsql/handler/src/main/java/org/apache/shardingsphere/sharding/distsql/handler/update/AlterShardingTableRuleExecutor.java
@@ -18,7 +18,7 @@
package org.apache.shardingsphere.sharding.distsql.handler.update;
import
org.apache.shardingsphere.distsql.handler.exception.rule.MissingRequiredRuleException;
-import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleAlterExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleRDLAlterExecutor;
import
org.apache.shardingsphere.infra.exception.core.ShardingSpherePreconditions;
import
org.apache.shardingsphere.infra.metadata.database.ShardingSphereDatabase;
import org.apache.shardingsphere.sharding.api.config.ShardingRuleConfiguration;
@@ -34,7 +34,7 @@ import java.util.stream.Collectors;
/**
* Alter sharding table rule executor.
*/
-public final class AlterShardingTableRuleExecutor implements
DatabaseRuleAlterExecutor<AlterShardingTableRuleStatement,
ShardingRuleConfiguration> {
+public final class AlterShardingTableRuleExecutor implements
DatabaseRuleRDLAlterExecutor<AlterShardingTableRuleStatement,
ShardingRuleConfiguration> {
@Override
public void checkSQLStatement(final ShardingSphereDatabase database, final
AlterShardingTableRuleStatement sqlStatement, final ShardingRuleConfiguration
currentRuleConfig) {
diff --git
a/features/sharding/distsql/handler/src/main/java/org/apache/shardingsphere/sharding/distsql/handler/update/CreateDefaultShardingStrategyExecutor.java
b/features/sharding/distsql/handler/src/main/java/org/apache/shardingsphere/sharding/distsql/handler/update/CreateDefaultShardingStrategyExecutor.java
index 557eb8a376c..5c447e0f430 100644
---
a/features/sharding/distsql/handler/src/main/java/org/apache/shardingsphere/sharding/distsql/handler/update/CreateDefaultShardingStrategyExecutor.java
+++
b/features/sharding/distsql/handler/src/main/java/org/apache/shardingsphere/sharding/distsql/handler/update/CreateDefaultShardingStrategyExecutor.java
@@ -20,7 +20,7 @@ package
org.apache.shardingsphere.sharding.distsql.handler.update;
import
org.apache.shardingsphere.distsql.handler.exception.algorithm.InvalidAlgorithmConfigurationException;
import
org.apache.shardingsphere.distsql.handler.exception.algorithm.MissingRequiredAlgorithmException;
import
org.apache.shardingsphere.distsql.handler.exception.rule.DuplicateRuleException;
-import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleCreateExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleRDLCreateExecutor;
import org.apache.shardingsphere.distsql.segment.AlgorithmSegment;
import org.apache.shardingsphere.infra.config.algorithm.AlgorithmConfiguration;
import
org.apache.shardingsphere.infra.metadata.database.ShardingSphereDatabase;
@@ -38,7 +38,7 @@ import java.util.Optional;
/**
* Create default sharding strategy executor.
*/
-public final class CreateDefaultShardingStrategyExecutor implements
DatabaseRuleCreateExecutor<CreateDefaultShardingStrategyStatement,
ShardingRuleConfiguration> {
+public final class CreateDefaultShardingStrategyExecutor implements
DatabaseRuleRDLCreateExecutor<CreateDefaultShardingStrategyStatement,
ShardingRuleConfiguration> {
@Override
public void checkSQLStatement(final ShardingSphereDatabase database, final
CreateDefaultShardingStrategyStatement sqlStatement, final
ShardingRuleConfiguration currentRuleConfig) {
diff --git
a/features/sharding/distsql/handler/src/main/java/org/apache/shardingsphere/sharding/distsql/handler/update/CreateShardingTableReferenceRuleExecutor.java
b/features/sharding/distsql/handler/src/main/java/org/apache/shardingsphere/sharding/distsql/handler/update/CreateShardingTableReferenceRuleExecutor.java
index ea62ced339c..1a9eedbb5e5 100644
---
a/features/sharding/distsql/handler/src/main/java/org/apache/shardingsphere/sharding/distsql/handler/update/CreateShardingTableReferenceRuleExecutor.java
+++
b/features/sharding/distsql/handler/src/main/java/org/apache/shardingsphere/sharding/distsql/handler/update/CreateShardingTableReferenceRuleExecutor.java
@@ -20,7 +20,7 @@ package
org.apache.shardingsphere.sharding.distsql.handler.update;
import
org.apache.shardingsphere.distsql.handler.exception.rule.DuplicateRuleException;
import
org.apache.shardingsphere.distsql.handler.exception.rule.InvalidRuleConfigurationException;
import
org.apache.shardingsphere.distsql.handler.exception.rule.MissingRequiredRuleException;
-import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleCreateExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleRDLCreateExecutor;
import
org.apache.shardingsphere.infra.metadata.database.ShardingSphereDatabase;
import
org.apache.shardingsphere.infra.exception.core.ShardingSpherePreconditions;
import org.apache.shardingsphere.sharding.api.config.ShardingRuleConfiguration;
@@ -40,7 +40,7 @@ import java.util.stream.Collectors;
/**
* Create sharding table reference rule executor.
*/
-public final class CreateShardingTableReferenceRuleExecutor implements
DatabaseRuleCreateExecutor<CreateShardingTableReferenceRuleStatement,
ShardingRuleConfiguration> {
+public final class CreateShardingTableReferenceRuleExecutor implements
DatabaseRuleRDLCreateExecutor<CreateShardingTableReferenceRuleStatement,
ShardingRuleConfiguration> {
@Override
public void checkSQLStatement(final ShardingSphereDatabase database, final
CreateShardingTableReferenceRuleStatement sqlStatement, final
ShardingRuleConfiguration currentRuleConfig) {
diff --git
a/features/sharding/distsql/handler/src/main/java/org/apache/shardingsphere/sharding/distsql/handler/update/CreateShardingTableRuleExecutor.java
b/features/sharding/distsql/handler/src/main/java/org/apache/shardingsphere/sharding/distsql/handler/update/CreateShardingTableRuleExecutor.java
index d3384a2165d..b57eed40200 100644
---
a/features/sharding/distsql/handler/src/main/java/org/apache/shardingsphere/sharding/distsql/handler/update/CreateShardingTableRuleExecutor.java
+++
b/features/sharding/distsql/handler/src/main/java/org/apache/shardingsphere/sharding/distsql/handler/update/CreateShardingTableRuleExecutor.java
@@ -17,7 +17,7 @@
package org.apache.shardingsphere.sharding.distsql.handler.update;
-import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleCreateExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleRDLCreateExecutor;
import
org.apache.shardingsphere.infra.metadata.database.ShardingSphereDatabase;
import org.apache.shardingsphere.sharding.api.config.ShardingRuleConfiguration;
import
org.apache.shardingsphere.sharding.api.config.rule.ShardingAutoTableRuleConfiguration;
@@ -35,7 +35,7 @@ import java.util.stream.Collectors;
/**
* Create sharding table rule executor.
*/
-public final class CreateShardingTableRuleExecutor implements
DatabaseRuleCreateExecutor<CreateShardingTableRuleStatement,
ShardingRuleConfiguration> {
+public final class CreateShardingTableRuleExecutor implements
DatabaseRuleRDLCreateExecutor<CreateShardingTableRuleStatement,
ShardingRuleConfiguration> {
@Override
public void checkSQLStatement(final ShardingSphereDatabase database, final
CreateShardingTableRuleStatement sqlStatement, final ShardingRuleConfiguration
currentRuleConfig) {
diff --git
a/features/sharding/distsql/handler/src/main/java/org/apache/shardingsphere/sharding/distsql/handler/update/DropDefaultShardingStrategyExecutor.java
b/features/sharding/distsql/handler/src/main/java/org/apache/shardingsphere/sharding/distsql/handler/update/DropDefaultShardingStrategyExecutor.java
index 71692236a7c..d7623bbc0a0 100644
---
a/features/sharding/distsql/handler/src/main/java/org/apache/shardingsphere/sharding/distsql/handler/update/DropDefaultShardingStrategyExecutor.java
+++
b/features/sharding/distsql/handler/src/main/java/org/apache/shardingsphere/sharding/distsql/handler/update/DropDefaultShardingStrategyExecutor.java
@@ -18,7 +18,7 @@
package org.apache.shardingsphere.sharding.distsql.handler.update;
import
org.apache.shardingsphere.distsql.handler.exception.rule.MissingRequiredRuleException;
-import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleDropExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleRDLDropExecutor;
import
org.apache.shardingsphere.infra.metadata.database.ShardingSphereDatabase;
import
org.apache.shardingsphere.infra.exception.core.ShardingSpherePreconditions;
import org.apache.shardingsphere.sharding.api.config.ShardingRuleConfiguration;
@@ -31,7 +31,7 @@ import java.util.Optional;
/**
* Drop default sharding strategy executor.
*/
-public final class DropDefaultShardingStrategyExecutor implements
DatabaseRuleDropExecutor<DropDefaultShardingStrategyStatement,
ShardingRuleConfiguration> {
+public final class DropDefaultShardingStrategyExecutor implements
DatabaseRuleRDLDropExecutor<DropDefaultShardingStrategyStatement,
ShardingRuleConfiguration> {
@Override
public void checkSQLStatement(final ShardingSphereDatabase database, final
DropDefaultShardingStrategyStatement sqlStatement,
diff --git
a/features/sharding/distsql/handler/src/main/java/org/apache/shardingsphere/sharding/distsql/handler/update/DropShardingAlgorithmExecutor.java
b/features/sharding/distsql/handler/src/main/java/org/apache/shardingsphere/sharding/distsql/handler/update/DropShardingAlgorithmExecutor.java
index 90846ea051a..6e711815406 100644
---
a/features/sharding/distsql/handler/src/main/java/org/apache/shardingsphere/sharding/distsql/handler/update/DropShardingAlgorithmExecutor.java
+++
b/features/sharding/distsql/handler/src/main/java/org/apache/shardingsphere/sharding/distsql/handler/update/DropShardingAlgorithmExecutor.java
@@ -19,7 +19,7 @@ package
org.apache.shardingsphere.sharding.distsql.handler.update;
import
org.apache.shardingsphere.distsql.handler.exception.algorithm.AlgorithmInUsedException;
import
org.apache.shardingsphere.distsql.handler.exception.algorithm.MissingRequiredAlgorithmException;
-import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleDropExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleRDLDropExecutor;
import
org.apache.shardingsphere.infra.metadata.database.ShardingSphereDatabase;
import
org.apache.shardingsphere.infra.exception.core.ShardingSpherePreconditions;
import org.apache.shardingsphere.sharding.api.config.ShardingRuleConfiguration;
@@ -33,7 +33,7 @@ import java.util.stream.Collectors;
/**
* Drop sharding algorithm executor.
*/
-public final class DropShardingAlgorithmExecutor implements
DatabaseRuleDropExecutor<DropShardingAlgorithmStatement,
ShardingRuleConfiguration> {
+public final class DropShardingAlgorithmExecutor implements
DatabaseRuleRDLDropExecutor<DropShardingAlgorithmStatement,
ShardingRuleConfiguration> {
@Override
public void checkSQLStatement(final ShardingSphereDatabase database, final
DropShardingAlgorithmStatement sqlStatement, final ShardingRuleConfiguration
currentRuleConfig) {
diff --git
a/features/sharding/distsql/handler/src/main/java/org/apache/shardingsphere/sharding/distsql/handler/update/DropShardingAuditorExecutor.java
b/features/sharding/distsql/handler/src/main/java/org/apache/shardingsphere/sharding/distsql/handler/update/DropShardingAuditorExecutor.java
index b25d30d6cfd..17e5ee84a34 100644
---
a/features/sharding/distsql/handler/src/main/java/org/apache/shardingsphere/sharding/distsql/handler/update/DropShardingAuditorExecutor.java
+++
b/features/sharding/distsql/handler/src/main/java/org/apache/shardingsphere/sharding/distsql/handler/update/DropShardingAuditorExecutor.java
@@ -19,7 +19,7 @@ package
org.apache.shardingsphere.sharding.distsql.handler.update;
import
org.apache.shardingsphere.distsql.handler.exception.algorithm.AlgorithmInUsedException;
import
org.apache.shardingsphere.distsql.handler.exception.algorithm.MissingRequiredAlgorithmException;
-import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleDropExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleRDLDropExecutor;
import
org.apache.shardingsphere.infra.exception.core.ShardingSpherePreconditions;
import
org.apache.shardingsphere.infra.metadata.database.ShardingSphereDatabase;
import org.apache.shardingsphere.sharding.api.config.ShardingRuleConfiguration;
@@ -34,7 +34,7 @@ import java.util.stream.Collectors;
/**
* Drop sharding auditor statement executor.
*/
-public final class DropShardingAuditorExecutor implements
DatabaseRuleDropExecutor<DropShardingAuditorStatement,
ShardingRuleConfiguration> {
+public final class DropShardingAuditorExecutor implements
DatabaseRuleRDLDropExecutor<DropShardingAuditorStatement,
ShardingRuleConfiguration> {
@Override
public void checkSQLStatement(final ShardingSphereDatabase database, final
DropShardingAuditorStatement sqlStatement, final ShardingRuleConfiguration
currentRuleConfig) {
diff --git
a/features/sharding/distsql/handler/src/main/java/org/apache/shardingsphere/sharding/distsql/handler/update/DropShardingKeyGeneratorExecutor.java
b/features/sharding/distsql/handler/src/main/java/org/apache/shardingsphere/sharding/distsql/handler/update/DropShardingKeyGeneratorExecutor.java
index f39c63f297a..ac35662a619 100644
---
a/features/sharding/distsql/handler/src/main/java/org/apache/shardingsphere/sharding/distsql/handler/update/DropShardingKeyGeneratorExecutor.java
+++
b/features/sharding/distsql/handler/src/main/java/org/apache/shardingsphere/sharding/distsql/handler/update/DropShardingKeyGeneratorExecutor.java
@@ -20,7 +20,7 @@ package
org.apache.shardingsphere.sharding.distsql.handler.update;
import com.google.common.base.Strings;
import
org.apache.shardingsphere.distsql.handler.exception.algorithm.AlgorithmInUsedException;
import
org.apache.shardingsphere.distsql.handler.exception.algorithm.MissingRequiredAlgorithmException;
-import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleDropExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleRDLDropExecutor;
import
org.apache.shardingsphere.infra.exception.core.ShardingSpherePreconditions;
import
org.apache.shardingsphere.infra.metadata.database.ShardingSphereDatabase;
import org.apache.shardingsphere.sharding.api.config.ShardingRuleConfiguration;
@@ -35,7 +35,7 @@ import java.util.stream.Collectors;
/**
* Drop sharding key generator executor.
*/
-public final class DropShardingKeyGeneratorExecutor implements
DatabaseRuleDropExecutor<DropShardingKeyGeneratorStatement,
ShardingRuleConfiguration> {
+public final class DropShardingKeyGeneratorExecutor implements
DatabaseRuleRDLDropExecutor<DropShardingKeyGeneratorStatement,
ShardingRuleConfiguration> {
@Override
public void checkSQLStatement(final ShardingSphereDatabase database, final
DropShardingKeyGeneratorStatement sqlStatement, final ShardingRuleConfiguration
currentRuleConfig) {
diff --git
a/features/sharding/distsql/handler/src/main/java/org/apache/shardingsphere/sharding/distsql/handler/update/DropShardingTableReferenceExecutor.java
b/features/sharding/distsql/handler/src/main/java/org/apache/shardingsphere/sharding/distsql/handler/update/DropShardingTableReferenceExecutor.java
index 61a545aa52d..ea0905d16d5 100644
---
a/features/sharding/distsql/handler/src/main/java/org/apache/shardingsphere/sharding/distsql/handler/update/DropShardingTableReferenceExecutor.java
+++
b/features/sharding/distsql/handler/src/main/java/org/apache/shardingsphere/sharding/distsql/handler/update/DropShardingTableReferenceExecutor.java
@@ -18,7 +18,7 @@
package org.apache.shardingsphere.sharding.distsql.handler.update;
import
org.apache.shardingsphere.distsql.handler.exception.rule.MissingRequiredRuleException;
-import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleDropExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleRDLDropExecutor;
import
org.apache.shardingsphere.infra.exception.core.ShardingSpherePreconditions;
import
org.apache.shardingsphere.infra.metadata.database.ShardingSphereDatabase;
import org.apache.shardingsphere.sharding.api.config.ShardingRuleConfiguration;
@@ -31,7 +31,7 @@ import java.util.stream.Collectors;
/**
* Drop sharding table reference executor.
*/
-public final class DropShardingTableReferenceExecutor implements
DatabaseRuleDropExecutor<DropShardingTableReferenceRuleStatement,
ShardingRuleConfiguration> {
+public final class DropShardingTableReferenceExecutor implements
DatabaseRuleRDLDropExecutor<DropShardingTableReferenceRuleStatement,
ShardingRuleConfiguration> {
@Override
public void checkSQLStatement(final ShardingSphereDatabase database, final
DropShardingTableReferenceRuleStatement sqlStatement, final
ShardingRuleConfiguration currentRuleConfig) {
diff --git
a/features/sharding/distsql/handler/src/main/java/org/apache/shardingsphere/sharding/distsql/handler/update/DropShardingTableRuleExecutor.java
b/features/sharding/distsql/handler/src/main/java/org/apache/shardingsphere/sharding/distsql/handler/update/DropShardingTableRuleExecutor.java
index 80809565153..a7b36eb1331 100644
---
a/features/sharding/distsql/handler/src/main/java/org/apache/shardingsphere/sharding/distsql/handler/update/DropShardingTableRuleExecutor.java
+++
b/features/sharding/distsql/handler/src/main/java/org/apache/shardingsphere/sharding/distsql/handler/update/DropShardingTableRuleExecutor.java
@@ -20,7 +20,7 @@ package
org.apache.shardingsphere.sharding.distsql.handler.update;
import com.google.common.base.Splitter;
import
org.apache.shardingsphere.distsql.handler.exception.rule.MissingRequiredRuleException;
import
org.apache.shardingsphere.distsql.handler.exception.rule.RuleInUsedException;
-import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleDropExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleRDLDropExecutor;
import
org.apache.shardingsphere.infra.exception.core.ShardingSpherePreconditions;
import
org.apache.shardingsphere.infra.metadata.database.ShardingSphereDatabase;
import org.apache.shardingsphere.sharding.api.config.ShardingRuleConfiguration;
@@ -38,7 +38,7 @@ import java.util.stream.Collectors;
/**
* Drop sharding table rule executor.
*/
-public final class DropShardingTableRuleExecutor implements
DatabaseRuleDropExecutor<DropShardingTableRuleStatement,
ShardingRuleConfiguration> {
+public final class DropShardingTableRuleExecutor implements
DatabaseRuleRDLDropExecutor<DropShardingTableRuleStatement,
ShardingRuleConfiguration> {
@Override
public void checkSQLStatement(final ShardingSphereDatabase database, final
DropShardingTableRuleStatement sqlStatement, final ShardingRuleConfiguration
currentRuleConfig) {
diff --git
a/infra/distsql-handler/src/main/java/org/apache/shardingsphere/distsql/handler/type/ral/query/ConvertRuleConfigurationProvider.java
b/infra/distsql-handler/src/main/java/org/apache/shardingsphere/distsql/handler/type/ral/query/ConvertRuleConfigurationProvider.java
index 52e091dc6a1..f7a3734d1ee 100644
---
a/infra/distsql-handler/src/main/java/org/apache/shardingsphere/distsql/handler/type/ral/query/ConvertRuleConfigurationProvider.java
+++
b/infra/distsql-handler/src/main/java/org/apache/shardingsphere/distsql/handler/type/ral/query/ConvertRuleConfigurationProvider.java
@@ -53,11 +53,9 @@ public interface ConvertRuleConfigurationProvider extends
TypedSPI {
return result.toString();
}
String type = algorithmConfig.getType().toLowerCase();
- if (algorithmConfig.getProps().isEmpty()) {
-
result.append(String.format(DistSQLScriptConstants.ALGORITHM_TYPE_WITHOUT_PROPS,
type));
- } else {
- result.append(String.format(DistSQLScriptConstants.ALGORITHM_TYPE,
type, getAlgorithmProperties(algorithmConfig.getProps())));
- }
+ result.append(algorithmConfig.getProps().isEmpty()
+ ?
String.format(DistSQLScriptConstants.ALGORITHM_TYPE_WITHOUT_PROPS, type)
+ : String.format(DistSQLScriptConstants.ALGORITHM_TYPE, type,
getAlgorithmProperties(algorithmConfig.getProps())));
return result.toString();
}
diff --git
a/infra/distsql-handler/src/main/java/org/apache/shardingsphere/distsql/handler/type/rdl/database/DatabaseRuleAlterExecutor.java
b/infra/distsql-handler/src/main/java/org/apache/shardingsphere/distsql/handler/type/rdl/database/DatabaseRuleRDLAlterExecutor.java
similarity index 92%
rename from
infra/distsql-handler/src/main/java/org/apache/shardingsphere/distsql/handler/type/rdl/database/DatabaseRuleAlterExecutor.java
rename to
infra/distsql-handler/src/main/java/org/apache/shardingsphere/distsql/handler/type/rdl/database/DatabaseRuleRDLAlterExecutor.java
index 26bbb228fac..5b18ea88bf6 100644
---
a/infra/distsql-handler/src/main/java/org/apache/shardingsphere/distsql/handler/type/rdl/database/DatabaseRuleAlterExecutor.java
+++
b/infra/distsql-handler/src/main/java/org/apache/shardingsphere/distsql/handler/type/rdl/database/DatabaseRuleRDLAlterExecutor.java
@@ -21,12 +21,12 @@ import
org.apache.shardingsphere.infra.config.rule.RuleConfiguration;
import org.apache.shardingsphere.sql.parser.sql.common.statement.SQLStatement;
/**
- * Database rule alter executor.
+ * Database rule RDL alter executor.
*
* @param <T> type of SQL statement
* @param <R> type of rule configuration
*/
-public interface DatabaseRuleAlterExecutor<T extends SQLStatement, R extends
RuleConfiguration> extends DatabaseRuleRDLExecutor<T, R> {
+public interface DatabaseRuleRDLAlterExecutor<T extends SQLStatement, R
extends RuleConfiguration> extends DatabaseRuleRDLExecutor<T, R> {
/**
* Build to be altered rule configuration.
diff --git
a/infra/distsql-handler/src/main/java/org/apache/shardingsphere/distsql/handler/type/rdl/database/DatabaseRuleCreateExecutor.java
b/infra/distsql-handler/src/main/java/org/apache/shardingsphere/distsql/handler/type/rdl/database/DatabaseRuleRDLCreateExecutor.java
similarity index 90%
rename from
infra/distsql-handler/src/main/java/org/apache/shardingsphere/distsql/handler/type/rdl/database/DatabaseRuleCreateExecutor.java
rename to
infra/distsql-handler/src/main/java/org/apache/shardingsphere/distsql/handler/type/rdl/database/DatabaseRuleRDLCreateExecutor.java
index 04e9051782e..f081418a50f 100644
---
a/infra/distsql-handler/src/main/java/org/apache/shardingsphere/distsql/handler/type/rdl/database/DatabaseRuleCreateExecutor.java
+++
b/infra/distsql-handler/src/main/java/org/apache/shardingsphere/distsql/handler/type/rdl/database/DatabaseRuleRDLCreateExecutor.java
@@ -21,12 +21,12 @@ import
org.apache.shardingsphere.infra.config.rule.RuleConfiguration;
import org.apache.shardingsphere.sql.parser.sql.common.statement.SQLStatement;
/**
- * Database rule create executor.
+ * Database rule RDL create executor.
*
* @param <T> type of SQL statement
* @param <R> type of rule configuration
*/
-public interface DatabaseRuleCreateExecutor<T extends SQLStatement, R extends
RuleConfiguration> extends DatabaseRuleRDLExecutor<T, R> {
+public interface DatabaseRuleRDLCreateExecutor<T extends SQLStatement, R
extends RuleConfiguration> extends DatabaseRuleRDLExecutor<T, R> {
/**
* Build to be created rule configuration.
diff --git
a/infra/distsql-handler/src/main/java/org/apache/shardingsphere/distsql/handler/type/rdl/database/DatabaseRuleDropExecutor.java
b/infra/distsql-handler/src/main/java/org/apache/shardingsphere/distsql/handler/type/rdl/database/DatabaseRuleRDLDropExecutor.java
similarity index 95%
rename from
infra/distsql-handler/src/main/java/org/apache/shardingsphere/distsql/handler/type/rdl/database/DatabaseRuleDropExecutor.java
rename to
infra/distsql-handler/src/main/java/org/apache/shardingsphere/distsql/handler/type/rdl/database/DatabaseRuleRDLDropExecutor.java
index 90a77426f27..5400da41ec7 100644
---
a/infra/distsql-handler/src/main/java/org/apache/shardingsphere/distsql/handler/type/rdl/database/DatabaseRuleDropExecutor.java
+++
b/infra/distsql-handler/src/main/java/org/apache/shardingsphere/distsql/handler/type/rdl/database/DatabaseRuleRDLDropExecutor.java
@@ -24,12 +24,12 @@ import java.util.Collection;
import java.util.stream.Collectors;
/**
- * Database rule drop executor.
+ * Database rule RDL drop executor.
*
* @param <T> type of SQL statement
* @param <R> type of rule configuration
*/
-public interface DatabaseRuleDropExecutor<T extends SQLStatement, R extends
RuleConfiguration> extends DatabaseRuleRDLExecutor<T, R> {
+public interface DatabaseRuleRDLDropExecutor<T extends SQLStatement, R extends
RuleConfiguration> extends DatabaseRuleRDLExecutor<T, R> {
/**
* TODO Remove temporary default implementation
diff --git
a/kernel/single/distsql/handler/src/main/java/org/apache/shardingsphere/single/distsql/handler/update/LoadSingleTableExecutor.java
b/kernel/single/distsql/handler/src/main/java/org/apache/shardingsphere/single/distsql/handler/update/LoadSingleTableExecutor.java
index 89ac244f57c..2d09b60aaa9 100644
---
a/kernel/single/distsql/handler/src/main/java/org/apache/shardingsphere/single/distsql/handler/update/LoadSingleTableExecutor.java
+++
b/kernel/single/distsql/handler/src/main/java/org/apache/shardingsphere/single/distsql/handler/update/LoadSingleTableExecutor.java
@@ -18,7 +18,7 @@
package org.apache.shardingsphere.single.distsql.handler.update;
import
org.apache.shardingsphere.distsql.handler.exception.storageunit.MissingRequiredStorageUnitsException;
-import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleCreateExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleRDLCreateExecutor;
import org.apache.shardingsphere.infra.database.DatabaseTypeEngine;
import
org.apache.shardingsphere.infra.database.core.metadata.database.DialectDatabaseMetaData;
import org.apache.shardingsphere.infra.database.core.type.DatabaseTypeRegistry;
@@ -48,7 +48,7 @@ import java.util.stream.Collectors;
/**
* Load single table statement executor.
*/
-public final class LoadSingleTableExecutor implements
DatabaseRuleCreateExecutor<LoadSingleTableStatement, SingleRuleConfiguration> {
+public final class LoadSingleTableExecutor implements
DatabaseRuleRDLCreateExecutor<LoadSingleTableStatement,
SingleRuleConfiguration> {
@Override
public void checkSQLStatement(final ShardingSphereDatabase database, final
LoadSingleTableStatement sqlStatement, final SingleRuleConfiguration
currentRuleConfig) {
diff --git
a/kernel/single/distsql/handler/src/main/java/org/apache/shardingsphere/single/distsql/handler/update/SetDefaultSingleTableStorageUnitExecutor.java
b/kernel/single/distsql/handler/src/main/java/org/apache/shardingsphere/single/distsql/handler/update/SetDefaultSingleTableStorageUnitExecutor.java
index b920249debe..809ae0f5b47 100644
---
a/kernel/single/distsql/handler/src/main/java/org/apache/shardingsphere/single/distsql/handler/update/SetDefaultSingleTableStorageUnitExecutor.java
+++
b/kernel/single/distsql/handler/src/main/java/org/apache/shardingsphere/single/distsql/handler/update/SetDefaultSingleTableStorageUnitExecutor.java
@@ -19,7 +19,7 @@ package
org.apache.shardingsphere.single.distsql.handler.update;
import com.google.common.base.Strings;
import
org.apache.shardingsphere.distsql.handler.exception.storageunit.MissingRequiredStorageUnitsException;
-import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleCreateExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleRDLCreateExecutor;
import
org.apache.shardingsphere.infra.exception.core.ShardingSpherePreconditions;
import
org.apache.shardingsphere.infra.metadata.database.ShardingSphereDatabase;
import org.apache.shardingsphere.single.api.config.SingleRuleConfiguration;
@@ -31,7 +31,7 @@ import java.util.Collections;
/**
* Set default single table storage unit executor.
*/
-public final class SetDefaultSingleTableStorageUnitExecutor implements
DatabaseRuleCreateExecutor<SetDefaultSingleTableStorageUnitStatement,
SingleRuleConfiguration> {
+public final class SetDefaultSingleTableStorageUnitExecutor implements
DatabaseRuleRDLCreateExecutor<SetDefaultSingleTableStorageUnitStatement,
SingleRuleConfiguration> {
@Override
public void checkSQLStatement(final ShardingSphereDatabase database, final
SetDefaultSingleTableStorageUnitStatement sqlStatement, final
SingleRuleConfiguration currentRuleConfig) {
diff --git
a/kernel/single/distsql/handler/src/main/java/org/apache/shardingsphere/single/distsql/handler/update/UnloadSingleTableExecutor.java
b/kernel/single/distsql/handler/src/main/java/org/apache/shardingsphere/single/distsql/handler/update/UnloadSingleTableExecutor.java
index 109ffdf614a..1a61616ae76 100644
---
a/kernel/single/distsql/handler/src/main/java/org/apache/shardingsphere/single/distsql/handler/update/UnloadSingleTableExecutor.java
+++
b/kernel/single/distsql/handler/src/main/java/org/apache/shardingsphere/single/distsql/handler/update/UnloadSingleTableExecutor.java
@@ -20,7 +20,7 @@ package
org.apache.shardingsphere.single.distsql.handler.update;
import com.google.common.base.Splitter;
import
org.apache.shardingsphere.infra.exception.dialect.exception.syntax.table.NoSuchTableException;
import
org.apache.shardingsphere.distsql.handler.exception.rule.MissingRequiredRuleException;
-import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleAlterExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleRDLAlterExecutor;
import org.apache.shardingsphere.infra.database.core.type.DatabaseType;
import org.apache.shardingsphere.infra.database.core.type.DatabaseTypeRegistry;
import org.apache.shardingsphere.infra.datanode.DataNode;
@@ -41,7 +41,7 @@ import java.util.stream.Collectors;
/**
* Unload single table statement executor.
*/
-public final class UnloadSingleTableExecutor implements
DatabaseRuleAlterExecutor<UnloadSingleTableStatement, SingleRuleConfiguration> {
+public final class UnloadSingleTableExecutor implements
DatabaseRuleRDLAlterExecutor<UnloadSingleTableStatement,
SingleRuleConfiguration> {
@Override
public void checkSQLStatement(final ShardingSphereDatabase database, final
UnloadSingleTableStatement sqlStatement, final SingleRuleConfiguration
currentRuleConfig) {
diff --git
a/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/rdl/rule/NewRuleDefinitionBackendHandler.java
b/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/rdl/rule/NewRuleDefinitionBackendHandler.java
index b399dd35f6b..01e0cc4b727 100644
---
a/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/rdl/rule/NewRuleDefinitionBackendHandler.java
+++
b/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/rdl/rule/NewRuleDefinitionBackendHandler.java
@@ -17,9 +17,9 @@
package org.apache.shardingsphere.proxy.backend.handler.distsql.rdl.rule;
-import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleAlterExecutor;
-import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleCreateExecutor;
-import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleDropExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleRDLAlterExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleRDLCreateExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleRDLDropExecutor;
import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleRDLExecutor;
import org.apache.shardingsphere.distsql.statement.rdl.RuleDefinitionStatement;
import org.apache.shardingsphere.infra.config.rule.RuleConfiguration;
@@ -101,20 +101,20 @@ public final class NewRuleDefinitionBackendHandler<T
extends RuleDefinitionState
@SuppressWarnings("rawtypes")
private Collection<MetaDataVersion> processSQLStatement(final
ShardingSphereDatabase database,
final T
sqlStatement, final DatabaseRuleRDLExecutor executor, final RuleConfiguration
currentRuleConfig) {
- if (executor instanceof DatabaseRuleCreateExecutor) {
- return processCreate(database, sqlStatement,
(DatabaseRuleCreateExecutor) executor, currentRuleConfig);
+ if (executor instanceof DatabaseRuleRDLCreateExecutor) {
+ return processCreate(database, sqlStatement,
(DatabaseRuleRDLCreateExecutor) executor, currentRuleConfig);
}
- if (executor instanceof DatabaseRuleAlterExecutor) {
- return processAlter(database, sqlStatement,
(DatabaseRuleAlterExecutor) executor, currentRuleConfig);
+ if (executor instanceof DatabaseRuleRDLAlterExecutor) {
+ return processAlter(database, sqlStatement,
(DatabaseRuleRDLAlterExecutor) executor, currentRuleConfig);
}
- if (executor instanceof DatabaseRuleDropExecutor) {
- return processDrop(database, sqlStatement,
(DatabaseRuleDropExecutor) executor, currentRuleConfig);
+ if (executor instanceof DatabaseRuleRDLDropExecutor) {
+ return processDrop(database, sqlStatement,
(DatabaseRuleRDLDropExecutor) executor, currentRuleConfig);
}
throw new UnsupportedSQLOperationException(String.format("Cannot
support RDL executor type `%s`", executor.getClass().getName()));
}
@SuppressWarnings({"rawtypes", "unchecked"})
- private Collection<MetaDataVersion> processCreate(final
ShardingSphereDatabase database, final T sqlStatement, final
DatabaseRuleCreateExecutor executor,
+ private Collection<MetaDataVersion> processCreate(final
ShardingSphereDatabase database, final T sqlStatement, final
DatabaseRuleRDLCreateExecutor executor,
final RuleConfiguration
currentRuleConfig) {
RuleConfiguration toBeCreatedRuleConfig =
executor.buildToBeCreatedRuleConfiguration(currentRuleConfig, sqlStatement);
if (null != currentRuleConfig) {
@@ -128,7 +128,8 @@ public final class NewRuleDefinitionBackendHandler<T
extends RuleDefinitionState
}
@SuppressWarnings({"rawtypes", "unchecked"})
- private Collection<MetaDataVersion> processAlter(final
ShardingSphereDatabase database, final T sqlStatement, final
DatabaseRuleAlterExecutor executor, final RuleConfiguration currentRuleConfig) {
+ private Collection<MetaDataVersion> processAlter(final
ShardingSphereDatabase database,
+ final T sqlStatement,
final DatabaseRuleRDLAlterExecutor executor, final RuleConfiguration
currentRuleConfig) {
RuleConfiguration toBeAlteredRuleConfig =
executor.buildToBeAlteredRuleConfiguration(sqlStatement);
executor.updateCurrentRuleConfiguration(currentRuleConfig,
toBeAlteredRuleConfig);
if (sqlStatement instanceof UnloadSingleTableStatement) {
@@ -150,7 +151,8 @@ public final class NewRuleDefinitionBackendHandler<T
extends RuleDefinitionState
}
@SuppressWarnings({"rawtypes", "unchecked"})
- private Collection<MetaDataVersion> processDrop(final
ShardingSphereDatabase database, final T sqlStatement, final
DatabaseRuleDropExecutor executor, final RuleConfiguration currentRuleConfig) {
+ private Collection<MetaDataVersion> processDrop(final
ShardingSphereDatabase database,
+ final T sqlStatement,
final DatabaseRuleRDLDropExecutor executor, final RuleConfiguration
currentRuleConfig) {
if (!executor.hasAnyOneToBeDropped(sqlStatement, currentRuleConfig)) {
return Collections.emptyList();
}
@@ -175,6 +177,6 @@ public final class NewRuleDefinitionBackendHandler<T
extends RuleDefinitionState
@SuppressWarnings({"rawtypes", "unchecked"})
private boolean getRefreshStatus(final SQLStatement sqlStatement, final
RuleConfiguration currentRuleConfig, final DatabaseRuleRDLExecutor<?, ?>
executor) {
- return !(executor instanceof DatabaseRuleDropExecutor) ||
((DatabaseRuleDropExecutor) executor).hasAnyOneToBeDropped(sqlStatement,
currentRuleConfig);
+ return !(executor instanceof DatabaseRuleRDLDropExecutor) ||
((DatabaseRuleRDLDropExecutor) executor).hasAnyOneToBeDropped(sqlStatement,
currentRuleConfig);
}
}
diff --git
a/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/rdl/rule/RuleDefinitionBackendHandler.java
b/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/rdl/rule/RuleDefinitionBackendHandler.java
index c64542eb0a5..ede6fb5732b 100644
---
a/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/rdl/rule/RuleDefinitionBackendHandler.java
+++
b/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/rdl/rule/RuleDefinitionBackendHandler.java
@@ -17,9 +17,9 @@
package org.apache.shardingsphere.proxy.backend.handler.distsql.rdl.rule;
-import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleAlterExecutor;
-import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleCreateExecutor;
-import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleDropExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleRDLAlterExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleRDLCreateExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleRDLDropExecutor;
import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleRDLExecutor;
import org.apache.shardingsphere.distsql.statement.rdl.RuleDefinitionStatement;
import org.apache.shardingsphere.infra.config.rule.RuleConfiguration;
@@ -83,18 +83,18 @@ public final class RuleDefinitionBackendHandler<T extends
RuleDefinitionStatemen
private Collection<RuleConfiguration> processSQLStatement(final
ShardingSphereDatabase database,
final T
sqlStatement, final DatabaseRuleRDLExecutor executor, final RuleConfiguration
currentRuleConfig) {
Collection<RuleConfiguration> result = new
LinkedList<>(database.getRuleMetaData().getConfigurations());
- if (executor instanceof DatabaseRuleCreateExecutor) {
+ if (executor instanceof DatabaseRuleRDLCreateExecutor) {
if (null != currentRuleConfig) {
result.remove(currentRuleConfig);
}
- RuleConfiguration createdRuleConfig = processCreate(sqlStatement,
(DatabaseRuleCreateExecutor) executor, currentRuleConfig);
+ RuleConfiguration createdRuleConfig = processCreate(sqlStatement,
(DatabaseRuleRDLCreateExecutor) executor, currentRuleConfig);
result.add(decorateRuleConfiguration(database, createdRuleConfig));
- } else if (executor instanceof DatabaseRuleAlterExecutor) {
+ } else if (executor instanceof DatabaseRuleRDLAlterExecutor) {
result.remove(currentRuleConfig);
- RuleConfiguration alteredRuleConfig = processAlter(sqlStatement,
(DatabaseRuleAlterExecutor) executor, currentRuleConfig);
+ RuleConfiguration alteredRuleConfig = processAlter(sqlStatement,
(DatabaseRuleRDLAlterExecutor) executor, currentRuleConfig);
result.add(decorateRuleConfiguration(database, alteredRuleConfig));
- } else if (executor instanceof DatabaseRuleDropExecutor) {
- processDrop(database, result, sqlStatement,
(DatabaseRuleDropExecutor) executor, currentRuleConfig);
+ } else if (executor instanceof DatabaseRuleRDLDropExecutor) {
+ processDrop(database, result, sqlStatement,
(DatabaseRuleRDLDropExecutor) executor, currentRuleConfig);
} else {
throw new UnsupportedSQLOperationException(String.format("Cannot
support RDL executor type `%s`", executor.getClass().getName()));
}
@@ -111,7 +111,7 @@ public final class RuleDefinitionBackendHandler<T extends
RuleDefinitionStatemen
}
@SuppressWarnings({"rawtypes", "unchecked"})
- private RuleConfiguration processCreate(final T sqlStatement, final
DatabaseRuleCreateExecutor executor, final RuleConfiguration currentRuleConfig)
{
+ private RuleConfiguration processCreate(final T sqlStatement, final
DatabaseRuleRDLCreateExecutor executor, final RuleConfiguration
currentRuleConfig) {
RuleConfiguration toBeCreatedRuleConfig =
executor.buildToBeCreatedRuleConfiguration(currentRuleConfig, sqlStatement);
if (null == currentRuleConfig) {
return toBeCreatedRuleConfig;
@@ -121,7 +121,7 @@ public final class RuleDefinitionBackendHandler<T extends
RuleDefinitionStatemen
}
@SuppressWarnings({"rawtypes", "unchecked"})
- private RuleConfiguration processAlter(final T sqlStatement, final
DatabaseRuleAlterExecutor executor, final RuleConfiguration currentRuleConfig) {
+ private RuleConfiguration processAlter(final T sqlStatement, final
DatabaseRuleRDLAlterExecutor executor, final RuleConfiguration
currentRuleConfig) {
RuleConfiguration toBeAlteredRuleConfig =
executor.buildToBeAlteredRuleConfiguration(sqlStatement);
executor.updateCurrentRuleConfiguration(currentRuleConfig,
toBeAlteredRuleConfig);
return currentRuleConfig;
@@ -129,7 +129,7 @@ public final class RuleDefinitionBackendHandler<T extends
RuleDefinitionStatemen
@SuppressWarnings({"rawtypes", "unchecked"})
private void processDrop(final ShardingSphereDatabase database, final
Collection<RuleConfiguration> configs, final T sqlStatement,
- final DatabaseRuleDropExecutor executor, final
RuleConfiguration currentRuleConfig) {
+ final DatabaseRuleRDLDropExecutor executor, final
RuleConfiguration currentRuleConfig) {
if (!executor.hasAnyOneToBeDropped(sqlStatement, currentRuleConfig)) {
return;
}
@@ -143,6 +143,6 @@ public final class RuleDefinitionBackendHandler<T extends
RuleDefinitionStatemen
}
private boolean getRefreshStatus(final SQLStatement sqlStatement, final
RuleConfiguration currentRuleConfig, final DatabaseRuleRDLExecutor<?, ?>
executor) {
- return !(executor instanceof DatabaseRuleDropExecutor) ||
((DatabaseRuleDropExecutor) executor).hasAnyOneToBeDropped(sqlStatement,
currentRuleConfig);
+ return !(executor instanceof DatabaseRuleRDLDropExecutor) ||
((DatabaseRuleRDLDropExecutor) executor).hasAnyOneToBeDropped(sqlStatement,
currentRuleConfig);
}
}
diff --git
a/proxy/backend/core/src/test/java/org/apache/shardingsphere/proxy/backend/handler/distsql/fixture/FixtureDatabaseRuleCreateExecutor.java
b/proxy/backend/core/src/test/java/org/apache/shardingsphere/proxy/backend/handler/distsql/fixture/FixtureDatabaseRuleCreateExecutor.java
index 0a13ee0bbb1..192c048fa54 100644
---
a/proxy/backend/core/src/test/java/org/apache/shardingsphere/proxy/backend/handler/distsql/fixture/FixtureDatabaseRuleCreateExecutor.java
+++
b/proxy/backend/core/src/test/java/org/apache/shardingsphere/proxy/backend/handler/distsql/fixture/FixtureDatabaseRuleCreateExecutor.java
@@ -17,10 +17,10 @@
package org.apache.shardingsphere.proxy.backend.handler.distsql.fixture;
-import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleCreateExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleRDLCreateExecutor;
import
org.apache.shardingsphere.infra.metadata.database.ShardingSphereDatabase;
-public final class FixtureDatabaseRuleCreateExecutor implements
DatabaseRuleCreateExecutor<CreateFixtureRuleStatement,
FixtureRuleConfiguration> {
+public final class FixtureDatabaseRuleCreateExecutor implements
DatabaseRuleRDLCreateExecutor<CreateFixtureRuleStatement,
FixtureRuleConfiguration> {
@Override
public FixtureRuleConfiguration buildToBeCreatedRuleConfiguration(final
FixtureRuleConfiguration currentRuleConfig, final CreateFixtureRuleStatement
sqlStatement) {