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 bad6b2f5c99 Rename ResourceDefinitionExecutor (#29822)
bad6b2f5c99 is described below
commit bad6b2f5c99888e087e233b8a445a5bddea20497
Author: Liang Zhang <[email protected]>
AuthorDate: Wed Jan 24 09:49:09 2024 +0800
Rename ResourceDefinitionExecutor (#29822)
* Rename DistSQLVariable
* Rename ResourceRDLExecutor
* Rename ResourceDefinitionExecutor
* Rename ResourceDefinitionExecutor
* Rename GlobalRuleDefinitionExecutor
* Rename DatabaseRuleDefinitionExecutor
---
.../update/CreateBroadcastTableRuleExecutor.java | 4 +--
.../update/DropBroadcastTableRuleExecutor.java | 4 +--
...l.rule.database.DatabaseRuleDefinitionExecutor} | 0
.../handler/update/AlterEncryptRuleExecutor.java | 4 +--
.../handler/update/CreateEncryptRuleExecutor.java | 4 +--
.../handler/update/DropEncryptRuleExecutor.java | 4 +--
...l.rule.database.DatabaseRuleDefinitionExecutor} | 0
.../handler/update/AlterMaskRuleExecutor.java | 4 +--
.../handler/update/CreateMaskRuleExecutor.java | 4 +--
.../handler/update/DropMaskRuleExecutor.java | 4 +--
...l.rule.database.DatabaseRuleDefinitionExecutor} | 0
.../AlterReadwriteSplittingRuleExecutor.java | 4 +--
.../CreateReadwriteSplittingRuleExecutor.java | 4 +--
.../update/DropReadwriteSplittingRuleExecutor.java | 4 +--
...l.rule.database.DatabaseRuleDefinitionExecutor} | 0
.../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 +--
...l.rule.database.DatabaseRuleDefinitionExecutor} | 0
.../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 +--
...l.rule.database.DatabaseRuleDefinitionExecutor} | 0
.../ResourceDefinitionExecutor.java} | 10 +++----
.../DatabaseAwareResourceDefinitionExecutor.java} | 12 ++++----
.../database/DatabaseRuleAlterExecutor.java} | 6 ++--
.../database/DatabaseRuleCreateExecutor.java} | 6 ++--
.../database/DatabaseRuleDefinitionExecutor.java} | 6 ++--
.../database/DatabaseRuleDropExecutor.java} | 6 ++--
.../global/GlobalRuleDefinitionExecutor.java} | 6 ++--
.../update/AlterGlobalClockRuleExecutor.java | 4 +--
...e.rdl.rule.global.GlobalRuleDefinitionExecutor} | 0
.../handler/update/LoadSingleTableExecutor.java | 4 +--
.../SetDefaultSingleTableStorageUnitExecutor.java | 4 +--
.../handler/update/UnloadSingleTableExecutor.java | 4 +--
...l.rule.database.DatabaseRuleDefinitionExecutor} | 0
.../update/AlterSQLFederationRuleExecutor.java | 4 +--
...e.rdl.rule.global.GlobalRuleDefinitionExecutor} | 0
.../handler/update/AlterSQLParserRuleExecutor.java | 4 +--
...e.rdl.rule.global.GlobalRuleDefinitionExecutor} | 0
.../update/AlterSQLTranslatorRuleExecutor.java | 4 +--
...e.rdl.rule.global.GlobalRuleDefinitionExecutor} | 0
.../handler/update/AlterTrafficRuleExecutor.java | 4 +--
...e.rdl.rule.global.GlobalRuleDefinitionExecutor} | 0
.../update/AlterTransactionRuleExecutor.java | 4 +--
...e.rdl.rule.global.GlobalRuleDefinitionExecutor} | 0
.../VariableEnum.java => DistSQLVariable.java} | 8 ++---
.../ral/queryable/ShowDistVariableExecutor.java | 4 +--
.../ral/queryable/ShowDistVariablesExecutor.java | 4 +--
.../distsql/rdl/RDLBackendHandlerFactory.java | 10 +++----
.../resource/ResourceDefinitionBackendHandler.java | 9 +++---
.../resource/type/AlterStorageUnitExecutor.java | 6 ++--
.../resource/type/RegisterStorageUnitExecutor.java | 4 +--
.../type/UnregisterStorageUnitExecutor.java | 4 +--
.../rdl/rule/RuleDefinitionBackendHandler.java | 8 ++---
.../rdl/rule/database/DatabaseRuleUpdater.java | 8 ++---
.../DatabaseRuleRDLExecuteEngineFactory.java | 22 +++++++-------
.../type/AlterDatabaseRuleRDLExecuteEngine.java | 4 +--
.../type/CreateDatabaseRuleRDLExecuteEngine.java | 4 +--
.../type/DropDatabaseRuleRDLExecuteEngine.java | 4 +--
.../distsql/rdl/rule/global/GlobalRuleUpdater.java | 4 +--
.../rdl/rule/legacy/LegacyGlobalRuleUpdater.java | 6 ++--
.../legacy/LegacyRuleDefinitionBackendHandler.java | 34 +++++++++++-----------
...r.type.rdl.resource.ResourceDefinitionExecutor} | 0
.../fixture/FixtureDatabaseRuleCreateExecutor.java | 4 +--
...l.rule.database.DatabaseRuleDefinitionExecutor} | 0
79 files changed, 177 insertions(+), 178 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 3cfc4aa6dd9..066ba06af08 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.DatabaseRuleRDLCreateExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.rule.database.DatabaseRuleCreateExecutor;
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
DatabaseRuleRDLCreateExecutor<CreateBroadcastTableRuleStatement,
BroadcastRuleConfiguration> {
+public final class CreateBroadcastTableRuleExecutor implements
DatabaseRuleCreateExecutor<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 8914e454605..700aa1e078a 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.DatabaseRuleRDLDropExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.rule.database.DatabaseRuleDropExecutor;
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
DatabaseRuleRDLDropExecutor<DropBroadcastTableRuleStatement,
BroadcastRuleConfiguration> {
+public final class DropBroadcastTableRuleExecutor implements
DatabaseRuleDropExecutor<DropBroadcastTableRuleStatement,
BroadcastRuleConfiguration> {
@Override
public void checkSQLStatement(final ShardingSphereDatabase database, final
DropBroadcastTableRuleStatement sqlStatement, final BroadcastRuleConfiguration
currentRuleConfig) {
diff --git
a/features/broadcast/distsql/handler/src/main/resources/META-INF/services/org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleRDLExecutor
b/features/broadcast/distsql/handler/src/main/resources/META-INF/services/org.apache.shardingsphere.distsql.handler.type.rdl.rule.database.DatabaseRuleDefinitionExecutor
similarity index 100%
rename from
features/broadcast/distsql/handler/src/main/resources/META-INF/services/org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleRDLExecutor
rename to
features/broadcast/distsql/handler/src/main/resources/META-INF/services/org.apache.shardingsphere.distsql.handler.type.rdl.rule.database.DatabaseRuleDefinitionExecutor
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 2eecd18464d..2336b75aef1 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.DatabaseRuleRDLAlterExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.rule.database.DatabaseRuleAlterExecutor;
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
DatabaseRuleRDLAlterExecutor<AlterEncryptRuleStatement,
EncryptRuleConfiguration> {
+public final class AlterEncryptRuleExecutor implements
DatabaseRuleAlterExecutor<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 28f2a0be51d..1fb303bc589 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.DatabaseRuleRDLCreateExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.rule.database.DatabaseRuleCreateExecutor;
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
DatabaseRuleRDLCreateExecutor<CreateEncryptRuleStatement,
EncryptRuleConfiguration> {
+public final class CreateEncryptRuleExecutor implements
DatabaseRuleCreateExecutor<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 7dfdb0722e8..d623913aa6f 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.DatabaseRuleRDLDropExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.rule.database.DatabaseRuleDropExecutor;
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
DatabaseRuleRDLDropExecutor<DropEncryptRuleStatement, EncryptRuleConfiguration>
{
+public final class DropEncryptRuleExecutor implements
DatabaseRuleDropExecutor<DropEncryptRuleStatement, EncryptRuleConfiguration> {
@Override
public void checkSQLStatement(final ShardingSphereDatabase database, final
DropEncryptRuleStatement sqlStatement, final EncryptRuleConfiguration
currentRuleConfig) {
diff --git
a/features/encrypt/distsql/handler/src/main/resources/META-INF/services/org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleRDLExecutor
b/features/encrypt/distsql/handler/src/main/resources/META-INF/services/org.apache.shardingsphere.distsql.handler.type.rdl.rule.database.DatabaseRuleDefinitionExecutor
similarity index 100%
rename from
features/encrypt/distsql/handler/src/main/resources/META-INF/services/org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleRDLExecutor
rename to
features/encrypt/distsql/handler/src/main/resources/META-INF/services/org.apache.shardingsphere.distsql.handler.type.rdl.rule.database.DatabaseRuleDefinitionExecutor
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 4251f299e81..71038bb594a 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.DatabaseRuleRDLAlterExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.rule.database.DatabaseRuleAlterExecutor;
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
DatabaseRuleRDLAlterExecutor<AlterMaskRuleStatement, MaskRuleConfiguration> {
+public final class AlterMaskRuleExecutor implements
DatabaseRuleAlterExecutor<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 1a6ab8a5728..96379c91b78 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.DatabaseRuleRDLCreateExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.rule.database.DatabaseRuleCreateExecutor;
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
DatabaseRuleRDLCreateExecutor<CreateMaskRuleStatement, MaskRuleConfiguration> {
+public final class CreateMaskRuleExecutor implements
DatabaseRuleCreateExecutor<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 11597754335..a2f789081bb 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.DatabaseRuleRDLDropExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.rule.database.DatabaseRuleDropExecutor;
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
DatabaseRuleRDLDropExecutor<DropMaskRuleStatement, MaskRuleConfiguration> {
+public final class DropMaskRuleExecutor implements
DatabaseRuleDropExecutor<DropMaskRuleStatement, MaskRuleConfiguration> {
@Override
public void checkSQLStatement(final ShardingSphereDatabase database, final
DropMaskRuleStatement sqlStatement, final MaskRuleConfiguration
currentRuleConfig) {
diff --git
a/features/mask/distsql/handler/src/main/resources/META-INF/services/org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleRDLExecutor
b/features/mask/distsql/handler/src/main/resources/META-INF/services/org.apache.shardingsphere.distsql.handler.type.rdl.rule.database.DatabaseRuleDefinitionExecutor
similarity index 100%
rename from
features/mask/distsql/handler/src/main/resources/META-INF/services/org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleRDLExecutor
rename to
features/mask/distsql/handler/src/main/resources/META-INF/services/org.apache.shardingsphere.distsql.handler.type.rdl.rule.database.DatabaseRuleDefinitionExecutor
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 d5b720e49d6..8b7808e7f62 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.DatabaseRuleRDLAlterExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.rule.database.DatabaseRuleAlterExecutor;
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
DatabaseRuleRDLAlterExecutor<AlterReadwriteSplittingRuleStatement,
ReadwriteSplittingRuleConfiguration> {
+public final class AlterReadwriteSplittingRuleExecutor implements
DatabaseRuleAlterExecutor<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 ced25e237ae..6c2c7c85e22 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.DatabaseRuleRDLCreateExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.rule.database.DatabaseRuleCreateExecutor;
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
DatabaseRuleRDLCreateExecutor<CreateReadwriteSplittingRuleStatement,
ReadwriteSplittingRuleConfiguration> {
+public final class CreateReadwriteSplittingRuleExecutor implements
DatabaseRuleCreateExecutor<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 7b3e7c990bf..6ede7766444 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.DatabaseRuleRDLDropExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.rule.database.DatabaseRuleDropExecutor;
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
DatabaseRuleRDLDropExecutor<DropReadwriteSplittingRuleStatement,
ReadwriteSplittingRuleConfiguration> {
+public final class DropReadwriteSplittingRuleExecutor implements
DatabaseRuleDropExecutor<DropReadwriteSplittingRuleStatement,
ReadwriteSplittingRuleConfiguration> {
@Override
public void checkSQLStatement(final ShardingSphereDatabase database, final
DropReadwriteSplittingRuleStatement sqlStatement, final
ReadwriteSplittingRuleConfiguration currentRuleConfig) {
diff --git
a/features/readwrite-splitting/distsql/handler/src/main/resources/META-INF/services/org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleRDLExecutor
b/features/readwrite-splitting/distsql/handler/src/main/resources/META-INF/services/org.apache.shardingsphere.distsql.handler.type.rdl.rule.database.DatabaseRuleDefinitionExecutor
similarity index 100%
rename from
features/readwrite-splitting/distsql/handler/src/main/resources/META-INF/services/org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleRDLExecutor
rename to
features/readwrite-splitting/distsql/handler/src/main/resources/META-INF/services/org.apache.shardingsphere.distsql.handler.type.rdl.rule.database.DatabaseRuleDefinitionExecutor
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 dd7116ae991..a15371a4f32 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.DatabaseRuleRDLAlterExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.rule.database.DatabaseRuleAlterExecutor;
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
DatabaseRuleRDLAlterExecutor<AlterDefaultShadowAlgorithmStatement,
ShadowRuleConfiguration> {
+public final class AlterDefaultShadowAlgorithmExecutor implements
DatabaseRuleAlterExecutor<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 c0ada89fa79..0923537929f 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.DatabaseRuleRDLAlterExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.rule.database.DatabaseRuleAlterExecutor;
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
DatabaseRuleRDLAlterExecutor<AlterShadowRuleStatement, ShadowRuleConfiguration>
{
+public final class AlterShadowRuleExecutor implements
DatabaseRuleAlterExecutor<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 030301a36d1..7fc4ad02f6a 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.DatabaseRuleRDLCreateExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.rule.database.DatabaseRuleCreateExecutor;
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
DatabaseRuleRDLCreateExecutor<CreateDefaultShadowAlgorithmStatement,
ShadowRuleConfiguration> {
+public final class CreateDefaultShadowAlgorithmExecutor implements
DatabaseRuleCreateExecutor<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 ff86629f9ce..b3a87a0cfcf 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.DatabaseRuleRDLCreateExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.rule.database.DatabaseRuleCreateExecutor;
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
DatabaseRuleRDLCreateExecutor<CreateShadowRuleStatement,
ShadowRuleConfiguration> {
+public final class CreateShadowRuleExecutor implements
DatabaseRuleCreateExecutor<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 2551b551eea..780656650fd 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.DatabaseRuleRDLDropExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.rule.database.DatabaseRuleDropExecutor;
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
DatabaseRuleRDLDropExecutor<DropDefaultShadowAlgorithmStatement,
ShadowRuleConfiguration> {
+public final class DropDefaultShadowAlgorithmExecutor implements
DatabaseRuleDropExecutor<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 64aee5726df..bb8400c5266 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.DatabaseRuleRDLDropExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.rule.database.DatabaseRuleDropExecutor;
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
DatabaseRuleRDLDropExecutor<DropShadowAlgorithmStatement,
ShadowRuleConfiguration> {
+public final class DropShadowAlgorithmExecutor implements
DatabaseRuleDropExecutor<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 b44fcc6c1ad..75ea1caf516 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.DatabaseRuleRDLDropExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.rule.database.DatabaseRuleDropExecutor;
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
DatabaseRuleRDLDropExecutor<DropShadowRuleStatement, ShadowRuleConfiguration> {
+public final class DropShadowRuleExecutor implements
DatabaseRuleDropExecutor<DropShadowRuleStatement, ShadowRuleConfiguration> {
@Override
public void checkSQLStatement(final ShardingSphereDatabase database, final
DropShadowRuleStatement sqlStatement, final ShadowRuleConfiguration
currentRuleConfig) {
diff --git
a/features/shadow/distsql/handler/src/main/resources/META-INF/services/org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleRDLExecutor
b/features/shadow/distsql/handler/src/main/resources/META-INF/services/org.apache.shardingsphere.distsql.handler.type.rdl.rule.database.DatabaseRuleDefinitionExecutor
similarity index 100%
rename from
features/shadow/distsql/handler/src/main/resources/META-INF/services/org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleRDLExecutor
rename to
features/shadow/distsql/handler/src/main/resources/META-INF/services/org.apache.shardingsphere.distsql.handler.type.rdl.rule.database.DatabaseRuleDefinitionExecutor
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 8a6762c959c..2e5bd08913e 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.DatabaseRuleRDLAlterExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.rule.database.DatabaseRuleAlterExecutor;
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
DatabaseRuleRDLAlterExecutor<AlterDefaultShardingStrategyStatement,
ShardingRuleConfiguration> {
+public final class AlterDefaultShardingStrategyExecutor implements
DatabaseRuleAlterExecutor<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 d5d959f8902..b3e9a075387 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.DatabaseRuleRDLAlterExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.rule.database.DatabaseRuleAlterExecutor;
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
DatabaseRuleRDLAlterExecutor<AlterShardingTableReferenceRuleStatement,
ShardingRuleConfiguration> {
+public final class AlterShardingTableReferenceRuleExecutor implements
DatabaseRuleAlterExecutor<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 708f1735bee..c6551a722c2 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.DatabaseRuleRDLAlterExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.rule.database.DatabaseRuleAlterExecutor;
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
DatabaseRuleRDLAlterExecutor<AlterShardingTableRuleStatement,
ShardingRuleConfiguration> {
+public final class AlterShardingTableRuleExecutor implements
DatabaseRuleAlterExecutor<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 5c447e0f430..917f7d29de3 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.DatabaseRuleRDLCreateExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.rule.database.DatabaseRuleCreateExecutor;
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
DatabaseRuleRDLCreateExecutor<CreateDefaultShardingStrategyStatement,
ShardingRuleConfiguration> {
+public final class CreateDefaultShardingStrategyExecutor implements
DatabaseRuleCreateExecutor<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 1a9eedbb5e5..cd1933ea9d0 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.DatabaseRuleRDLCreateExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.rule.database.DatabaseRuleCreateExecutor;
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
DatabaseRuleRDLCreateExecutor<CreateShardingTableReferenceRuleStatement,
ShardingRuleConfiguration> {
+public final class CreateShardingTableReferenceRuleExecutor implements
DatabaseRuleCreateExecutor<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 b57eed40200..99e07ddce6c 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.DatabaseRuleRDLCreateExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.rule.database.DatabaseRuleCreateExecutor;
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
DatabaseRuleRDLCreateExecutor<CreateShardingTableRuleStatement,
ShardingRuleConfiguration> {
+public final class CreateShardingTableRuleExecutor implements
DatabaseRuleCreateExecutor<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 d7623bbc0a0..c6ace7f52db 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.DatabaseRuleRDLDropExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.rule.database.DatabaseRuleDropExecutor;
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
DatabaseRuleRDLDropExecutor<DropDefaultShardingStrategyStatement,
ShardingRuleConfiguration> {
+public final class DropDefaultShardingStrategyExecutor implements
DatabaseRuleDropExecutor<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 6e711815406..fe7c5045b1b 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.DatabaseRuleRDLDropExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.rule.database.DatabaseRuleDropExecutor;
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
DatabaseRuleRDLDropExecutor<DropShardingAlgorithmStatement,
ShardingRuleConfiguration> {
+public final class DropShardingAlgorithmExecutor implements
DatabaseRuleDropExecutor<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 17e5ee84a34..c316a02e04d 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.DatabaseRuleRDLDropExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.rule.database.DatabaseRuleDropExecutor;
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
DatabaseRuleRDLDropExecutor<DropShardingAuditorStatement,
ShardingRuleConfiguration> {
+public final class DropShardingAuditorExecutor implements
DatabaseRuleDropExecutor<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 ac35662a619..fb61082bc5c 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.DatabaseRuleRDLDropExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.rule.database.DatabaseRuleDropExecutor;
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
DatabaseRuleRDLDropExecutor<DropShardingKeyGeneratorStatement,
ShardingRuleConfiguration> {
+public final class DropShardingKeyGeneratorExecutor implements
DatabaseRuleDropExecutor<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 ea0905d16d5..64284a37f4d 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.DatabaseRuleRDLDropExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.rule.database.DatabaseRuleDropExecutor;
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
DatabaseRuleRDLDropExecutor<DropShardingTableReferenceRuleStatement,
ShardingRuleConfiguration> {
+public final class DropShardingTableReferenceExecutor implements
DatabaseRuleDropExecutor<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 a7b36eb1331..0ab0dd97a74 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.DatabaseRuleRDLDropExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.rule.database.DatabaseRuleDropExecutor;
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
DatabaseRuleRDLDropExecutor<DropShardingTableRuleStatement,
ShardingRuleConfiguration> {
+public final class DropShardingTableRuleExecutor implements
DatabaseRuleDropExecutor<DropShardingTableRuleStatement,
ShardingRuleConfiguration> {
@Override
public void checkSQLStatement(final ShardingSphereDatabase database, final
DropShardingTableRuleStatement sqlStatement, final ShardingRuleConfiguration
currentRuleConfig) {
diff --git
a/features/sharding/distsql/handler/src/main/resources/META-INF/services/org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleRDLExecutor
b/features/sharding/distsql/handler/src/main/resources/META-INF/services/org.apache.shardingsphere.distsql.handler.type.rdl.rule.database.DatabaseRuleDefinitionExecutor
similarity index 100%
rename from
features/sharding/distsql/handler/src/main/resources/META-INF/services/org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleRDLExecutor
rename to
features/sharding/distsql/handler/src/main/resources/META-INF/services/org.apache.shardingsphere.distsql.handler.type.rdl.rule.database.DatabaseRuleDefinitionExecutor
diff --git
a/infra/distsql-handler/src/main/java/org/apache/shardingsphere/distsql/handler/type/rdl/RDLExecutor.java
b/infra/distsql-handler/src/main/java/org/apache/shardingsphere/distsql/handler/type/rdl/resource/ResourceDefinitionExecutor.java
similarity index 76%
rename from
infra/distsql-handler/src/main/java/org/apache/shardingsphere/distsql/handler/type/rdl/RDLExecutor.java
rename to
infra/distsql-handler/src/main/java/org/apache/shardingsphere/distsql/handler/type/rdl/resource/ResourceDefinitionExecutor.java
index 8e533d6a09c..ca57a1072ff 100644
---
a/infra/distsql-handler/src/main/java/org/apache/shardingsphere/distsql/handler/type/rdl/RDLExecutor.java
+++
b/infra/distsql-handler/src/main/java/org/apache/shardingsphere/distsql/handler/type/rdl/resource/ResourceDefinitionExecutor.java
@@ -15,19 +15,19 @@
* limitations under the License.
*/
-package org.apache.shardingsphere.distsql.handler.type.rdl;
+package org.apache.shardingsphere.distsql.handler.type.rdl.resource;
-import org.apache.shardingsphere.distsql.statement.rdl.RDLStatement;
+import
org.apache.shardingsphere.distsql.statement.rdl.StorageUnitDefinitionStatement;
import org.apache.shardingsphere.infra.spi.annotation.SingletonSPI;
import org.apache.shardingsphere.infra.spi.type.typed.TypedSPI;
/**
- * RDL executor.
+ * Resource definition executor.
*
- * @param <T> type of RQL statement
+ * @param <T> type of storage unit definition statement
*/
@SingletonSPI
-public interface RDLExecutor<T extends RDLStatement> extends TypedSPI {
+public interface ResourceDefinitionExecutor<T extends
StorageUnitDefinitionStatement> extends TypedSPI {
/**
* Execute update.
diff --git
a/infra/distsql-handler/src/main/java/org/apache/shardingsphere/distsql/handler/type/rdl/aware/DatabaseAwareRDLExecutor.java
b/infra/distsql-handler/src/main/java/org/apache/shardingsphere/distsql/handler/type/rdl/resource/aware/DatabaseAwareResourceDefinitionExecutor.java
similarity index 67%
rename from
infra/distsql-handler/src/main/java/org/apache/shardingsphere/distsql/handler/type/rdl/aware/DatabaseAwareRDLExecutor.java
rename to
infra/distsql-handler/src/main/java/org/apache/shardingsphere/distsql/handler/type/rdl/resource/aware/DatabaseAwareResourceDefinitionExecutor.java
index 81d010af70a..449b8258b58 100644
---
a/infra/distsql-handler/src/main/java/org/apache/shardingsphere/distsql/handler/type/rdl/aware/DatabaseAwareRDLExecutor.java
+++
b/infra/distsql-handler/src/main/java/org/apache/shardingsphere/distsql/handler/type/rdl/resource/aware/DatabaseAwareResourceDefinitionExecutor.java
@@ -15,18 +15,18 @@
* limitations under the License.
*/
-package org.apache.shardingsphere.distsql.handler.type.rdl.aware;
+package org.apache.shardingsphere.distsql.handler.type.rdl.resource.aware;
-import org.apache.shardingsphere.distsql.handler.type.rdl.RDLExecutor;
-import org.apache.shardingsphere.distsql.statement.rdl.RDLStatement;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.resource.ResourceDefinitionExecutor;
+import
org.apache.shardingsphere.distsql.statement.rdl.StorageUnitDefinitionStatement;
import
org.apache.shardingsphere.infra.metadata.database.ShardingSphereDatabase;
/**
- * Database aware RDL executor.
+ * Database aware resource definition executor.
*
- * @param <T> type of SQL statement
+ * @param <T> type of storage unit definition statement
*/
-public interface DatabaseAwareRDLExecutor<T extends RDLStatement> extends
RDLExecutor<T> {
+public interface DatabaseAwareResourceDefinitionExecutor<T extends
StorageUnitDefinitionStatement> extends ResourceDefinitionExecutor<T> {
/**
* Set database.
diff --git
a/infra/distsql-handler/src/main/java/org/apache/shardingsphere/distsql/handler/type/rdl/database/DatabaseRuleRDLAlterExecutor.java
b/infra/distsql-handler/src/main/java/org/apache/shardingsphere/distsql/handler/type/rdl/rule/database/DatabaseRuleAlterExecutor.java
similarity index 88%
rename from
infra/distsql-handler/src/main/java/org/apache/shardingsphere/distsql/handler/type/rdl/database/DatabaseRuleRDLAlterExecutor.java
rename to
infra/distsql-handler/src/main/java/org/apache/shardingsphere/distsql/handler/type/rdl/rule/database/DatabaseRuleAlterExecutor.java
index 5b18ea88bf6..09089980bd0 100644
---
a/infra/distsql-handler/src/main/java/org/apache/shardingsphere/distsql/handler/type/rdl/database/DatabaseRuleRDLAlterExecutor.java
+++
b/infra/distsql-handler/src/main/java/org/apache/shardingsphere/distsql/handler/type/rdl/rule/database/DatabaseRuleAlterExecutor.java
@@ -15,18 +15,18 @@
* limitations under the License.
*/
-package org.apache.shardingsphere.distsql.handler.type.rdl.database;
+package org.apache.shardingsphere.distsql.handler.type.rdl.rule.database;
import org.apache.shardingsphere.infra.config.rule.RuleConfiguration;
import org.apache.shardingsphere.sql.parser.sql.common.statement.SQLStatement;
/**
- * Database rule RDL alter executor.
+ * Database rule alter executor.
*
* @param <T> type of SQL statement
* @param <R> type of rule configuration
*/
-public interface DatabaseRuleRDLAlterExecutor<T extends SQLStatement, R
extends RuleConfiguration> extends DatabaseRuleRDLExecutor<T, R> {
+public interface DatabaseRuleAlterExecutor<T extends SQLStatement, R extends
RuleConfiguration> extends DatabaseRuleDefinitionExecutor<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/DatabaseRuleRDLCreateExecutor.java
b/infra/distsql-handler/src/main/java/org/apache/shardingsphere/distsql/handler/type/rdl/rule/database/DatabaseRuleCreateExecutor.java
similarity index 86%
rename from
infra/distsql-handler/src/main/java/org/apache/shardingsphere/distsql/handler/type/rdl/database/DatabaseRuleRDLCreateExecutor.java
rename to
infra/distsql-handler/src/main/java/org/apache/shardingsphere/distsql/handler/type/rdl/rule/database/DatabaseRuleCreateExecutor.java
index f081418a50f..1ee8c85820c 100644
---
a/infra/distsql-handler/src/main/java/org/apache/shardingsphere/distsql/handler/type/rdl/database/DatabaseRuleRDLCreateExecutor.java
+++
b/infra/distsql-handler/src/main/java/org/apache/shardingsphere/distsql/handler/type/rdl/rule/database/DatabaseRuleCreateExecutor.java
@@ -15,18 +15,18 @@
* limitations under the License.
*/
-package org.apache.shardingsphere.distsql.handler.type.rdl.database;
+package org.apache.shardingsphere.distsql.handler.type.rdl.rule.database;
import org.apache.shardingsphere.infra.config.rule.RuleConfiguration;
import org.apache.shardingsphere.sql.parser.sql.common.statement.SQLStatement;
/**
- * Database rule RDL create executor.
+ * Database rule create executor.
*
* @param <T> type of SQL statement
* @param <R> type of rule configuration
*/
-public interface DatabaseRuleRDLCreateExecutor<T extends SQLStatement, R
extends RuleConfiguration> extends DatabaseRuleRDLExecutor<T, R> {
+public interface DatabaseRuleCreateExecutor<T extends SQLStatement, R extends
RuleConfiguration> extends DatabaseRuleDefinitionExecutor<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/DatabaseRuleRDLExecutor.java
b/infra/distsql-handler/src/main/java/org/apache/shardingsphere/distsql/handler/type/rdl/rule/database/DatabaseRuleDefinitionExecutor.java
similarity index 88%
rename from
infra/distsql-handler/src/main/java/org/apache/shardingsphere/distsql/handler/type/rdl/database/DatabaseRuleRDLExecutor.java
rename to
infra/distsql-handler/src/main/java/org/apache/shardingsphere/distsql/handler/type/rdl/rule/database/DatabaseRuleDefinitionExecutor.java
index c2478d85917..50bad8280eb 100644
---
a/infra/distsql-handler/src/main/java/org/apache/shardingsphere/distsql/handler/type/rdl/database/DatabaseRuleRDLExecutor.java
+++
b/infra/distsql-handler/src/main/java/org/apache/shardingsphere/distsql/handler/type/rdl/rule/database/DatabaseRuleDefinitionExecutor.java
@@ -15,7 +15,7 @@
* limitations under the License.
*/
-package org.apache.shardingsphere.distsql.handler.type.rdl.database;
+package org.apache.shardingsphere.distsql.handler.type.rdl.rule.database;
import org.apache.shardingsphere.infra.config.rule.RuleConfiguration;
import
org.apache.shardingsphere.infra.metadata.database.ShardingSphereDatabase;
@@ -24,13 +24,13 @@ import
org.apache.shardingsphere.infra.spi.type.typed.TypedSPI;
import org.apache.shardingsphere.sql.parser.sql.common.statement.SQLStatement;
/**
- * Database rule RDL executor.
+ * Database rule definition executor.
*
* @param <T> type of SQL statement
* @param <R> type of rule configuration
*/
@SingletonSPI
-public interface DatabaseRuleRDLExecutor<T extends SQLStatement, R extends
RuleConfiguration> extends TypedSPI {
+public interface DatabaseRuleDefinitionExecutor<T extends SQLStatement, R
extends RuleConfiguration> extends TypedSPI {
/**
* Check SQL statement.
diff --git
a/infra/distsql-handler/src/main/java/org/apache/shardingsphere/distsql/handler/type/rdl/database/DatabaseRuleRDLDropExecutor.java
b/infra/distsql-handler/src/main/java/org/apache/shardingsphere/distsql/handler/type/rdl/rule/database/DatabaseRuleDropExecutor.java
similarity index 93%
rename from
infra/distsql-handler/src/main/java/org/apache/shardingsphere/distsql/handler/type/rdl/database/DatabaseRuleRDLDropExecutor.java
rename to
infra/distsql-handler/src/main/java/org/apache/shardingsphere/distsql/handler/type/rdl/rule/database/DatabaseRuleDropExecutor.java
index 5400da41ec7..f2fa056846a 100644
---
a/infra/distsql-handler/src/main/java/org/apache/shardingsphere/distsql/handler/type/rdl/database/DatabaseRuleRDLDropExecutor.java
+++
b/infra/distsql-handler/src/main/java/org/apache/shardingsphere/distsql/handler/type/rdl/rule/database/DatabaseRuleDropExecutor.java
@@ -15,7 +15,7 @@
* limitations under the License.
*/
-package org.apache.shardingsphere.distsql.handler.type.rdl.database;
+package org.apache.shardingsphere.distsql.handler.type.rdl.rule.database;
import org.apache.shardingsphere.infra.config.rule.RuleConfiguration;
import org.apache.shardingsphere.sql.parser.sql.common.statement.SQLStatement;
@@ -24,12 +24,12 @@ import java.util.Collection;
import java.util.stream.Collectors;
/**
- * Database rule RDL drop executor.
+ * Database rule drop executor.
*
* @param <T> type of SQL statement
* @param <R> type of rule configuration
*/
-public interface DatabaseRuleRDLDropExecutor<T extends SQLStatement, R extends
RuleConfiguration> extends DatabaseRuleRDLExecutor<T, R> {
+public interface DatabaseRuleDropExecutor<T extends SQLStatement, R extends
RuleConfiguration> extends DatabaseRuleDefinitionExecutor<T, R> {
/**
* TODO Remove temporary default implementation
diff --git
a/infra/distsql-handler/src/main/java/org/apache/shardingsphere/distsql/handler/type/rdl/global/GlobalRuleRDLExecutor.java
b/infra/distsql-handler/src/main/java/org/apache/shardingsphere/distsql/handler/type/rdl/rule/global/GlobalRuleDefinitionExecutor.java
similarity index 89%
rename from
infra/distsql-handler/src/main/java/org/apache/shardingsphere/distsql/handler/type/rdl/global/GlobalRuleRDLExecutor.java
rename to
infra/distsql-handler/src/main/java/org/apache/shardingsphere/distsql/handler/type/rdl/rule/global/GlobalRuleDefinitionExecutor.java
index 9456ed2cb38..baab3444dab 100644
---
a/infra/distsql-handler/src/main/java/org/apache/shardingsphere/distsql/handler/type/rdl/global/GlobalRuleRDLExecutor.java
+++
b/infra/distsql-handler/src/main/java/org/apache/shardingsphere/distsql/handler/type/rdl/rule/global/GlobalRuleDefinitionExecutor.java
@@ -15,7 +15,7 @@
* limitations under the License.
*/
-package org.apache.shardingsphere.distsql.handler.type.rdl.global;
+package org.apache.shardingsphere.distsql.handler.type.rdl.rule.global;
import org.apache.shardingsphere.distsql.statement.rdl.RuleDefinitionStatement;
import org.apache.shardingsphere.infra.config.rule.RuleConfiguration;
@@ -23,13 +23,13 @@ import
org.apache.shardingsphere.infra.spi.annotation.SingletonSPI;
import org.apache.shardingsphere.infra.spi.type.typed.TypedSPI;
/**
- * Global rule RDL executor.
+ * Global rule definition executor.
*
* @param <T> type of rule definition statement
* @param <R> type of rule configuration
*/
@SingletonSPI
-public interface GlobalRuleRDLExecutor<T extends RuleDefinitionStatement, R
extends RuleConfiguration> extends TypedSPI {
+public interface GlobalRuleDefinitionExecutor<T extends
RuleDefinitionStatement, R extends RuleConfiguration> extends TypedSPI {
/**
* Check SQL statement.
diff --git
a/kernel/global-clock/distsql/handler/src/main/java/org/apache/shardingsphere/globalclock/distsql/handler/update/AlterGlobalClockRuleExecutor.java
b/kernel/global-clock/distsql/handler/src/main/java/org/apache/shardingsphere/globalclock/distsql/handler/update/AlterGlobalClockRuleExecutor.java
index 38989612d02..0eb27e0af00 100644
---
a/kernel/global-clock/distsql/handler/src/main/java/org/apache/shardingsphere/globalclock/distsql/handler/update/AlterGlobalClockRuleExecutor.java
+++
b/kernel/global-clock/distsql/handler/src/main/java/org/apache/shardingsphere/globalclock/distsql/handler/update/AlterGlobalClockRuleExecutor.java
@@ -17,14 +17,14 @@
package org.apache.shardingsphere.globalclock.distsql.handler.update;
-import
org.apache.shardingsphere.distsql.handler.type.rdl.global.GlobalRuleRDLExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.rule.global.GlobalRuleDefinitionExecutor;
import
org.apache.shardingsphere.globalclock.api.config.GlobalClockRuleConfiguration;
import
org.apache.shardingsphere.globalclock.distsql.statement.updatable.AlterGlobalClockRuleStatement;
/**
* Alter global clock rule executor.
*/
-public final class AlterGlobalClockRuleExecutor implements
GlobalRuleRDLExecutor<AlterGlobalClockRuleStatement,
GlobalClockRuleConfiguration> {
+public final class AlterGlobalClockRuleExecutor implements
GlobalRuleDefinitionExecutor<AlterGlobalClockRuleStatement,
GlobalClockRuleConfiguration> {
@Override
public void checkSQLStatement(final GlobalClockRuleConfiguration
currentRuleConfig, final AlterGlobalClockRuleStatement sqlStatement) {
diff --git
a/kernel/global-clock/distsql/handler/src/main/resources/META-INF/services/org.apache.shardingsphere.distsql.handler.type.rdl.global.GlobalRuleRDLExecutor
b/kernel/global-clock/distsql/handler/src/main/resources/META-INF/services/org.apache.shardingsphere.distsql.handler.type.rdl.rule.global.GlobalRuleDefinitionExecutor
similarity index 100%
rename from
kernel/global-clock/distsql/handler/src/main/resources/META-INF/services/org.apache.shardingsphere.distsql.handler.type.rdl.global.GlobalRuleRDLExecutor
rename to
kernel/global-clock/distsql/handler/src/main/resources/META-INF/services/org.apache.shardingsphere.distsql.handler.type.rdl.rule.global.GlobalRuleDefinitionExecutor
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 2d09b60aaa9..9590a3d0ef8 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.DatabaseRuleRDLCreateExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.rule.database.DatabaseRuleCreateExecutor;
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
DatabaseRuleRDLCreateExecutor<LoadSingleTableStatement,
SingleRuleConfiguration> {
+public final class LoadSingleTableExecutor implements
DatabaseRuleCreateExecutor<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 809ae0f5b47..d0a6d72c369 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.DatabaseRuleRDLCreateExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.rule.database.DatabaseRuleCreateExecutor;
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
DatabaseRuleRDLCreateExecutor<SetDefaultSingleTableStorageUnitStatement,
SingleRuleConfiguration> {
+public final class SetDefaultSingleTableStorageUnitExecutor implements
DatabaseRuleCreateExecutor<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 1a61616ae76..28a053be019 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.DatabaseRuleRDLAlterExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.rule.database.DatabaseRuleAlterExecutor;
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
DatabaseRuleRDLAlterExecutor<UnloadSingleTableStatement,
SingleRuleConfiguration> {
+public final class UnloadSingleTableExecutor implements
DatabaseRuleAlterExecutor<UnloadSingleTableStatement, SingleRuleConfiguration> {
@Override
public void checkSQLStatement(final ShardingSphereDatabase database, final
UnloadSingleTableStatement sqlStatement, final SingleRuleConfiguration
currentRuleConfig) {
diff --git
a/kernel/single/distsql/handler/src/main/resources/META-INF/services/org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleRDLExecutor
b/kernel/single/distsql/handler/src/main/resources/META-INF/services/org.apache.shardingsphere.distsql.handler.type.rdl.rule.database.DatabaseRuleDefinitionExecutor
similarity index 100%
rename from
kernel/single/distsql/handler/src/main/resources/META-INF/services/org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleRDLExecutor
rename to
kernel/single/distsql/handler/src/main/resources/META-INF/services/org.apache.shardingsphere.distsql.handler.type.rdl.rule.database.DatabaseRuleDefinitionExecutor
diff --git
a/kernel/sql-federation/distsql/handler/src/main/java/org/apache/shardingsphere/sqlfederation/distsql/handler/update/AlterSQLFederationRuleExecutor.java
b/kernel/sql-federation/distsql/handler/src/main/java/org/apache/shardingsphere/sqlfederation/distsql/handler/update/AlterSQLFederationRuleExecutor.java
index e61885f362d..59c5f5e638b 100644
---
a/kernel/sql-federation/distsql/handler/src/main/java/org/apache/shardingsphere/sqlfederation/distsql/handler/update/AlterSQLFederationRuleExecutor.java
+++
b/kernel/sql-federation/distsql/handler/src/main/java/org/apache/shardingsphere/sqlfederation/distsql/handler/update/AlterSQLFederationRuleExecutor.java
@@ -17,7 +17,7 @@
package org.apache.shardingsphere.sqlfederation.distsql.handler.update;
-import
org.apache.shardingsphere.distsql.handler.type.rdl.global.GlobalRuleRDLExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.rule.global.GlobalRuleDefinitionExecutor;
import org.apache.shardingsphere.sql.parser.api.CacheOption;
import
org.apache.shardingsphere.sqlfederation.api.config.SQLFederationRuleConfiguration;
import
org.apache.shardingsphere.sqlfederation.distsql.segment.CacheOptionSegment;
@@ -26,7 +26,7 @@ import
org.apache.shardingsphere.sqlfederation.distsql.statement.updatable.Alter
/**
* Alter SQL federation rule executor.
*/
-public final class AlterSQLFederationRuleExecutor implements
GlobalRuleRDLExecutor<AlterSQLFederationRuleStatement,
SQLFederationRuleConfiguration> {
+public final class AlterSQLFederationRuleExecutor implements
GlobalRuleDefinitionExecutor<AlterSQLFederationRuleStatement,
SQLFederationRuleConfiguration> {
@Override
public void checkSQLStatement(final SQLFederationRuleConfiguration
currentRuleConfig, final AlterSQLFederationRuleStatement sqlStatement) {
diff --git
a/kernel/sql-federation/distsql/handler/src/main/resources/META-INF/services/org.apache.shardingsphere.distsql.handler.type.rdl.global.GlobalRuleRDLExecutor
b/kernel/sql-federation/distsql/handler/src/main/resources/META-INF/services/org.apache.shardingsphere.distsql.handler.type.rdl.rule.global.GlobalRuleDefinitionExecutor
similarity index 100%
rename from
kernel/sql-federation/distsql/handler/src/main/resources/META-INF/services/org.apache.shardingsphere.distsql.handler.type.rdl.global.GlobalRuleRDLExecutor
rename to
kernel/sql-federation/distsql/handler/src/main/resources/META-INF/services/org.apache.shardingsphere.distsql.handler.type.rdl.rule.global.GlobalRuleDefinitionExecutor
diff --git
a/kernel/sql-parser/distsql/handler/src/main/java/org/apache/shardingsphere/parser/distsql/handler/update/AlterSQLParserRuleExecutor.java
b/kernel/sql-parser/distsql/handler/src/main/java/org/apache/shardingsphere/parser/distsql/handler/update/AlterSQLParserRuleExecutor.java
index 9bb0e92a669..6d2c69784e6 100644
---
a/kernel/sql-parser/distsql/handler/src/main/java/org/apache/shardingsphere/parser/distsql/handler/update/AlterSQLParserRuleExecutor.java
+++
b/kernel/sql-parser/distsql/handler/src/main/java/org/apache/shardingsphere/parser/distsql/handler/update/AlterSQLParserRuleExecutor.java
@@ -17,7 +17,7 @@
package org.apache.shardingsphere.parser.distsql.handler.update;
-import
org.apache.shardingsphere.distsql.handler.type.rdl.global.GlobalRuleRDLExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.rule.global.GlobalRuleDefinitionExecutor;
import org.apache.shardingsphere.parser.config.SQLParserRuleConfiguration;
import org.apache.shardingsphere.parser.distsql.segment.CacheOptionSegment;
import
org.apache.shardingsphere.parser.distsql.statement.updatable.AlterSQLParserRuleStatement;
@@ -26,7 +26,7 @@ import org.apache.shardingsphere.sql.parser.api.CacheOption;
/**
* Alter SQL parser rule executor.
*/
-public final class AlterSQLParserRuleExecutor implements
GlobalRuleRDLExecutor<AlterSQLParserRuleStatement, SQLParserRuleConfiguration> {
+public final class AlterSQLParserRuleExecutor implements
GlobalRuleDefinitionExecutor<AlterSQLParserRuleStatement,
SQLParserRuleConfiguration> {
@Override
public void checkSQLStatement(final SQLParserRuleConfiguration
currentRuleConfig, final AlterSQLParserRuleStatement sqlStatement) {
diff --git
a/kernel/sql-parser/distsql/handler/src/main/resources/META-INF/services/org.apache.shardingsphere.distsql.handler.type.rdl.global.GlobalRuleRDLExecutor
b/kernel/sql-parser/distsql/handler/src/main/resources/META-INF/services/org.apache.shardingsphere.distsql.handler.type.rdl.rule.global.GlobalRuleDefinitionExecutor
similarity index 100%
rename from
kernel/sql-parser/distsql/handler/src/main/resources/META-INF/services/org.apache.shardingsphere.distsql.handler.type.rdl.global.GlobalRuleRDLExecutor
rename to
kernel/sql-parser/distsql/handler/src/main/resources/META-INF/services/org.apache.shardingsphere.distsql.handler.type.rdl.rule.global.GlobalRuleDefinitionExecutor
diff --git
a/kernel/sql-translator/distsql/handler/src/main/java/org/apache/shardingsphere/sqltranslator/distsql/handler/update/AlterSQLTranslatorRuleExecutor.java
b/kernel/sql-translator/distsql/handler/src/main/java/org/apache/shardingsphere/sqltranslator/distsql/handler/update/AlterSQLTranslatorRuleExecutor.java
index 6703b5bda48..ffe2c8ee1e1 100644
---
a/kernel/sql-translator/distsql/handler/src/main/java/org/apache/shardingsphere/sqltranslator/distsql/handler/update/AlterSQLTranslatorRuleExecutor.java
+++
b/kernel/sql-translator/distsql/handler/src/main/java/org/apache/shardingsphere/sqltranslator/distsql/handler/update/AlterSQLTranslatorRuleExecutor.java
@@ -17,7 +17,7 @@
package org.apache.shardingsphere.sqltranslator.distsql.handler.update;
-import
org.apache.shardingsphere.distsql.handler.type.rdl.global.GlobalRuleRDLExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.rule.global.GlobalRuleDefinitionExecutor;
import org.apache.shardingsphere.infra.spi.type.typed.TypedSPILoader;
import
org.apache.shardingsphere.sqltranslator.api.config.SQLTranslatorRuleConfiguration;
import
org.apache.shardingsphere.sqltranslator.distsql.statement.updateable.AlterSQLTranslatorRuleStatement;
@@ -26,7 +26,7 @@ import
org.apache.shardingsphere.sqltranslator.spi.SQLTranslator;
/**
* Alter SQL translator rule executor.
*/
-public final class AlterSQLTranslatorRuleExecutor implements
GlobalRuleRDLExecutor<AlterSQLTranslatorRuleStatement,
SQLTranslatorRuleConfiguration> {
+public final class AlterSQLTranslatorRuleExecutor implements
GlobalRuleDefinitionExecutor<AlterSQLTranslatorRuleStatement,
SQLTranslatorRuleConfiguration> {
@Override
public void checkSQLStatement(final SQLTranslatorRuleConfiguration
currentRuleConfig, final AlterSQLTranslatorRuleStatement sqlStatement) {
diff --git
a/kernel/sql-translator/distsql/handler/src/main/resources/META-INF/services/org.apache.shardingsphere.distsql.handler.type.rdl.global.GlobalRuleRDLExecutor
b/kernel/sql-translator/distsql/handler/src/main/resources/META-INF/services/org.apache.shardingsphere.distsql.handler.type.rdl.rule.global.GlobalRuleDefinitionExecutor
similarity index 100%
rename from
kernel/sql-translator/distsql/handler/src/main/resources/META-INF/services/org.apache.shardingsphere.distsql.handler.type.rdl.global.GlobalRuleRDLExecutor
rename to
kernel/sql-translator/distsql/handler/src/main/resources/META-INF/services/org.apache.shardingsphere.distsql.handler.type.rdl.rule.global.GlobalRuleDefinitionExecutor
diff --git
a/kernel/traffic/distsql/handler/src/main/java/org/apache/shardingsphere/traffic/distsql/handler/update/AlterTrafficRuleExecutor.java
b/kernel/traffic/distsql/handler/src/main/java/org/apache/shardingsphere/traffic/distsql/handler/update/AlterTrafficRuleExecutor.java
index 291dbbb9792..98d8fe23990 100644
---
a/kernel/traffic/distsql/handler/src/main/java/org/apache/shardingsphere/traffic/distsql/handler/update/AlterTrafficRuleExecutor.java
+++
b/kernel/traffic/distsql/handler/src/main/java/org/apache/shardingsphere/traffic/distsql/handler/update/AlterTrafficRuleExecutor.java
@@ -18,7 +18,7 @@
package org.apache.shardingsphere.traffic.distsql.handler.update;
import
org.apache.shardingsphere.distsql.handler.exception.rule.MissingRequiredRuleException;
-import
org.apache.shardingsphere.distsql.handler.type.rdl.global.GlobalRuleRDLExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.rule.global.GlobalRuleDefinitionExecutor;
import org.apache.shardingsphere.infra.config.algorithm.AlgorithmConfiguration;
import
org.apache.shardingsphere.infra.exception.core.ShardingSpherePreconditions;
import org.apache.shardingsphere.infra.spi.type.typed.TypedSPILoader;
@@ -39,7 +39,7 @@ import java.util.stream.Collectors;
/**
* Alter traffic rule executor.
*/
-public final class AlterTrafficRuleExecutor implements
GlobalRuleRDLExecutor<AlterTrafficRuleStatement, TrafficRuleConfiguration> {
+public final class AlterTrafficRuleExecutor implements
GlobalRuleDefinitionExecutor<AlterTrafficRuleStatement,
TrafficRuleConfiguration> {
@Override
public void checkSQLStatement(final TrafficRuleConfiguration
currentRuleConfig, final AlterTrafficRuleStatement sqlStatement) {
diff --git
a/kernel/traffic/distsql/handler/src/main/resources/META-INF/services/org.apache.shardingsphere.distsql.handler.type.rdl.global.GlobalRuleRDLExecutor
b/kernel/traffic/distsql/handler/src/main/resources/META-INF/services/org.apache.shardingsphere.distsql.handler.type.rdl.rule.global.GlobalRuleDefinitionExecutor
similarity index 100%
rename from
kernel/traffic/distsql/handler/src/main/resources/META-INF/services/org.apache.shardingsphere.distsql.handler.type.rdl.global.GlobalRuleRDLExecutor
rename to
kernel/traffic/distsql/handler/src/main/resources/META-INF/services/org.apache.shardingsphere.distsql.handler.type.rdl.rule.global.GlobalRuleDefinitionExecutor
diff --git
a/kernel/transaction/distsql/handler/src/main/java/org/apache/shardingsphere/transaction/distsql/handler/update/AlterTransactionRuleExecutor.java
b/kernel/transaction/distsql/handler/src/main/java/org/apache/shardingsphere/transaction/distsql/handler/update/AlterTransactionRuleExecutor.java
index 931e6c3a734..692209ce027 100644
---
a/kernel/transaction/distsql/handler/src/main/java/org/apache/shardingsphere/transaction/distsql/handler/update/AlterTransactionRuleExecutor.java
+++
b/kernel/transaction/distsql/handler/src/main/java/org/apache/shardingsphere/transaction/distsql/handler/update/AlterTransactionRuleExecutor.java
@@ -18,7 +18,7 @@
package org.apache.shardingsphere.transaction.distsql.handler.update;
import
org.apache.shardingsphere.distsql.handler.exception.rule.InvalidRuleConfigurationException;
-import
org.apache.shardingsphere.distsql.handler.type.rdl.global.GlobalRuleRDLExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.rule.global.GlobalRuleDefinitionExecutor;
import
org.apache.shardingsphere.infra.exception.core.ShardingSpherePreconditions;
import org.apache.shardingsphere.infra.spi.ShardingSphereServiceLoader;
import org.apache.shardingsphere.transaction.api.TransactionType;
@@ -32,7 +32,7 @@ import java.util.Optional;
/**
* Alter transaction rule executor.
*/
-public final class AlterTransactionRuleExecutor implements
GlobalRuleRDLExecutor<AlterTransactionRuleStatement,
TransactionRuleConfiguration> {
+public final class AlterTransactionRuleExecutor implements
GlobalRuleDefinitionExecutor<AlterTransactionRuleStatement,
TransactionRuleConfiguration> {
@Override
public void checkSQLStatement(final TransactionRuleConfiguration
currentRuleConfig, final AlterTransactionRuleStatement sqlStatement) {
diff --git
a/kernel/transaction/distsql/handler/src/main/resources/META-INF/services/org.apache.shardingsphere.distsql.handler.type.rdl.global.GlobalRuleRDLExecutor
b/kernel/transaction/distsql/handler/src/main/resources/META-INF/services/org.apache.shardingsphere.distsql.handler.type.rdl.rule.global.GlobalRuleDefinitionExecutor
similarity index 100%
rename from
kernel/transaction/distsql/handler/src/main/resources/META-INF/services/org.apache.shardingsphere.distsql.handler.type.rdl.global.GlobalRuleRDLExecutor
rename to
kernel/transaction/distsql/handler/src/main/resources/META-INF/services/org.apache.shardingsphere.distsql.handler.type.rdl.rule.global.GlobalRuleDefinitionExecutor
diff --git
a/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/ral/common/enums/VariableEnum.java
b/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/ral/common/DistSQLVariable.java
similarity index 91%
rename from
proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/ral/common/enums/VariableEnum.java
rename to
proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/ral/common/DistSQLVariable.java
index 6ca4fb3570b..036091fb654 100644
---
a/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/ral/common/enums/VariableEnum.java
+++
b/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/ral/common/DistSQLVariable.java
@@ -15,14 +15,14 @@
* limitations under the License.
*/
-package
org.apache.shardingsphere.proxy.backend.handler.distsql.ral.common.enums;
+package org.apache.shardingsphere.proxy.backend.handler.distsql.ral.common;
import
org.apache.shardingsphere.proxy.backend.exception.UnsupportedVariableException;
/**
- * Variable enum.
+ * DistSQL variable.
*/
-public enum VariableEnum {
+public enum DistSQLVariable {
CACHED_CONNECTIONS;
@@ -33,7 +33,7 @@ public enum VariableEnum {
* @return variable constant
* @throws UnsupportedVariableException unsupported variable exception
*/
- public static VariableEnum getValueOf(final String variableName) {
+ public static DistSQLVariable getValueOf(final String variableName) {
try {
return valueOf(variableName.toUpperCase());
} catch (final IllegalArgumentException ignored) {
diff --git
a/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/ral/queryable/ShowDistVariableExecutor.java
b/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/ral/queryable/ShowDistVariableExecutor.java
index 557c096c5ea..6dabc3cee9b 100644
---
a/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/ral/queryable/ShowDistVariableExecutor.java
+++
b/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/ral/queryable/ShowDistVariableExecutor.java
@@ -29,7 +29,7 @@ import
org.apache.shardingsphere.logging.constant.LoggingConstants;
import org.apache.shardingsphere.logging.logger.ShardingSphereLogger;
import org.apache.shardingsphere.logging.util.LoggingUtils;
import
org.apache.shardingsphere.proxy.backend.exception.UnsupportedVariableException;
-import
org.apache.shardingsphere.proxy.backend.handler.distsql.ral.common.enums.VariableEnum;
+import
org.apache.shardingsphere.proxy.backend.handler.distsql.ral.common.DistSQLVariable;
import
org.apache.shardingsphere.distsql.handler.type.ral.query.ConnectionSizeAwareQueryableRALExecutor;
import java.util.Arrays;
@@ -102,7 +102,7 @@ public final class ShowDistVariableExecutor implements
ConnectionSizeAwareQuerya
}
private String getConnectionSize(final String variableName) {
- ShardingSpherePreconditions.checkState(VariableEnum.CACHED_CONNECTIONS
== VariableEnum.getValueOf(variableName), () -> new
UnsupportedVariableException(variableName));
+
ShardingSpherePreconditions.checkState(DistSQLVariable.CACHED_CONNECTIONS ==
DistSQLVariable.getValueOf(variableName), () -> new
UnsupportedVariableException(variableName));
return String.valueOf(connectionSize);
}
diff --git
a/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/ral/queryable/ShowDistVariablesExecutor.java
b/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/ral/queryable/ShowDistVariablesExecutor.java
index 21418a36cba..c9bb6fba141 100644
---
a/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/ral/queryable/ShowDistVariablesExecutor.java
+++
b/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/ral/queryable/ShowDistVariablesExecutor.java
@@ -27,7 +27,7 @@ import
org.apache.shardingsphere.infra.spi.type.typed.TypedSPI;
import org.apache.shardingsphere.logging.constant.LoggingConstants;
import org.apache.shardingsphere.logging.logger.ShardingSphereLogger;
import org.apache.shardingsphere.logging.util.LoggingUtils;
-import
org.apache.shardingsphere.proxy.backend.handler.distsql.ral.common.enums.VariableEnum;
+import
org.apache.shardingsphere.proxy.backend.handler.distsql.ral.common.DistSQLVariable;
import
org.apache.shardingsphere.distsql.handler.type.ral.query.ConnectionSizeAwareQueryableRALExecutor;
import org.apache.shardingsphere.sql.parser.sql.common.util.SQLUtils;
@@ -60,7 +60,7 @@ public final class ShowDistVariablesExecutor implements
ConnectionSizeAwareQuery
result.addAll(TemporaryConfigurationPropertyKey.getKeyNames().stream()
.map(each -> new LocalDataQueryResultRow(each.toLowerCase(),
getStringResult(metaData.getTemporaryProps().getValue(TemporaryConfigurationPropertyKey.valueOf(each)))))
.collect(Collectors.toList()));
- result.add(new
LocalDataQueryResultRow(VariableEnum.CACHED_CONNECTIONS.name().toLowerCase(),
connectionSize));
+ result.add(new
LocalDataQueryResultRow(DistSQLVariable.CACHED_CONNECTIONS.name().toLowerCase(),
connectionSize));
addLoggingPropsRows(metaData, result);
if (sqlStatement.getLikePattern().isPresent()) {
String pattern =
SQLUtils.convertLikePatternToRegex(sqlStatement.getLikePattern().get());
diff --git
a/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/rdl/RDLBackendHandlerFactory.java
b/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/rdl/RDLBackendHandlerFactory.java
index 29f8c29298a..24d82e78124 100644
---
a/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/rdl/RDLBackendHandlerFactory.java
+++
b/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/rdl/RDLBackendHandlerFactory.java
@@ -19,8 +19,8 @@ package
org.apache.shardingsphere.proxy.backend.handler.distsql.rdl;
import lombok.AccessLevel;
import lombok.NoArgsConstructor;
-import org.apache.shardingsphere.distsql.handler.type.rdl.RDLExecutor;
-import
org.apache.shardingsphere.distsql.handler.type.rdl.aware.DatabaseAwareRDLExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.resource.ResourceDefinitionExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.resource.aware.DatabaseAwareResourceDefinitionExecutor;
import org.apache.shardingsphere.distsql.statement.rdl.RDLStatement;
import org.apache.shardingsphere.distsql.statement.rdl.RuleDefinitionStatement;
import
org.apache.shardingsphere.distsql.statement.rdl.StorageUnitDefinitionStatement;
@@ -56,9 +56,9 @@ public final class RDLBackendHandlerFactory {
@SuppressWarnings("rawtypes")
private static ResourceDefinitionBackendHandler
getStorageUnitBackendHandler(final StorageUnitDefinitionStatement sqlStatement,
final ConnectionSession connectionSession) {
- RDLExecutor executor = TypedSPILoader.getService(RDLExecutor.class,
sqlStatement.getClass());
- if (executor instanceof DatabaseAwareRDLExecutor) {
- ((DatabaseAwareRDLExecutor<?>)
executor).setDatabase(ProxyContext.getInstance().getDatabase(DatabaseNameUtils.getDatabaseName(sqlStatement,
connectionSession)));
+ ResourceDefinitionExecutor executor =
TypedSPILoader.getService(ResourceDefinitionExecutor.class,
sqlStatement.getClass());
+ if (executor instanceof DatabaseAwareResourceDefinitionExecutor) {
+ ((DatabaseAwareResourceDefinitionExecutor<?>)
executor).setDatabase(ProxyContext.getInstance().getDatabase(DatabaseNameUtils.getDatabaseName(sqlStatement,
connectionSession)));
}
return new ResourceDefinitionBackendHandler(sqlStatement, executor);
}
diff --git
a/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/rdl/resource/ResourceDefinitionBackendHandler.java
b/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/rdl/resource/ResourceDefinitionBackendHandler.java
index 016aa0ee03c..236c788a181 100644
---
a/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/rdl/resource/ResourceDefinitionBackendHandler.java
+++
b/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/rdl/resource/ResourceDefinitionBackendHandler.java
@@ -18,8 +18,8 @@
package org.apache.shardingsphere.proxy.backend.handler.distsql.rdl.resource;
import lombok.RequiredArgsConstructor;
-import org.apache.shardingsphere.distsql.handler.type.rdl.RDLExecutor;
-import org.apache.shardingsphere.distsql.statement.rdl.RDLStatement;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.resource.ResourceDefinitionExecutor;
+import
org.apache.shardingsphere.distsql.statement.rdl.StorageUnitDefinitionStatement;
import
org.apache.shardingsphere.proxy.backend.handler.distsql.DistSQLBackendHandler;
import org.apache.shardingsphere.proxy.backend.response.header.ResponseHeader;
import
org.apache.shardingsphere.proxy.backend.response.header.update.UpdateResponseHeader;
@@ -29,14 +29,13 @@ import java.sql.SQLException;
/**
* Resource definition backend handler.
*/
-// TODO merge to RDLBackendHandler @zhangliang
@RequiredArgsConstructor
public final class ResourceDefinitionBackendHandler implements
DistSQLBackendHandler {
- private final RDLStatement sqlStatement;
+ private final StorageUnitDefinitionStatement sqlStatement;
@SuppressWarnings("rawtypes")
- private final RDLExecutor executor;
+ private final ResourceDefinitionExecutor executor;
@SuppressWarnings("unchecked")
@Override
diff --git
a/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/rdl/resource/type/AlterStorageUnitExecutor.java
b/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/rdl/resource/type/AlterStorageUnitExecutor.java
index 016e26138aa..23523d096a3 100644
---
a/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/rdl/resource/type/AlterStorageUnitExecutor.java
+++
b/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/rdl/resource/type/AlterStorageUnitExecutor.java
@@ -22,7 +22,7 @@ import lombok.extern.slf4j.Slf4j;
import
org.apache.shardingsphere.distsql.handler.exception.storageunit.DuplicateStorageUnitException;
import
org.apache.shardingsphere.distsql.handler.exception.storageunit.InvalidStorageUnitsException;
import
org.apache.shardingsphere.distsql.handler.exception.storageunit.MissingRequiredStorageUnitsException;
-import
org.apache.shardingsphere.distsql.handler.type.rdl.aware.DatabaseAwareRDLExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.resource.aware.DatabaseAwareResourceDefinitionExecutor;
import
org.apache.shardingsphere.distsql.handler.validate.DataSourcePoolPropertiesValidateHandler;
import org.apache.shardingsphere.distsql.segment.DataSourceSegment;
import
org.apache.shardingsphere.distsql.segment.HostnameAndPortBasedDataSourceSegment;
@@ -48,11 +48,11 @@ import java.util.Objects;
import java.util.stream.Collectors;
/**
- * Alter storage unit backend handler.
+ * Alter storage unit executor.
*/
@Slf4j
@Setter
-public final class AlterStorageUnitExecutor implements
DatabaseAwareRDLExecutor<AlterStorageUnitStatement> {
+public final class AlterStorageUnitExecutor implements
DatabaseAwareResourceDefinitionExecutor<AlterStorageUnitStatement> {
private final DataSourcePoolPropertiesValidateHandler validateHandler =
new DataSourcePoolPropertiesValidateHandler();
diff --git
a/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/rdl/resource/type/RegisterStorageUnitExecutor.java
b/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/rdl/resource/type/RegisterStorageUnitExecutor.java
index 0047b28b291..1de047cb88b 100644
---
a/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/rdl/resource/type/RegisterStorageUnitExecutor.java
+++
b/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/rdl/resource/type/RegisterStorageUnitExecutor.java
@@ -21,7 +21,7 @@ import lombok.Setter;
import lombok.extern.slf4j.Slf4j;
import
org.apache.shardingsphere.distsql.handler.exception.storageunit.DuplicateStorageUnitException;
import
org.apache.shardingsphere.distsql.handler.exception.storageunit.InvalidStorageUnitsException;
-import
org.apache.shardingsphere.distsql.handler.type.rdl.aware.DatabaseAwareRDLExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.resource.aware.DatabaseAwareResourceDefinitionExecutor;
import
org.apache.shardingsphere.distsql.handler.validate.DataSourcePoolPropertiesValidateHandler;
import org.apache.shardingsphere.distsql.segment.DataSourceSegment;
import
org.apache.shardingsphere.distsql.segment.converter.DataSourceSegmentsConverter;
@@ -46,7 +46,7 @@ import java.util.stream.Collectors;
*/
@Setter
@Slf4j
-public final class RegisterStorageUnitExecutor implements
DatabaseAwareRDLExecutor<RegisterStorageUnitStatement> {
+public final class RegisterStorageUnitExecutor implements
DatabaseAwareResourceDefinitionExecutor<RegisterStorageUnitStatement> {
private final DataSourcePoolPropertiesValidateHandler validateHandler =
new DataSourcePoolPropertiesValidateHandler();
diff --git
a/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/rdl/resource/type/UnregisterStorageUnitExecutor.java
b/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/rdl/resource/type/UnregisterStorageUnitExecutor.java
index 9e07ae46e0a..78a321b7d66 100644
---
a/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/rdl/resource/type/UnregisterStorageUnitExecutor.java
+++
b/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/rdl/resource/type/UnregisterStorageUnitExecutor.java
@@ -23,7 +23,7 @@ import org.apache.shardingsphere.broadcast.rule.BroadcastRule;
import
org.apache.shardingsphere.distsql.handler.exception.storageunit.InvalidStorageUnitsException;
import
org.apache.shardingsphere.distsql.handler.exception.storageunit.MissingRequiredStorageUnitsException;
import
org.apache.shardingsphere.distsql.handler.exception.storageunit.StorageUnitInUsedException;
-import
org.apache.shardingsphere.distsql.handler.type.rdl.aware.DatabaseAwareRDLExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.resource.aware.DatabaseAwareResourceDefinitionExecutor;
import
org.apache.shardingsphere.distsql.statement.rdl.drop.UnregisterStorageUnitStatement;
import
org.apache.shardingsphere.infra.exception.core.ShardingSpherePreconditions;
import
org.apache.shardingsphere.infra.exception.core.external.server.ShardingSphereServerException;
@@ -46,7 +46,7 @@ import java.util.stream.Collectors;
*/
@Setter
@Slf4j
-public final class UnregisterStorageUnitExecutor implements
DatabaseAwareRDLExecutor<UnregisterStorageUnitStatement> {
+public final class UnregisterStorageUnitExecutor implements
DatabaseAwareResourceDefinitionExecutor<UnregisterStorageUnitStatement> {
private ShardingSphereDatabase database;
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 7d03065010b..462efc00f67 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
@@ -18,8 +18,8 @@
package org.apache.shardingsphere.proxy.backend.handler.distsql.rdl.rule;
import lombok.RequiredArgsConstructor;
-import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleRDLExecutor;
-import
org.apache.shardingsphere.distsql.handler.type.rdl.global.GlobalRuleRDLExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.rule.database.DatabaseRuleDefinitionExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.rule.global.GlobalRuleDefinitionExecutor;
import org.apache.shardingsphere.distsql.statement.rdl.RuleDefinitionStatement;
import org.apache.shardingsphere.infra.spi.type.typed.TypedSPILoader;
import org.apache.shardingsphere.proxy.backend.context.ProxyContext;
@@ -46,12 +46,12 @@ public final class RuleDefinitionBackendHandler implements
DistSQLBackendHandler
@SuppressWarnings("rawtypes")
@Override
public ResponseHeader execute() {
- Optional<DatabaseRuleRDLExecutor> databaseExecutor =
TypedSPILoader.findService(DatabaseRuleRDLExecutor.class,
sqlStatement.getClass());
+ Optional<DatabaseRuleDefinitionExecutor> databaseExecutor =
TypedSPILoader.findService(DatabaseRuleDefinitionExecutor.class,
sqlStatement.getClass());
if (databaseExecutor.isPresent()) {
new DatabaseRuleUpdater(sqlStatement, connectionSession,
databaseExecutor.get()).executeUpdate();
} else {
String modeType =
ProxyContext.getInstance().getContextManager().getInstanceContext().getModeConfiguration().getType();
- GlobalRuleRDLExecutor globalExecutor =
TypedSPILoader.getService(GlobalRuleRDLExecutor.class, sqlStatement.getClass());
+ GlobalRuleDefinitionExecutor globalExecutor =
TypedSPILoader.getService(GlobalRuleDefinitionExecutor.class,
sqlStatement.getClass());
if ("Cluster".equals(modeType) || "Standalone".equals(modeType)) {
new GlobalRuleUpdater(sqlStatement,
globalExecutor).executeUpdate();
} else {
diff --git
a/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/rdl/rule/database/DatabaseRuleUpdater.java
b/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/rdl/rule/database/DatabaseRuleUpdater.java
index e3d948ca9ce..1594ef844f4 100644
---
a/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/rdl/rule/database/DatabaseRuleUpdater.java
+++
b/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/rdl/rule/database/DatabaseRuleUpdater.java
@@ -18,8 +18,8 @@
package
org.apache.shardingsphere.proxy.backend.handler.distsql.rdl.rule.database;
import lombok.RequiredArgsConstructor;
-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.handler.type.rdl.rule.database.DatabaseRuleDropExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.rule.database.DatabaseRuleDefinitionExecutor;
import org.apache.shardingsphere.distsql.statement.rdl.RuleDefinitionStatement;
import org.apache.shardingsphere.infra.config.rule.RuleConfiguration;
import
org.apache.shardingsphere.infra.metadata.database.ShardingSphereDatabase;
@@ -41,7 +41,7 @@ public final class DatabaseRuleUpdater {
private final ConnectionSession connectionSession;
@SuppressWarnings("rawtypes")
- private final DatabaseRuleRDLExecutor executor;
+ private final DatabaseRuleDefinitionExecutor executor;
/**
* Execute update.
@@ -64,6 +64,6 @@ public final class DatabaseRuleUpdater {
@SuppressWarnings({"rawtypes", "unchecked"})
private boolean getRefreshStatus(final RuleConfiguration
currentRuleConfig) {
- return !(executor instanceof DatabaseRuleRDLDropExecutor) ||
((DatabaseRuleRDLDropExecutor) executor).hasAnyOneToBeDropped(sqlStatement,
currentRuleConfig);
+ return !(executor instanceof DatabaseRuleDropExecutor) ||
((DatabaseRuleDropExecutor) executor).hasAnyOneToBeDropped(sqlStatement,
currentRuleConfig);
}
}
diff --git
a/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/rdl/rule/database/execute/DatabaseRuleRDLExecuteEngineFactory.java
b/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/rdl/rule/database/execute/DatabaseRuleRDLExecuteEngineFactory.java
index 9d655057a21..402953435c0 100644
---
a/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/rdl/rule/database/execute/DatabaseRuleRDLExecuteEngineFactory.java
+++
b/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/rdl/rule/database/execute/DatabaseRuleRDLExecuteEngineFactory.java
@@ -19,10 +19,10 @@ package
org.apache.shardingsphere.proxy.backend.handler.distsql.rdl.rule.databas
import lombok.AccessLevel;
import lombok.NoArgsConstructor;
-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.handler.type.rdl.rule.database.DatabaseRuleAlterExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.rule.database.DatabaseRuleCreateExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.rule.database.DatabaseRuleDropExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.rule.database.DatabaseRuleDefinitionExecutor;
import
org.apache.shardingsphere.infra.exception.core.external.sql.type.generic.UnsupportedSQLOperationException;
import
org.apache.shardingsphere.proxy.backend.handler.distsql.rdl.rule.database.execute.type.AlterDatabaseRuleRDLExecuteEngine;
import
org.apache.shardingsphere.proxy.backend.handler.distsql.rdl.rule.database.execute.type.CreateDatabaseRuleRDLExecuteEngine;
@@ -41,15 +41,15 @@ public final class DatabaseRuleRDLExecuteEngineFactory {
* @throws UnsupportedSQLOperationException if invalid database rule RDL
executor
*/
@SuppressWarnings("rawtypes")
- public static DatabaseRuleRDLExecuteEngine newInstance(final
DatabaseRuleRDLExecutor executor) {
- if (executor instanceof DatabaseRuleRDLCreateExecutor) {
- return new
CreateDatabaseRuleRDLExecuteEngine((DatabaseRuleRDLCreateExecutor) executor);
+ public static DatabaseRuleRDLExecuteEngine newInstance(final
DatabaseRuleDefinitionExecutor executor) {
+ if (executor instanceof DatabaseRuleCreateExecutor) {
+ return new
CreateDatabaseRuleRDLExecuteEngine((DatabaseRuleCreateExecutor) executor);
}
- if (executor instanceof DatabaseRuleRDLAlterExecutor) {
- return new
AlterDatabaseRuleRDLExecuteEngine((DatabaseRuleRDLAlterExecutor) executor);
+ if (executor instanceof DatabaseRuleAlterExecutor) {
+ return new
AlterDatabaseRuleRDLExecuteEngine((DatabaseRuleAlterExecutor) executor);
}
- if (executor instanceof DatabaseRuleRDLDropExecutor) {
- return new
DropDatabaseRuleRDLExecuteEngine((DatabaseRuleRDLDropExecutor) executor);
+ if (executor instanceof DatabaseRuleDropExecutor) {
+ return new
DropDatabaseRuleRDLExecuteEngine((DatabaseRuleDropExecutor) executor);
}
throw new UnsupportedSQLOperationException(String.format("Cannot
support RDL executor type `%s`", executor.getClass().getName()));
}
diff --git
a/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/rdl/rule/database/execute/type/AlterDatabaseRuleRDLExecuteEngine.java
b/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/rdl/rule/database/execute/type/AlterDatabaseRuleRDLExecuteEngine.java
index ef111b8ecd0..44bb4fa3523 100644
---
a/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/rdl/rule/database/execute/type/AlterDatabaseRuleRDLExecuteEngine.java
+++
b/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/rdl/rule/database/execute/type/AlterDatabaseRuleRDLExecuteEngine.java
@@ -18,7 +18,7 @@
package
org.apache.shardingsphere.proxy.backend.handler.distsql.rdl.rule.database.execute.type;
import lombok.RequiredArgsConstructor;
-import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleRDLAlterExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.rule.database.DatabaseRuleAlterExecutor;
import org.apache.shardingsphere.distsql.statement.rdl.RuleDefinitionStatement;
import org.apache.shardingsphere.infra.config.rule.RuleConfiguration;
import
org.apache.shardingsphere.infra.config.rule.decorator.RuleConfigurationDecorator;
@@ -42,7 +42,7 @@ import java.util.stream.Collectors;
public final class AlterDatabaseRuleRDLExecuteEngine implements
DatabaseRuleRDLExecuteEngine {
@SuppressWarnings("rawtypes")
- private final DatabaseRuleRDLAlterExecutor executor;
+ private final DatabaseRuleAlterExecutor executor;
@Override
@SuppressWarnings("unchecked")
diff --git
a/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/rdl/rule/database/execute/type/CreateDatabaseRuleRDLExecuteEngine.java
b/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/rdl/rule/database/execute/type/CreateDatabaseRuleRDLExecuteEngine.java
index ada833f2da5..96ed8a60c78 100644
---
a/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/rdl/rule/database/execute/type/CreateDatabaseRuleRDLExecuteEngine.java
+++
b/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/rdl/rule/database/execute/type/CreateDatabaseRuleRDLExecuteEngine.java
@@ -18,7 +18,7 @@
package
org.apache.shardingsphere.proxy.backend.handler.distsql.rdl.rule.database.execute.type;
import lombok.RequiredArgsConstructor;
-import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleRDLCreateExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.rule.database.DatabaseRuleCreateExecutor;
import org.apache.shardingsphere.distsql.statement.rdl.RuleDefinitionStatement;
import org.apache.shardingsphere.infra.config.rule.RuleConfiguration;
import
org.apache.shardingsphere.infra.config.rule.decorator.RuleConfigurationDecorator;
@@ -41,7 +41,7 @@ import java.util.stream.Collectors;
public final class CreateDatabaseRuleRDLExecuteEngine implements
DatabaseRuleRDLExecuteEngine {
@SuppressWarnings("rawtypes")
- private final DatabaseRuleRDLCreateExecutor executor;
+ private final DatabaseRuleCreateExecutor executor;
@Override
@SuppressWarnings("unchecked")
diff --git
a/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/rdl/rule/database/execute/type/DropDatabaseRuleRDLExecuteEngine.java
b/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/rdl/rule/database/execute/type/DropDatabaseRuleRDLExecuteEngine.java
index ea33409d259..4063aa96abd 100644
---
a/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/rdl/rule/database/execute/type/DropDatabaseRuleRDLExecuteEngine.java
+++
b/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/rdl/rule/database/execute/type/DropDatabaseRuleRDLExecuteEngine.java
@@ -18,7 +18,7 @@
package
org.apache.shardingsphere.proxy.backend.handler.distsql.rdl.rule.database.execute.type;
import lombok.RequiredArgsConstructor;
-import
org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleRDLDropExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.rule.database.DatabaseRuleDropExecutor;
import org.apache.shardingsphere.distsql.statement.rdl.RuleDefinitionStatement;
import org.apache.shardingsphere.infra.config.rule.RuleConfiguration;
import
org.apache.shardingsphere.infra.config.rule.scope.DatabaseRuleConfiguration;
@@ -42,7 +42,7 @@ import java.util.Collections;
public final class DropDatabaseRuleRDLExecuteEngine implements
DatabaseRuleRDLExecuteEngine {
@SuppressWarnings("rawtypes")
- private final DatabaseRuleRDLDropExecutor executor;
+ private final DatabaseRuleDropExecutor executor;
@Override
@SuppressWarnings("unchecked")
diff --git
a/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/rdl/rule/global/GlobalRuleUpdater.java
b/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/rdl/rule/global/GlobalRuleUpdater.java
index cec8a682522..993220a71cf 100644
---
a/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/rdl/rule/global/GlobalRuleUpdater.java
+++
b/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/rdl/rule/global/GlobalRuleUpdater.java
@@ -19,7 +19,7 @@ package
org.apache.shardingsphere.proxy.backend.handler.distsql.rdl.rule.global;
import lombok.RequiredArgsConstructor;
import
org.apache.shardingsphere.distsql.handler.exception.rule.MissingRequiredRuleException;
-import
org.apache.shardingsphere.distsql.handler.type.rdl.global.GlobalRuleRDLExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.rule.global.GlobalRuleDefinitionExecutor;
import org.apache.shardingsphere.distsql.statement.rdl.RuleDefinitionStatement;
import org.apache.shardingsphere.infra.config.rule.RuleConfiguration;
import org.apache.shardingsphere.mode.manager.ContextManager;
@@ -36,7 +36,7 @@ public final class GlobalRuleUpdater {
private final RuleDefinitionStatement sqlStatement;
@SuppressWarnings("rawtypes")
- private final GlobalRuleRDLExecutor executor;
+ private final GlobalRuleDefinitionExecutor executor;
/**
* Execute update.
diff --git
a/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/rdl/rule/legacy/LegacyGlobalRuleUpdater.java
b/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/rdl/rule/legacy/LegacyGlobalRuleUpdater.java
index 0087cdc76bc..0e88b5954e4 100644
---
a/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/rdl/rule/legacy/LegacyGlobalRuleUpdater.java
+++
b/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/rdl/rule/legacy/LegacyGlobalRuleUpdater.java
@@ -19,7 +19,7 @@ package
org.apache.shardingsphere.proxy.backend.handler.distsql.rdl.rule.legacy;
import lombok.RequiredArgsConstructor;
import
org.apache.shardingsphere.distsql.handler.exception.rule.MissingRequiredRuleException;
-import
org.apache.shardingsphere.distsql.handler.type.rdl.global.GlobalRuleRDLExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.rule.global.GlobalRuleDefinitionExecutor;
import org.apache.shardingsphere.distsql.statement.rdl.RuleDefinitionStatement;
import org.apache.shardingsphere.infra.config.rule.RuleConfiguration;
import org.apache.shardingsphere.infra.spi.type.typed.TypedSPILoader;
@@ -43,7 +43,7 @@ public final class LegacyGlobalRuleUpdater {
*/
@SuppressWarnings({"rawtypes", "unchecked"})
public void executeUpdate() {
- GlobalRuleRDLExecutor executor =
TypedSPILoader.getService(GlobalRuleRDLExecutor.class, sqlStatement.getClass());
+ GlobalRuleDefinitionExecutor executor =
TypedSPILoader.getService(GlobalRuleDefinitionExecutor.class,
sqlStatement.getClass());
Class<? extends RuleConfiguration> ruleConfigClass =
executor.getRuleConfigurationClass();
ContextManager contextManager =
ProxyContext.getInstance().getContextManager();
Collection<RuleConfiguration> ruleConfigs =
contextManager.getMetaDataContexts().getMetaData().getGlobalRuleMetaData().getConfigurations();
@@ -63,7 +63,7 @@ public final class LegacyGlobalRuleUpdater {
@SuppressWarnings({"rawtypes", "unchecked"})
private Collection<RuleConfiguration> processUpdate(final
Collection<RuleConfiguration> ruleConfigurations,
- final
RuleDefinitionStatement sqlStatement, final GlobalRuleRDLExecutor
globalRuleUpdater, final RuleConfiguration currentRuleConfig) {
+ final
RuleDefinitionStatement sqlStatement, final GlobalRuleDefinitionExecutor
globalRuleUpdater, final RuleConfiguration currentRuleConfig) {
Collection<RuleConfiguration> result = new
LinkedList<>(ruleConfigurations);
result.remove(currentRuleConfig);
result.add(globalRuleUpdater.buildAlteredRuleConfiguration(currentRuleConfig,
sqlStatement));
diff --git
a/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/rdl/rule/legacy/LegacyRuleDefinitionBackendHandler.java
b/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/rdl/rule/legacy/LegacyRuleDefinitionBackendHandler.java
index 12bad91ae34..4e5c2e9612e 100644
---
a/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/rdl/rule/legacy/LegacyRuleDefinitionBackendHandler.java
+++
b/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/rdl/rule/legacy/LegacyRuleDefinitionBackendHandler.java
@@ -18,10 +18,10 @@
package
org.apache.shardingsphere.proxy.backend.handler.distsql.rdl.rule.legacy;
import lombok.RequiredArgsConstructor;
-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.handler.type.rdl.rule.database.DatabaseRuleAlterExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.rule.database.DatabaseRuleCreateExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.rule.database.DatabaseRuleDropExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.rule.database.DatabaseRuleDefinitionExecutor;
import org.apache.shardingsphere.distsql.statement.rdl.RuleDefinitionStatement;
import org.apache.shardingsphere.infra.config.rule.RuleConfiguration;
import
org.apache.shardingsphere.infra.config.rule.decorator.RuleConfigurationDecorator;
@@ -61,7 +61,7 @@ public final class LegacyRuleDefinitionBackendHandler
implements DistSQLBackendH
@Override
public ResponseHeader execute() {
ShardingSphereDatabase database =
ProxyContext.getInstance().getDatabase(DatabaseNameUtils.getDatabaseName(sqlStatement,
connectionSession));
- DatabaseRuleRDLExecutor executor =
TypedSPILoader.getService(DatabaseRuleRDLExecutor.class,
sqlStatement.getClass());
+ DatabaseRuleDefinitionExecutor executor =
TypedSPILoader.getService(DatabaseRuleDefinitionExecutor.class,
sqlStatement.getClass());
Class<? extends RuleConfiguration> ruleConfigClass =
executor.getRuleConfigurationClass();
RuleConfiguration currentRuleConfig =
findCurrentRuleConfiguration(database, ruleConfigClass).orElse(null);
executor.checkSQLStatement(database, sqlStatement, currentRuleConfig);
@@ -77,26 +77,26 @@ public final class LegacyRuleDefinitionBackendHandler
implements DistSQLBackendH
}
@SuppressWarnings({"unchecked", "rawtypes"})
- private boolean getRefreshStatus(final SQLStatement sqlStatement, final
RuleConfiguration currentRuleConfig, final DatabaseRuleRDLExecutor<?, ?>
executor) {
- return !(executor instanceof DatabaseRuleRDLDropExecutor) ||
((DatabaseRuleRDLDropExecutor) executor).hasAnyOneToBeDropped(sqlStatement,
currentRuleConfig);
+ private boolean getRefreshStatus(final SQLStatement sqlStatement, final
RuleConfiguration currentRuleConfig, final DatabaseRuleDefinitionExecutor<?, ?>
executor) {
+ return !(executor instanceof DatabaseRuleDropExecutor) ||
((DatabaseRuleDropExecutor) executor).hasAnyOneToBeDropped(sqlStatement,
currentRuleConfig);
}
@SuppressWarnings("rawtypes")
private Collection<RuleConfiguration> processSQLStatement(final
ShardingSphereDatabase database,
- final
RuleDefinitionStatement sqlStatement, final DatabaseRuleRDLExecutor executor,
final RuleConfiguration currentRuleConfig) {
+ final
RuleDefinitionStatement sqlStatement, final DatabaseRuleDefinitionExecutor
executor, final RuleConfiguration currentRuleConfig) {
Collection<RuleConfiguration> result = new
LinkedList<>(database.getRuleMetaData().getConfigurations());
- if (executor instanceof DatabaseRuleRDLCreateExecutor) {
+ if (executor instanceof DatabaseRuleCreateExecutor) {
if (null != currentRuleConfig) {
result.remove(currentRuleConfig);
}
- RuleConfiguration createdRuleConfig = processCreate(sqlStatement,
(DatabaseRuleRDLCreateExecutor) executor, currentRuleConfig);
+ RuleConfiguration createdRuleConfig = processCreate(sqlStatement,
(DatabaseRuleCreateExecutor) executor, currentRuleConfig);
result.add(decorateRuleConfiguration(database, createdRuleConfig));
- } else if (executor instanceof DatabaseRuleRDLAlterExecutor) {
+ } else if (executor instanceof DatabaseRuleAlterExecutor) {
result.remove(currentRuleConfig);
- RuleConfiguration alteredRuleConfig = processAlter(sqlStatement,
(DatabaseRuleRDLAlterExecutor) executor, currentRuleConfig);
+ RuleConfiguration alteredRuleConfig = processAlter(sqlStatement,
(DatabaseRuleAlterExecutor) executor, currentRuleConfig);
result.add(decorateRuleConfiguration(database, alteredRuleConfig));
- } else if (executor instanceof DatabaseRuleRDLDropExecutor) {
- processDrop(database, result, sqlStatement,
(DatabaseRuleRDLDropExecutor) executor, currentRuleConfig);
+ } else if (executor instanceof DatabaseRuleDropExecutor) {
+ processDrop(database, result, sqlStatement,
(DatabaseRuleDropExecutor) executor, currentRuleConfig);
} else {
throw new UnsupportedSQLOperationException(String.format("Cannot
support RDL executor type `%s`", executor.getClass().getName()));
}
@@ -104,7 +104,7 @@ public final class LegacyRuleDefinitionBackendHandler
implements DistSQLBackendH
}
@SuppressWarnings({"rawtypes", "unchecked"})
- private RuleConfiguration processCreate(final RuleDefinitionStatement
sqlStatement, final DatabaseRuleRDLCreateExecutor executor, final
RuleConfiguration currentRuleConfig) {
+ private RuleConfiguration processCreate(final RuleDefinitionStatement
sqlStatement, final DatabaseRuleCreateExecutor executor, final
RuleConfiguration currentRuleConfig) {
RuleConfiguration toBeCreatedRuleConfig =
executor.buildToBeCreatedRuleConfiguration(currentRuleConfig, sqlStatement);
if (null == currentRuleConfig) {
return toBeCreatedRuleConfig;
@@ -114,7 +114,7 @@ public final class LegacyRuleDefinitionBackendHandler
implements DistSQLBackendH
}
@SuppressWarnings({"rawtypes", "unchecked"})
- private RuleConfiguration processAlter(final RuleDefinitionStatement
sqlStatement, final DatabaseRuleRDLAlterExecutor executor, final
RuleConfiguration currentRuleConfig) {
+ private RuleConfiguration processAlter(final RuleDefinitionStatement
sqlStatement, final DatabaseRuleAlterExecutor executor, final RuleConfiguration
currentRuleConfig) {
RuleConfiguration toBeAlteredRuleConfig =
executor.buildToBeAlteredRuleConfiguration(sqlStatement);
executor.updateCurrentRuleConfiguration(currentRuleConfig,
toBeAlteredRuleConfig);
return currentRuleConfig;
@@ -122,7 +122,7 @@ public final class LegacyRuleDefinitionBackendHandler
implements DistSQLBackendH
@SuppressWarnings({"rawtypes", "unchecked"})
private void processDrop(final ShardingSphereDatabase database, final
Collection<RuleConfiguration> configs, final RuleDefinitionStatement
sqlStatement,
- final DatabaseRuleRDLDropExecutor executor, final
RuleConfiguration currentRuleConfig) {
+ final DatabaseRuleDropExecutor executor, final
RuleConfiguration currentRuleConfig) {
if (!executor.hasAnyOneToBeDropped(sqlStatement, currentRuleConfig)) {
return;
}
diff --git
a/proxy/backend/core/src/main/resources/META-INF/services/org.apache.shardingsphere.distsql.handler.type.rdl.RDLExecutor
b/proxy/backend/core/src/main/resources/META-INF/services/org.apache.shardingsphere.distsql.handler.type.rdl.resource.ResourceDefinitionExecutor
similarity index 100%
rename from
proxy/backend/core/src/main/resources/META-INF/services/org.apache.shardingsphere.distsql.handler.type.rdl.RDLExecutor
rename to
proxy/backend/core/src/main/resources/META-INF/services/org.apache.shardingsphere.distsql.handler.type.rdl.resource.ResourceDefinitionExecutor
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 192c048fa54..8e82259e8e0 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.DatabaseRuleRDLCreateExecutor;
+import
org.apache.shardingsphere.distsql.handler.type.rdl.rule.database.DatabaseRuleCreateExecutor;
import
org.apache.shardingsphere.infra.metadata.database.ShardingSphereDatabase;
-public final class FixtureDatabaseRuleCreateExecutor implements
DatabaseRuleRDLCreateExecutor<CreateFixtureRuleStatement,
FixtureRuleConfiguration> {
+public final class FixtureDatabaseRuleCreateExecutor implements
DatabaseRuleCreateExecutor<CreateFixtureRuleStatement,
FixtureRuleConfiguration> {
@Override
public FixtureRuleConfiguration buildToBeCreatedRuleConfiguration(final
FixtureRuleConfiguration currentRuleConfig, final CreateFixtureRuleStatement
sqlStatement) {
diff --git
a/proxy/backend/core/src/test/resources/META-INF/services/org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleRDLExecutor
b/proxy/backend/core/src/test/resources/META-INF/services/org.apache.shardingsphere.distsql.handler.type.rdl.rule.database.DatabaseRuleDefinitionExecutor
similarity index 100%
rename from
proxy/backend/core/src/test/resources/META-INF/services/org.apache.shardingsphere.distsql.handler.type.rdl.database.DatabaseRuleRDLExecutor
rename to
proxy/backend/core/src/test/resources/META-INF/services/org.apache.shardingsphere.distsql.handler.type.rdl.rule.database.DatabaseRuleDefinitionExecutor