This is an automated email from the ASF dual-hosted git repository.
panjuan pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/shardingsphere.git
The following commit(s) were added to refs/heads/master by this push:
new 8f5b2aadf93 Refactor CREATE/ALTER/DROP PROCESS CONFIGURATION DistSQL
impl for common usage (#20902)
8f5b2aadf93 is described below
commit 8f5b2aadf937597c4d11e5a6c70b273e437d7646
Author: Hongsheng Zhong <[email protected]>
AuthorDate: Fri Sep 9 18:10:06 2022 +0800
Refactor CREATE/ALTER/DROP PROCESS CONFIGURATION DistSQL impl for common
usage (#20902)
* Rename migrationProcessConfiguration to
inventoryIncrementalProcessConfiguration for common usage
* Add getPipelineJobPublicAPI
* Refactor dropMigrationProcessConfiguration for common usage
* Refactor createMigrationProcessConfiguration for common usage
* Refactor alterMigrationProcessConfiguration for common usage
* Remove unused code
---
.../src/main/antlr4/imports/RALStatement.g4 | 6 ++---
.../core/kernel/KernelDistSQLStatementVisitor.java | 26 ++++++++++++----------
...oryIncrementalProcessConfigurationSegment.java} | 4 ++--
...yIncrementalProcessConfigurationStatement.java} | 10 +++++----
...yIncrementalProcessConfigurationStatement.java} | 10 +++++----
...DropPipelineProcessConfigurationStatement.java} | 6 +++--
.../pipeline/api/PipelineJobPublicAPIFactory.java | 12 ++++++++++
.../data/pipeline/api/job/JobType.java | 2 +-
...ngsphere.data.pipeline.api.PipelineJobPublicAPI | 4 +---
...oryIncrementalProcessConfigurationUpdater.java} | 21 +++++++++--------
...oryIncrementalProcessConfigurationUpdater.java} | 21 +++++++++--------
...> DropPipelineProcessConfigurationUpdater.java} | 17 +++++++-------
...entalProcessConfigurationSegmentConverter.java} | 10 ++++-----
....shardingsphere.infra.distsql.update.RALUpdater | 6 ++---
.../UpdatableScalingRALStatementAssert.java | 12 +++++-----
...pelineProcessConfigurationStatementAssert.java} | 12 +++++-----
.../jaxb/cases/domain/SQLParserTestCases.java | 4 ++--
...lineProcessConfigurationStatementTestCase.java} | 4 ++--
18 files changed, 101 insertions(+), 86 deletions(-)
diff --git
a/shardingsphere-distsql/shardingsphere-distsql-parser/src/main/antlr4/imports/RALStatement.g4
b/shardingsphere-distsql/shardingsphere-distsql-parser/src/main/antlr4/imports/RALStatement.g4
index 32107480059..497ecd3fb5d 100644
---
a/shardingsphere-distsql/shardingsphere-distsql-parser/src/main/antlr4/imports/RALStatement.g4
+++
b/shardingsphere-distsql/shardingsphere-distsql-parser/src/main/antlr4/imports/RALStatement.g4
@@ -96,18 +96,18 @@ showMigrationProcessConfiguration
;
createMigrationProcessConfiguration
- : CREATE MIGRATION PROCESS CONFIGURATION migrationProcessConfiguration?
+ : CREATE MIGRATION PROCESS CONFIGURATION
inventoryIncrementalProcessConfiguration?
;
alterMigrationProcessConfiguration
- : ALTER MIGRATION PROCESS CONFIGURATION migrationProcessConfiguration?
+ : ALTER MIGRATION PROCESS CONFIGURATION
inventoryIncrementalProcessConfiguration?
;
dropMigrationProcessConfiguration
: DROP MIGRATION PROCESS CONFIGURATION confPath
;
-migrationProcessConfiguration
+inventoryIncrementalProcessConfiguration
: LP readDefinition? (COMMA? writeDefinition)? (COMMA? streamChannel)? RP
;
diff --git
a/shardingsphere-distsql/shardingsphere-distsql-parser/src/main/java/org/apache/shardingsphere/distsql/parser/core/kernel/KernelDistSQLStatementVisitor.java
b/shardingsphere-distsql/shardingsphere-distsql-parser/src/main/java/org/apache/shardingsphere/distsql/parser/core/kernel/KernelDistSQLStatementVisitor.java
index eaa0cad5322..6188d9c3ccb 100644
---
a/shardingsphere-distsql/shardingsphere-distsql-parser/src/main/java/org/apache/shardingsphere/distsql/parser/core/kernel/KernelDistSQLStatementVisitor.java
+++
b/shardingsphere-distsql/shardingsphere-distsql-parser/src/main/java/org/apache/shardingsphere/distsql/parser/core/kernel/KernelDistSQLStatementVisitor.java
@@ -44,8 +44,8 @@ import
org.apache.shardingsphere.distsql.parser.autogen.KernelDistSQLStatementPa
import
org.apache.shardingsphere.distsql.parser.autogen.KernelDistSQLStatementParser.FromSegmentContext;
import
org.apache.shardingsphere.distsql.parser.autogen.KernelDistSQLStatementParser.ImportDatabaseConfigurationContext;
import
org.apache.shardingsphere.distsql.parser.autogen.KernelDistSQLStatementParser.InstanceIdContext;
+import
org.apache.shardingsphere.distsql.parser.autogen.KernelDistSQLStatementParser.InventoryIncrementalProcessConfigurationContext;
import
org.apache.shardingsphere.distsql.parser.autogen.KernelDistSQLStatementParser.LabelInstanceContext;
-import
org.apache.shardingsphere.distsql.parser.autogen.KernelDistSQLStatementParser.MigrationProcessConfigurationContext;
import
org.apache.shardingsphere.distsql.parser.autogen.KernelDistSQLStatementParser.PasswordContext;
import
org.apache.shardingsphere.distsql.parser.autogen.KernelDistSQLStatementParser.PrepareDistSQLContext;
import
org.apache.shardingsphere.distsql.parser.autogen.KernelDistSQLStatementParser.PropertiesDefinitionContext;
@@ -76,7 +76,7 @@ import
org.apache.shardingsphere.distsql.parser.autogen.KernelDistSQLStatementPa
import org.apache.shardingsphere.distsql.parser.segment.AlgorithmSegment;
import org.apache.shardingsphere.distsql.parser.segment.DataSourceSegment;
import
org.apache.shardingsphere.distsql.parser.segment.HostnameAndPortBasedDataSourceSegment;
-import
org.apache.shardingsphere.distsql.parser.segment.MigrationProcessConfigurationSegment;
+import
org.apache.shardingsphere.distsql.parser.segment.InventoryIncrementalProcessConfigurationSegment;
import org.apache.shardingsphere.distsql.parser.segment.ReadOrWriteSegment;
import
org.apache.shardingsphere.distsql.parser.segment.URLBasedDataSourceSegment;
import
org.apache.shardingsphere.distsql.parser.statement.ral.hint.ClearHintStatement;
@@ -91,11 +91,11 @@ import
org.apache.shardingsphere.distsql.parser.statement.ral.queryable.ShowSQLT
import
org.apache.shardingsphere.distsql.parser.statement.ral.queryable.ShowTableMetadataStatement;
import
org.apache.shardingsphere.distsql.parser.statement.ral.queryable.ShowVariableStatement;
import
org.apache.shardingsphere.distsql.parser.statement.ral.updatable.AlterInstanceStatement;
-import
org.apache.shardingsphere.distsql.parser.statement.ral.updatable.AlterMigrationProcessConfigurationStatement;
+import
org.apache.shardingsphere.distsql.parser.statement.ral.updatable.AlterInventoryIncrementalProcessConfigurationStatement;
import
org.apache.shardingsphere.distsql.parser.statement.ral.updatable.ApplyDistSQLStatement;
-import
org.apache.shardingsphere.distsql.parser.statement.ral.updatable.CreateMigrationProcessConfigurationStatement;
+import
org.apache.shardingsphere.distsql.parser.statement.ral.updatable.CreateInventoryIncrementalProcessConfigurationStatement;
import
org.apache.shardingsphere.distsql.parser.statement.ral.updatable.DiscardDistSQLStatement;
-import
org.apache.shardingsphere.distsql.parser.statement.ral.updatable.DropMigrationProcessConfigurationStatement;
+import
org.apache.shardingsphere.distsql.parser.statement.ral.updatable.DropPipelineProcessConfigurationStatement;
import
org.apache.shardingsphere.distsql.parser.statement.ral.updatable.ImportDatabaseConfigurationStatement;
import
org.apache.shardingsphere.distsql.parser.statement.ral.updatable.LabelInstanceStatement;
import
org.apache.shardingsphere.distsql.parser.statement.ral.updatable.PrepareDistSQLStatement;
@@ -363,24 +363,26 @@ public final class KernelDistSQLStatementVisitor extends
KernelDistSQLStatementB
@Override
public ASTNode visitCreateMigrationProcessConfiguration(final
CreateMigrationProcessConfigurationContext ctx) {
- MigrationProcessConfigurationSegment segment = null ==
ctx.migrationProcessConfiguration() ? null :
(MigrationProcessConfigurationSegment)
visit(ctx.migrationProcessConfiguration());
- return new CreateMigrationProcessConfigurationStatement(segment);
+ InventoryIncrementalProcessConfigurationSegment segment = null ==
ctx.inventoryIncrementalProcessConfiguration() ? null
+ : (InventoryIncrementalProcessConfigurationSegment)
visit(ctx.inventoryIncrementalProcessConfiguration());
+ return new
CreateInventoryIncrementalProcessConfigurationStatement("MIGRATION", segment);
}
@Override
public ASTNode visitAlterMigrationProcessConfiguration(final
AlterMigrationProcessConfigurationContext ctx) {
- MigrationProcessConfigurationSegment segment = null ==
ctx.migrationProcessConfiguration() ? null :
(MigrationProcessConfigurationSegment)
visit(ctx.migrationProcessConfiguration());
- return new AlterMigrationProcessConfigurationStatement(segment);
+ InventoryIncrementalProcessConfigurationSegment segment = null ==
ctx.inventoryIncrementalProcessConfiguration() ? null
+ : (InventoryIncrementalProcessConfigurationSegment)
visit(ctx.inventoryIncrementalProcessConfiguration());
+ return new
AlterInventoryIncrementalProcessConfigurationStatement("MIGRATION", segment);
}
@Override
public ASTNode visitDropMigrationProcessConfiguration(final
KernelDistSQLStatementParser.DropMigrationProcessConfigurationContext ctx) {
- return new
DropMigrationProcessConfigurationStatement(getIdentifierValue(ctx.confPath()));
+ return new DropPipelineProcessConfigurationStatement("MIGRATION",
getIdentifierValue(ctx.confPath()));
}
@Override
- public ASTNode visitMigrationProcessConfiguration(final
MigrationProcessConfigurationContext ctx) {
- MigrationProcessConfigurationSegment result = new
MigrationProcessConfigurationSegment();
+ public ASTNode visitInventoryIncrementalProcessConfiguration(final
InventoryIncrementalProcessConfigurationContext ctx) {
+ InventoryIncrementalProcessConfigurationSegment result = new
InventoryIncrementalProcessConfigurationSegment();
if (null != ctx.readDefinition()) {
result.setReadSegment((ReadOrWriteSegment)
visit(ctx.readDefinition()));
}
diff --git
a/shardingsphere-distsql/shardingsphere-distsql-statement/src/main/java/org/apache/shardingsphere/distsql/parser/segment/MigrationProcessConfigurationSegment.java
b/shardingsphere-distsql/shardingsphere-distsql-statement/src/main/java/org/apache/shardingsphere/distsql/parser/segment/InventoryIncrementalProcessConfigurationSegment.java
similarity index 88%
rename from
shardingsphere-distsql/shardingsphere-distsql-statement/src/main/java/org/apache/shardingsphere/distsql/parser/segment/MigrationProcessConfigurationSegment.java
rename to
shardingsphere-distsql/shardingsphere-distsql-statement/src/main/java/org/apache/shardingsphere/distsql/parser/segment/InventoryIncrementalProcessConfigurationSegment.java
index 44a0e0e0e12..b3a08995ff6 100644
---
a/shardingsphere-distsql/shardingsphere-distsql-statement/src/main/java/org/apache/shardingsphere/distsql/parser/segment/MigrationProcessConfigurationSegment.java
+++
b/shardingsphere-distsql/shardingsphere-distsql-statement/src/main/java/org/apache/shardingsphere/distsql/parser/segment/InventoryIncrementalProcessConfigurationSegment.java
@@ -22,11 +22,11 @@ import lombok.Setter;
import org.apache.shardingsphere.sql.parser.api.visitor.ASTNode;
/**
- * Migration process configuration segment.
+ * Inventory incremental process configuration segment.
*/
@Getter
@Setter
-public final class MigrationProcessConfigurationSegment implements ASTNode {
+public final class InventoryIncrementalProcessConfigurationSegment implements
ASTNode {
private ReadOrWriteSegment readSegment;
diff --git
a/shardingsphere-distsql/shardingsphere-distsql-statement/src/main/java/org/apache/shardingsphere/distsql/parser/statement/ral/updatable/CreateMigrationProcessConfigurationStatement.java
b/shardingsphere-distsql/shardingsphere-distsql-statement/src/main/java/org/apache/shardingsphere/distsql/parser/statement/ral/updatable/AlterInventoryIncrementalProcessConfigurationStatement.java
similarity index 72%
rename from
shardingsphere-distsql/shardingsphere-distsql-statement/src/main/java/org/apache/shardingsphere/distsql/parser/statement/ral/updatable/CreateMigrationProcessConfigurationStatement.java
rename to
shardingsphere-distsql/shardingsphere-distsql-statement/src/main/java/org/apache/shardingsphere/distsql/parser/statement/ral/updatable/AlterInventoryIncrementalProcessConfigurationStatement.java
index 025b1dc6303..275b8b8e288 100644
---
a/shardingsphere-distsql/shardingsphere-distsql-statement/src/main/java/org/apache/shardingsphere/distsql/parser/statement/ral/updatable/CreateMigrationProcessConfigurationStatement.java
+++
b/shardingsphere-distsql/shardingsphere-distsql-statement/src/main/java/org/apache/shardingsphere/distsql/parser/statement/ral/updatable/AlterInventoryIncrementalProcessConfigurationStatement.java
@@ -19,15 +19,17 @@ package
org.apache.shardingsphere.distsql.parser.statement.ral.updatable;
import lombok.Getter;
import lombok.RequiredArgsConstructor;
-import
org.apache.shardingsphere.distsql.parser.segment.MigrationProcessConfigurationSegment;
+import
org.apache.shardingsphere.distsql.parser.segment.InventoryIncrementalProcessConfigurationSegment;
import
org.apache.shardingsphere.distsql.parser.statement.ral.scaling.UpdatableScalingRALStatement;
/**
- * Create migration process configuration statement.
+ * Alter inventory incremental process configuration statement.
*/
@RequiredArgsConstructor
@Getter
-public final class CreateMigrationProcessConfigurationStatement extends
UpdatableScalingRALStatement {
+public final class AlterInventoryIncrementalProcessConfigurationStatement
extends UpdatableScalingRALStatement {
- private final MigrationProcessConfigurationSegment
migrationProcessConfigurationSegment;
+ private final String jobTypeName;
+
+ private final InventoryIncrementalProcessConfigurationSegment
processConfigSegment;
}
diff --git
a/shardingsphere-distsql/shardingsphere-distsql-statement/src/main/java/org/apache/shardingsphere/distsql/parser/statement/ral/updatable/AlterMigrationProcessConfigurationStatement.java
b/shardingsphere-distsql/shardingsphere-distsql-statement/src/main/java/org/apache/shardingsphere/distsql/parser/statement/ral/updatable/CreateInventoryIncrementalProcessConfigurationStatement.java
similarity index 72%
rename from
shardingsphere-distsql/shardingsphere-distsql-statement/src/main/java/org/apache/shardingsphere/distsql/parser/statement/ral/updatable/AlterMigrationProcessConfigurationStatement.java
rename to
shardingsphere-distsql/shardingsphere-distsql-statement/src/main/java/org/apache/shardingsphere/distsql/parser/statement/ral/updatable/CreateInventoryIncrementalProcessConfigurationStatement.java
index 06bca682ec4..ecf4f3235bd 100644
---
a/shardingsphere-distsql/shardingsphere-distsql-statement/src/main/java/org/apache/shardingsphere/distsql/parser/statement/ral/updatable/AlterMigrationProcessConfigurationStatement.java
+++
b/shardingsphere-distsql/shardingsphere-distsql-statement/src/main/java/org/apache/shardingsphere/distsql/parser/statement/ral/updatable/CreateInventoryIncrementalProcessConfigurationStatement.java
@@ -19,15 +19,17 @@ package
org.apache.shardingsphere.distsql.parser.statement.ral.updatable;
import lombok.Getter;
import lombok.RequiredArgsConstructor;
-import
org.apache.shardingsphere.distsql.parser.segment.MigrationProcessConfigurationSegment;
+import
org.apache.shardingsphere.distsql.parser.segment.InventoryIncrementalProcessConfigurationSegment;
import
org.apache.shardingsphere.distsql.parser.statement.ral.scaling.UpdatableScalingRALStatement;
/**
- * Alter migration process configuration statement.
+ * Create inventory incremental process configuration statement.
*/
@RequiredArgsConstructor
@Getter
-public final class AlterMigrationProcessConfigurationStatement extends
UpdatableScalingRALStatement {
+public final class CreateInventoryIncrementalProcessConfigurationStatement
extends UpdatableScalingRALStatement {
- private final MigrationProcessConfigurationSegment
migrationProcessConfigurationSegment;
+ private final String jobTypeName;
+
+ private final InventoryIncrementalProcessConfigurationSegment
processConfigSegment;
}
diff --git
a/shardingsphere-distsql/shardingsphere-distsql-statement/src/main/java/org/apache/shardingsphere/distsql/parser/statement/ral/updatable/DropMigrationProcessConfigurationStatement.java
b/shardingsphere-distsql/shardingsphere-distsql-statement/src/main/java/org/apache/shardingsphere/distsql/parser/statement/ral/updatable/DropPipelineProcessConfigurationStatement.java
similarity index 85%
rename from
shardingsphere-distsql/shardingsphere-distsql-statement/src/main/java/org/apache/shardingsphere/distsql/parser/statement/ral/updatable/DropMigrationProcessConfigurationStatement.java
rename to
shardingsphere-distsql/shardingsphere-distsql-statement/src/main/java/org/apache/shardingsphere/distsql/parser/statement/ral/updatable/DropPipelineProcessConfigurationStatement.java
index a9954b52d82..32a979fa233 100644
---
a/shardingsphere-distsql/shardingsphere-distsql-statement/src/main/java/org/apache/shardingsphere/distsql/parser/statement/ral/updatable/DropMigrationProcessConfigurationStatement.java
+++
b/shardingsphere-distsql/shardingsphere-distsql-statement/src/main/java/org/apache/shardingsphere/distsql/parser/statement/ral/updatable/DropPipelineProcessConfigurationStatement.java
@@ -22,11 +22,13 @@ import lombok.RequiredArgsConstructor;
import
org.apache.shardingsphere.distsql.parser.statement.ral.scaling.UpdatableScalingRALStatement;
/**
- * Drop migration process configuration statement.
+ * Drop pipeline process configuration statement.
*/
@RequiredArgsConstructor
@Getter
-public final class DropMigrationProcessConfigurationStatement extends
UpdatableScalingRALStatement {
+public final class DropPipelineProcessConfigurationStatement extends
UpdatableScalingRALStatement {
+
+ private final String jobTypeName;
private final String confPath;
}
diff --git
a/shardingsphere-kernel/shardingsphere-data-pipeline/shardingsphere-data-pipeline-api/src/main/java/org/apache/shardingsphere/data/pipeline/api/PipelineJobPublicAPIFactory.java
b/shardingsphere-kernel/shardingsphere-data-pipeline/shardingsphere-data-pipeline-api/src/main/java/org/apache/shardingsphere/data/pipeline/api/PipelineJobPublicAPIFactory.java
index 557e9c49783..97e6d18727d 100644
---
a/shardingsphere-kernel/shardingsphere-data-pipeline/shardingsphere-data-pipeline-api/src/main/java/org/apache/shardingsphere/data/pipeline/api/PipelineJobPublicAPIFactory.java
+++
b/shardingsphere-kernel/shardingsphere-data-pipeline/shardingsphere-data-pipeline-api/src/main/java/org/apache/shardingsphere/data/pipeline/api/PipelineJobPublicAPIFactory.java
@@ -17,8 +17,10 @@
package org.apache.shardingsphere.data.pipeline.api;
+import lombok.NonNull;
import org.apache.shardingsphere.infra.util.spi.ShardingSphereServiceLoader;
import
org.apache.shardingsphere.infra.util.spi.type.required.RequiredSPIRegistry;
+import org.apache.shardingsphere.infra.util.spi.type.typed.TypedSPIRegistry;
/**
* Pipeline job public API factory.
@@ -29,6 +31,16 @@ public final class PipelineJobPublicAPIFactory {
ShardingSphereServiceLoader.register(MigrationJobPublicAPI.class);
}
+ /**
+ * Get instance of pipeline job public API.
+ *
+ * @param jobTypeName job type name
+ * @return got instance
+ */
+ public static PipelineJobPublicAPI getPipelineJobPublicAPI(@NonNull final
String jobTypeName) {
+ return
TypedSPIRegistry.getRegisteredService(PipelineJobPublicAPI.class, jobTypeName);
+ }
+
/**
* Get instance of migration job public API.
*
diff --git
a/shardingsphere-kernel/shardingsphere-data-pipeline/shardingsphere-data-pipeline-api/src/main/java/org/apache/shardingsphere/data/pipeline/api/job/JobType.java
b/shardingsphere-kernel/shardingsphere-data-pipeline/shardingsphere-data-pipeline-api/src/main/java/org/apache/shardingsphere/data/pipeline/api/job/JobType.java
index 553e720c936..24c4b1f8da3 100644
---
a/shardingsphere-kernel/shardingsphere-data-pipeline/shardingsphere-data-pipeline-api/src/main/java/org/apache/shardingsphere/data/pipeline/api/job/JobType.java
+++
b/shardingsphere-kernel/shardingsphere-data-pipeline/shardingsphere-data-pipeline-api/src/main/java/org/apache/shardingsphere/data/pipeline/api/job/JobType.java
@@ -48,7 +48,7 @@ public enum JobType {
JobType(final String typeName, final String typeCode) {
Preconditions.checkArgument(StringUtils.isAlpha(typeName), "type name
must be character of [a-z]");
this.typeName = typeName;
- this.lowercaseTypeName = typeName.toLowerCase();
+ lowercaseTypeName = typeName.toLowerCase();
Preconditions.checkArgument(typeCode.length() == 2, "code length is
not 2");
this.typeCode = typeCode;
}
diff --git
a/shardingsphere-proxy/shardingsphere-proxy-backend/src/main/resources/META-INF/services/org.apache.shardingsphere.infra.distsql.update.RALUpdater
b/shardingsphere-kernel/shardingsphere-data-pipeline/shardingsphere-data-pipeline-core/src/main/resources/META-INF/services/org.apache.shardingsphere.data.pipeline.api.PipelineJobPublicAPI
similarity index 70%
copy from
shardingsphere-proxy/shardingsphere-proxy-backend/src/main/resources/META-INF/services/org.apache.shardingsphere.infra.distsql.update.RALUpdater
copy to
shardingsphere-kernel/shardingsphere-data-pipeline/shardingsphere-data-pipeline-core/src/main/resources/META-INF/services/org.apache.shardingsphere.data.pipeline.api.PipelineJobPublicAPI
index 7afc152634a..90857b277c4 100644
---
a/shardingsphere-proxy/shardingsphere-proxy-backend/src/main/resources/META-INF/services/org.apache.shardingsphere.infra.distsql.update.RALUpdater
+++
b/shardingsphere-kernel/shardingsphere-data-pipeline/shardingsphere-data-pipeline-core/src/main/resources/META-INF/services/org.apache.shardingsphere.data.pipeline.api.PipelineJobPublicAPI
@@ -15,6 +15,4 @@
# limitations under the License.
#
-org.apache.shardingsphere.proxy.backend.handler.distsql.ral.updatable.CreateMigrationProcessConfigurationUpdater
-org.apache.shardingsphere.proxy.backend.handler.distsql.ral.updatable.AlterMigrationProcessConfigurationUpdater
-org.apache.shardingsphere.proxy.backend.handler.distsql.ral.updatable.DropMigrationProcessConfigurationUpdater
+org.apache.shardingsphere.data.pipeline.scenario.migration.MigrationJobAPIImpl
diff --git
a/shardingsphere-proxy/shardingsphere-proxy-backend/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/ral/updatable/AlterMigrationProcessConfigurationUpdater.java
b/shardingsphere-proxy/shardingsphere-proxy-backend/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/ral/updatable/AlterInventoryIncrementalProcessConfigurationUpdater.java
similarity index 60%
rename from
shardingsphere-proxy/shardingsphere-proxy-backend/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/ral/updatable/AlterMigrationProcessConfigurationUpdater.java
rename to
shardingsphere-proxy/shardingsphere-proxy-backend/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/ral/updatable/AlterInventoryIncrementalProcessConfigurationUpdater.java
index 03815ad3cad..b85b0ef3462 100644
---
a/shardingsphere-proxy/shardingsphere-proxy-backend/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/ral/updatable/AlterMigrationProcessConfigurationUpdater.java
+++
b/shardingsphere-proxy/shardingsphere-proxy-backend/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/ral/updatable/AlterInventoryIncrementalProcessConfigurationUpdater.java
@@ -17,28 +17,27 @@
package org.apache.shardingsphere.proxy.backend.handler.distsql.ral.updatable;
-import org.apache.shardingsphere.data.pipeline.api.MigrationJobPublicAPI;
+import org.apache.shardingsphere.data.pipeline.api.PipelineJobPublicAPI;
import org.apache.shardingsphere.data.pipeline.api.PipelineJobPublicAPIFactory;
-import
org.apache.shardingsphere.distsql.parser.statement.ral.updatable.AlterMigrationProcessConfigurationStatement;
+import
org.apache.shardingsphere.distsql.parser.statement.ral.updatable.AlterInventoryIncrementalProcessConfigurationStatement;
import
org.apache.shardingsphere.infra.config.rule.data.pipeline.PipelineProcessConfiguration;
import org.apache.shardingsphere.infra.distsql.update.RALUpdater;
-import
org.apache.shardingsphere.proxy.backend.handler.distsql.ral.updatable.converter.MigrationProcessConfigurationSegmentConverter;
+import
org.apache.shardingsphere.proxy.backend.handler.distsql.ral.updatable.converter.InventoryIncrementalProcessConfigurationSegmentConverter;
/**
- * Alter migration process configuration updater.
+ * Alter inventory incremental process configuration updater.
*/
-public final class AlterMigrationProcessConfigurationUpdater implements
RALUpdater<AlterMigrationProcessConfigurationStatement> {
-
- private static final MigrationJobPublicAPI JOB_API =
PipelineJobPublicAPIFactory.getMigrationJobPublicAPI();
+public final class AlterInventoryIncrementalProcessConfigurationUpdater
implements RALUpdater<AlterInventoryIncrementalProcessConfigurationStatement> {
@Override
- public void executeUpdate(final String databaseName, final
AlterMigrationProcessConfigurationStatement sqlStatement) {
- PipelineProcessConfiguration processConfig =
MigrationProcessConfigurationSegmentConverter.convert(sqlStatement.getMigrationProcessConfigurationSegment());
- JOB_API.alterProcessConfiguration(processConfig);
+ public void executeUpdate(final String databaseName, final
AlterInventoryIncrementalProcessConfigurationStatement sqlStatement) {
+ PipelineJobPublicAPI jobAPI =
PipelineJobPublicAPIFactory.getPipelineJobPublicAPI(sqlStatement.getJobTypeName());
+ PipelineProcessConfiguration processConfig =
InventoryIncrementalProcessConfigurationSegmentConverter.convert(sqlStatement.getProcessConfigSegment());
+ jobAPI.alterProcessConfiguration(processConfig);
}
@Override
public String getType() {
- return AlterMigrationProcessConfigurationStatement.class.getName();
+ return
AlterInventoryIncrementalProcessConfigurationStatement.class.getName();
}
}
diff --git
a/shardingsphere-proxy/shardingsphere-proxy-backend/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/ral/updatable/CreateMigrationProcessConfigurationUpdater.java
b/shardingsphere-proxy/shardingsphere-proxy-backend/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/ral/updatable/CreateInventoryIncrementalProcessConfigurationUpdater.java
similarity index 60%
rename from
shardingsphere-proxy/shardingsphere-proxy-backend/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/ral/updatable/CreateMigrationProcessConfigurationUpdater.java
rename to
shardingsphere-proxy/shardingsphere-proxy-backend/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/ral/updatable/CreateInventoryIncrementalProcessConfigurationUpdater.java
index e96c0f615c6..e91ef111dc7 100644
---
a/shardingsphere-proxy/shardingsphere-proxy-backend/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/ral/updatable/CreateMigrationProcessConfigurationUpdater.java
+++
b/shardingsphere-proxy/shardingsphere-proxy-backend/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/ral/updatable/CreateInventoryIncrementalProcessConfigurationUpdater.java
@@ -17,28 +17,27 @@
package org.apache.shardingsphere.proxy.backend.handler.distsql.ral.updatable;
-import org.apache.shardingsphere.data.pipeline.api.MigrationJobPublicAPI;
+import org.apache.shardingsphere.data.pipeline.api.PipelineJobPublicAPI;
import org.apache.shardingsphere.data.pipeline.api.PipelineJobPublicAPIFactory;
-import
org.apache.shardingsphere.distsql.parser.statement.ral.updatable.CreateMigrationProcessConfigurationStatement;
+import
org.apache.shardingsphere.distsql.parser.statement.ral.updatable.CreateInventoryIncrementalProcessConfigurationStatement;
import
org.apache.shardingsphere.infra.config.rule.data.pipeline.PipelineProcessConfiguration;
import org.apache.shardingsphere.infra.distsql.update.RALUpdater;
-import
org.apache.shardingsphere.proxy.backend.handler.distsql.ral.updatable.converter.MigrationProcessConfigurationSegmentConverter;
+import
org.apache.shardingsphere.proxy.backend.handler.distsql.ral.updatable.converter.InventoryIncrementalProcessConfigurationSegmentConverter;
/**
- * Create migration process configuration updater.
+ * Create inventory incremental process configuration updater.
*/
-public final class CreateMigrationProcessConfigurationUpdater implements
RALUpdater<CreateMigrationProcessConfigurationStatement> {
-
- private static final MigrationJobPublicAPI JOB_API =
PipelineJobPublicAPIFactory.getMigrationJobPublicAPI();
+public final class CreateInventoryIncrementalProcessConfigurationUpdater
implements RALUpdater<CreateInventoryIncrementalProcessConfigurationStatement> {
@Override
- public void executeUpdate(final String databaseName, final
CreateMigrationProcessConfigurationStatement sqlStatement) {
- PipelineProcessConfiguration processConfig =
MigrationProcessConfigurationSegmentConverter.convert(sqlStatement.getMigrationProcessConfigurationSegment());
- JOB_API.createProcessConfiguration(processConfig);
+ public void executeUpdate(final String databaseName, final
CreateInventoryIncrementalProcessConfigurationStatement sqlStatement) {
+ PipelineJobPublicAPI jobAPI =
PipelineJobPublicAPIFactory.getPipelineJobPublicAPI(sqlStatement.getJobTypeName());
+ PipelineProcessConfiguration processConfig =
InventoryIncrementalProcessConfigurationSegmentConverter.convert(sqlStatement.getProcessConfigSegment());
+ jobAPI.createProcessConfiguration(processConfig);
}
@Override
public String getType() {
- return CreateMigrationProcessConfigurationStatement.class.getName();
+ return
CreateInventoryIncrementalProcessConfigurationStatement.class.getName();
}
}
diff --git
a/shardingsphere-proxy/shardingsphere-proxy-backend/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/ral/updatable/DropMigrationProcessConfigurationUpdater.java
b/shardingsphere-proxy/shardingsphere-proxy-backend/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/ral/updatable/DropPipelineProcessConfigurationUpdater.java
similarity index 66%
rename from
shardingsphere-proxy/shardingsphere-proxy-backend/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/ral/updatable/DropMigrationProcessConfigurationUpdater.java
rename to
shardingsphere-proxy/shardingsphere-proxy-backend/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/ral/updatable/DropPipelineProcessConfigurationUpdater.java
index f8f2c9052cf..6d67482be2a 100644
---
a/shardingsphere-proxy/shardingsphere-proxy-backend/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/ral/updatable/DropMigrationProcessConfigurationUpdater.java
+++
b/shardingsphere-proxy/shardingsphere-proxy-backend/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/ral/updatable/DropPipelineProcessConfigurationUpdater.java
@@ -17,25 +17,24 @@
package org.apache.shardingsphere.proxy.backend.handler.distsql.ral.updatable;
-import org.apache.shardingsphere.data.pipeline.api.MigrationJobPublicAPI;
+import org.apache.shardingsphere.data.pipeline.api.PipelineJobPublicAPI;
import org.apache.shardingsphere.data.pipeline.api.PipelineJobPublicAPIFactory;
-import
org.apache.shardingsphere.distsql.parser.statement.ral.updatable.DropMigrationProcessConfigurationStatement;
+import
org.apache.shardingsphere.distsql.parser.statement.ral.updatable.DropPipelineProcessConfigurationStatement;
import org.apache.shardingsphere.infra.distsql.update.RALUpdater;
/**
- * Drop migration process configuration updater.
+ * Drop pipeline process configuration updater.
*/
-public final class DropMigrationProcessConfigurationUpdater implements
RALUpdater<DropMigrationProcessConfigurationStatement> {
-
- private static final MigrationJobPublicAPI JOB_API =
PipelineJobPublicAPIFactory.getMigrationJobPublicAPI();
+public final class DropPipelineProcessConfigurationUpdater implements
RALUpdater<DropPipelineProcessConfigurationStatement> {
@Override
- public void executeUpdate(final String databaseName, final
DropMigrationProcessConfigurationStatement sqlStatement) {
- JOB_API.dropProcessConfiguration(sqlStatement.getConfPath());
+ public void executeUpdate(final String databaseName, final
DropPipelineProcessConfigurationStatement sqlStatement) {
+ PipelineJobPublicAPI jobAPI =
PipelineJobPublicAPIFactory.getPipelineJobPublicAPI(sqlStatement.getJobTypeName());
+ jobAPI.dropProcessConfiguration(sqlStatement.getConfPath());
}
@Override
public String getType() {
- return DropMigrationProcessConfigurationStatement.class.getName();
+ return DropPipelineProcessConfigurationStatement.class.getName();
}
}
diff --git
a/shardingsphere-proxy/shardingsphere-proxy-backend/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/ral/updatable/converter/MigrationProcessConfigurationSegmentConverter.java
b/shardingsphere-proxy/shardingsphere-proxy-backend/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/ral/updatable/converter/InventoryIncrementalProcessConfigurationSegmentConverter.java
similarity index 87%
rename from
shardingsphere-proxy/shardingsphere-proxy-backend/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/ral/updatable/converter/MigrationProcessConfigurationSegmentConverter.java
rename to
shardingsphere-proxy/shardingsphere-proxy-backend/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/ral/updatable/converter/InventoryIncrementalProcessConfigurationSegmentConverter.java
index 62c5a065118..958fe21ac4d 100644
---
a/shardingsphere-proxy/shardingsphere-proxy-backend/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/ral/updatable/converter/MigrationProcessConfigurationSegmentConverter.java
+++
b/shardingsphere-proxy/shardingsphere-proxy-backend/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/ral/updatable/converter/InventoryIncrementalProcessConfigurationSegmentConverter.java
@@ -20,7 +20,7 @@ package
org.apache.shardingsphere.proxy.backend.handler.distsql.ral.updatable.co
import lombok.AccessLevel;
import lombok.NoArgsConstructor;
import org.apache.shardingsphere.distsql.parser.segment.AlgorithmSegment;
-import
org.apache.shardingsphere.distsql.parser.segment.MigrationProcessConfigurationSegment;
+import
org.apache.shardingsphere.distsql.parser.segment.InventoryIncrementalProcessConfigurationSegment;
import org.apache.shardingsphere.distsql.parser.segment.ReadOrWriteSegment;
import org.apache.shardingsphere.infra.config.algorithm.AlgorithmConfiguration;
import
org.apache.shardingsphere.infra.config.rule.data.pipeline.PipelineProcessConfiguration;
@@ -28,18 +28,18 @@ import
org.apache.shardingsphere.infra.config.rule.data.pipeline.PipelineReadCon
import
org.apache.shardingsphere.infra.config.rule.data.pipeline.PipelineWriteConfiguration;
/**
- * Migration process configuration segment converter.
+ * Inventory incremental process configuration segment converter.
*/
@NoArgsConstructor(access = AccessLevel.PRIVATE)
-public final class MigrationProcessConfigurationSegmentConverter {
+public final class InventoryIncrementalProcessConfigurationSegmentConverter {
/**
* Convert to pipeline process configuration.
*
- * @param segment migration process configuration segment
+ * @param segment process configuration segment
* @return pipeline process configuration
*/
- public static PipelineProcessConfiguration convert(final
MigrationProcessConfigurationSegment segment) {
+ public static PipelineProcessConfiguration convert(final
InventoryIncrementalProcessConfigurationSegment segment) {
PipelineReadConfiguration readConfig =
convertToReadConfiguration(segment.getReadSegment());
PipelineWriteConfiguration writeConfig =
convertToWriteConfiguration(segment.getWriteSegment());
AlgorithmConfiguration streamChannel =
convertToAlgorithm(segment.getStreamChannel());
diff --git
a/shardingsphere-proxy/shardingsphere-proxy-backend/src/main/resources/META-INF/services/org.apache.shardingsphere.infra.distsql.update.RALUpdater
b/shardingsphere-proxy/shardingsphere-proxy-backend/src/main/resources/META-INF/services/org.apache.shardingsphere.infra.distsql.update.RALUpdater
index 7afc152634a..c03fcc4e826 100644
---
a/shardingsphere-proxy/shardingsphere-proxy-backend/src/main/resources/META-INF/services/org.apache.shardingsphere.infra.distsql.update.RALUpdater
+++
b/shardingsphere-proxy/shardingsphere-proxy-backend/src/main/resources/META-INF/services/org.apache.shardingsphere.infra.distsql.update.RALUpdater
@@ -15,6 +15,6 @@
# limitations under the License.
#
-org.apache.shardingsphere.proxy.backend.handler.distsql.ral.updatable.CreateMigrationProcessConfigurationUpdater
-org.apache.shardingsphere.proxy.backend.handler.distsql.ral.updatable.AlterMigrationProcessConfigurationUpdater
-org.apache.shardingsphere.proxy.backend.handler.distsql.ral.updatable.DropMigrationProcessConfigurationUpdater
+org.apache.shardingsphere.proxy.backend.handler.distsql.ral.updatable.CreateInventoryIncrementalProcessConfigurationUpdater
+org.apache.shardingsphere.proxy.backend.handler.distsql.ral.updatable.AlterInventoryIncrementalProcessConfigurationUpdater
+org.apache.shardingsphere.proxy.backend.handler.distsql.ral.updatable.DropPipelineProcessConfigurationUpdater
diff --git
a/shardingsphere-test/shardingsphere-parser-test/src/main/java/org/apache/shardingsphere/test/sql/parser/parameterized/asserts/statement/distsql/ral/impl/migration/UpdatableScalingRALStatementAssert.java
b/shardingsphere-test/shardingsphere-parser-test/src/main/java/org/apache/shardingsphere/test/sql/parser/parameterized/asserts/statement/distsql/ral/impl/migration/UpdatableScalingRALStatementAssert.java
index 028987d7055..808eac96ac6 100644
---
a/shardingsphere-test/shardingsphere-parser-test/src/main/java/org/apache/shardingsphere/test/sql/parser/parameterized/asserts/statement/distsql/ral/impl/migration/UpdatableScalingRALStatementAssert.java
+++
b/shardingsphere-test/shardingsphere-parser-test/src/main/java/org/apache/shardingsphere/test/sql/parser/parameterized/asserts/statement/distsql/ral/impl/migration/UpdatableScalingRALStatementAssert.java
@@ -20,7 +20,7 @@ package
org.apache.shardingsphere.test.sql.parser.parameterized.asserts.statemen
import lombok.AccessLevel;
import lombok.NoArgsConstructor;
import
org.apache.shardingsphere.distsql.parser.statement.ral.scaling.UpdatableScalingRALStatement;
-import
org.apache.shardingsphere.distsql.parser.statement.ral.updatable.DropMigrationProcessConfigurationStatement;
+import
org.apache.shardingsphere.distsql.parser.statement.ral.updatable.DropPipelineProcessConfigurationStatement;
import
org.apache.shardingsphere.migration.distsql.statement.AddMigrationSourceResourceStatement;
import
org.apache.shardingsphere.migration.distsql.statement.RollbackMigrationStatement;
import
org.apache.shardingsphere.migration.distsql.statement.DropMigrationSourceResourceStatement;
@@ -31,7 +31,7 @@ import
org.apache.shardingsphere.migration.distsql.statement.StopMigrationStatem
import
org.apache.shardingsphere.test.sql.parser.parameterized.asserts.SQLCaseAssertContext;
import
org.apache.shardingsphere.test.sql.parser.parameterized.asserts.statement.distsql.ral.impl.migration.update.AddMigrationSourceResourceStatementAssert;
import
org.apache.shardingsphere.test.sql.parser.parameterized.asserts.statement.distsql.ral.impl.migration.update.RollbackMigrationStatementAssert;
-import
org.apache.shardingsphere.test.sql.parser.parameterized.asserts.statement.distsql.ral.impl.migration.update.DropMigrationProcessConfigurationStatementAssert;
+import
org.apache.shardingsphere.test.sql.parser.parameterized.asserts.statement.distsql.ral.impl.migration.update.DropPipelineProcessConfigurationStatementAssert;
import
org.apache.shardingsphere.test.sql.parser.parameterized.asserts.statement.distsql.ral.impl.migration.update.DropMigrationSourceResourceStatementAssert;
import
org.apache.shardingsphere.test.sql.parser.parameterized.asserts.statement.distsql.ral.impl.migration.update.MigrateTableStatementAssert;
import
org.apache.shardingsphere.test.sql.parser.parameterized.asserts.statement.distsql.ral.impl.migration.update.CommitMigrationStatementAssert;
@@ -40,7 +40,7 @@ import
org.apache.shardingsphere.test.sql.parser.parameterized.asserts.statement
import
org.apache.shardingsphere.test.sql.parser.parameterized.jaxb.cases.domain.statement.SQLParserTestCase;
import
org.apache.shardingsphere.test.sql.parser.parameterized.jaxb.cases.domain.statement.distsql.ral.migration.AddMigrationSourceResourceStatementTestCase;
import
org.apache.shardingsphere.test.sql.parser.parameterized.jaxb.cases.domain.statement.distsql.ral.migration.RollbackMigrationStatementTestCase;
-import
org.apache.shardingsphere.test.sql.parser.parameterized.jaxb.cases.domain.statement.distsql.ral.migration.DropMigrationProcessConfigurationStatementTestCase;
+import
org.apache.shardingsphere.test.sql.parser.parameterized.jaxb.cases.domain.statement.distsql.ral.migration.DropPipelineProcessConfigurationStatementTestCase;
import
org.apache.shardingsphere.test.sql.parser.parameterized.jaxb.cases.domain.statement.distsql.ral.migration.DropMigrationSourceResourceStatementTestCase;
import
org.apache.shardingsphere.test.sql.parser.parameterized.jaxb.cases.domain.statement.distsql.ral.migration.MigrateTableStatementTestCase;
import
org.apache.shardingsphere.test.sql.parser.parameterized.jaxb.cases.domain.statement.distsql.ral.migration.CommitMigrationStatementTestCase;
@@ -64,9 +64,9 @@ public final class UpdatableScalingRALStatementAssert {
// TODO add more test case
if (actual instanceof MigrateTableStatement) {
MigrateTableStatementAssert.assertIs(assertContext,
(MigrateTableStatement) actual, (MigrateTableStatementTestCase) expected);
- } else if (actual instanceof
DropMigrationProcessConfigurationStatement) {
-
DropMigrationProcessConfigurationStatementAssert.assertIs(assertContext,
(DropMigrationProcessConfigurationStatement) actual,
- (DropMigrationProcessConfigurationStatementTestCase)
expected);
+ } else if (actual instanceof
DropPipelineProcessConfigurationStatement) {
+
DropPipelineProcessConfigurationStatementAssert.assertIs(assertContext,
(DropPipelineProcessConfigurationStatement) actual,
+ (DropPipelineProcessConfigurationStatementTestCase)
expected);
} else if (actual instanceof StopMigrationStatement) {
StopMigrationStatementAssert.assertIs(assertContext,
(StopMigrationStatement) actual, (StopMigrationStatementTestCase) expected);
} else if (actual instanceof CommitMigrationStatement) {
diff --git
a/shardingsphere-test/shardingsphere-parser-test/src/main/java/org/apache/shardingsphere/test/sql/parser/parameterized/asserts/statement/distsql/ral/impl/migration/update/DropMigrationProcessConfigurationStatementAssert.java
b/shardingsphere-test/shardingsphere-parser-test/src/main/java/org/apache/shardingsphere/test/sql/parser/parameterized/asserts/statement/distsql/ral/impl/migration/update/DropPipelineProcessConfigurationStatementAssert.java
similarity index 75%
rename from
shardingsphere-test/shardingsphere-parser-test/src/main/java/org/apache/shardingsphere/test/sql/parser/parameterized/asserts/statement/distsql/ral/impl/migration/update/DropMigrationProcessConfigurationStatementAssert.java
rename to
shardingsphere-test/shardingsphere-parser-test/src/main/java/org/apache/shardingsphere/test/sql/parser/parameterized/asserts/statement/distsql/ral/impl/migration/update/DropPipelineProcessConfigurationStatementAssert.java
index ed5438fff9f..c76aa0e2cfb 100644
---
a/shardingsphere-test/shardingsphere-parser-test/src/main/java/org/apache/shardingsphere/test/sql/parser/parameterized/asserts/statement/distsql/ral/impl/migration/update/DropMigrationProcessConfigurationStatementAssert.java
+++
b/shardingsphere-test/shardingsphere-parser-test/src/main/java/org/apache/shardingsphere/test/sql/parser/parameterized/asserts/statement/distsql/ral/impl/migration/update/DropPipelineProcessConfigurationStatementAssert.java
@@ -17,26 +17,26 @@
package
org.apache.shardingsphere.test.sql.parser.parameterized.asserts.statement.distsql.ral.impl.migration.update;
-import
org.apache.shardingsphere.distsql.parser.statement.ral.updatable.DropMigrationProcessConfigurationStatement;
+import
org.apache.shardingsphere.distsql.parser.statement.ral.updatable.DropPipelineProcessConfigurationStatement;
import
org.apache.shardingsphere.test.sql.parser.parameterized.asserts.SQLCaseAssertContext;
-import
org.apache.shardingsphere.test.sql.parser.parameterized.jaxb.cases.domain.statement.distsql.ral.migration.DropMigrationProcessConfigurationStatementTestCase;
+import
org.apache.shardingsphere.test.sql.parser.parameterized.jaxb.cases.domain.statement.distsql.ral.migration.DropPipelineProcessConfigurationStatementTestCase;
import static org.hamcrest.CoreMatchers.is;
import static org.junit.Assert.assertThat;
/**
- * Drop migration process configuration statement assert.
+ * Drop pipeline process configuration statement assert.
*/
-public final class DropMigrationProcessConfigurationStatementAssert {
+public final class DropPipelineProcessConfigurationStatementAssert {
/**
- * Assert drop migration process configuration statement is correct with
expected parser result.
+ * Assert drop pipeline process configuration statement is correct with
expected parser result.
*
* @param assertContext assert context
* @param actual actual statement
* @param expected expected statement test case
*/
- public static void assertIs(final SQLCaseAssertContext assertContext,
final DropMigrationProcessConfigurationStatement actual, final
DropMigrationProcessConfigurationStatementTestCase expected) {
+ public static void assertIs(final SQLCaseAssertContext assertContext,
final DropPipelineProcessConfigurationStatement actual, final
DropPipelineProcessConfigurationStatementTestCase expected) {
assertThat(assertContext.getText("conf path does not match"),
actual.getConfPath(), is(expected.getConfPath()));
}
}
diff --git
a/shardingsphere-test/shardingsphere-parser-test/src/main/java/org/apache/shardingsphere/test/sql/parser/parameterized/jaxb/cases/domain/SQLParserTestCases.java
b/shardingsphere-test/shardingsphere-parser-test/src/main/java/org/apache/shardingsphere/test/sql/parser/parameterized/jaxb/cases/domain/SQLParserTestCases.java
index 54c51f0e0ee..0fcec06d5f3 100644
---
a/shardingsphere-test/shardingsphere-parser-test/src/main/java/org/apache/shardingsphere/test/sql/parser/parameterized/jaxb/cases/domain/SQLParserTestCases.java
+++
b/shardingsphere-test/shardingsphere-parser-test/src/main/java/org/apache/shardingsphere/test/sql/parser/parameterized/jaxb/cases/domain/SQLParserTestCases.java
@@ -311,7 +311,7 @@ import
org.apache.shardingsphere.test.sql.parser.parameterized.jaxb.cases.domain
import
org.apache.shardingsphere.test.sql.parser.parameterized.jaxb.cases.domain.statement.distsql.ral.migration.AddMigrationSourceResourceStatementTestCase;
import
org.apache.shardingsphere.test.sql.parser.parameterized.jaxb.cases.domain.statement.distsql.ral.migration.CheckMigrationStatementTestCase;
import
org.apache.shardingsphere.test.sql.parser.parameterized.jaxb.cases.domain.statement.distsql.ral.migration.RollbackMigrationStatementTestCase;
-import
org.apache.shardingsphere.test.sql.parser.parameterized.jaxb.cases.domain.statement.distsql.ral.migration.DropMigrationProcessConfigurationStatementTestCase;
+import
org.apache.shardingsphere.test.sql.parser.parameterized.jaxb.cases.domain.statement.distsql.ral.migration.DropPipelineProcessConfigurationStatementTestCase;
import
org.apache.shardingsphere.test.sql.parser.parameterized.jaxb.cases.domain.statement.distsql.ral.migration.DropMigrationSourceResourceStatementTestCase;
import
org.apache.shardingsphere.test.sql.parser.parameterized.jaxb.cases.domain.statement.distsql.ral.migration.MigrateTableStatementTestCase;
import
org.apache.shardingsphere.test.sql.parser.parameterized.jaxb.cases.domain.statement.distsql.ral.migration.CommitMigrationStatementTestCase;
@@ -1025,7 +1025,7 @@ public final class SQLParserTestCases {
private final List<StartMigrationStatementTestCase>
startMigrationTestCases = new LinkedList<>();
@XmlElement(name = "drop-migration-process-configuration")
- private final List<DropMigrationProcessConfigurationStatementTestCase>
dropMigrationProcessConfigurationStatementTestCases = new LinkedList<>();
+ private final List<DropPipelineProcessConfigurationStatementTestCase>
dropMigrationProcessConfigurationStatementTestCases = new LinkedList<>();
@XmlElement(name = "migrate-table")
private final List<MigrateTableStatementTestCase> migrateTableTestCases =
new LinkedList<>();
diff --git
a/shardingsphere-test/shardingsphere-parser-test/src/main/java/org/apache/shardingsphere/test/sql/parser/parameterized/jaxb/cases/domain/statement/distsql/ral/migration/DropMigrationProcessConfigurationStatementTestCase.java
b/shardingsphere-test/shardingsphere-parser-test/src/main/java/org/apache/shardingsphere/test/sql/parser/parameterized/jaxb/cases/domain/statement/distsql/ral/migration/DropPipelineProcessConfigurationStatementTestCase.java
similarity index 89%
rename from
shardingsphere-test/shardingsphere-parser-test/src/main/java/org/apache/shardingsphere/test/sql/parser/parameterized/jaxb/cases/domain/statement/distsql/ral/migration/DropMigrationProcessConfigurationStatementTestCase.java
rename to
shardingsphere-test/shardingsphere-parser-test/src/main/java/org/apache/shardingsphere/test/sql/parser/parameterized/jaxb/cases/domain/statement/distsql/ral/migration/DropPipelineProcessConfigurationStatementTestCase.java
index 399512f43af..e606a110bdc 100644
---
a/shardingsphere-test/shardingsphere-parser-test/src/main/java/org/apache/shardingsphere/test/sql/parser/parameterized/jaxb/cases/domain/statement/distsql/ral/migration/DropMigrationProcessConfigurationStatementTestCase.java
+++
b/shardingsphere-test/shardingsphere-parser-test/src/main/java/org/apache/shardingsphere/test/sql/parser/parameterized/jaxb/cases/domain/statement/distsql/ral/migration/DropPipelineProcessConfigurationStatementTestCase.java
@@ -24,11 +24,11 @@ import
org.apache.shardingsphere.test.sql.parser.parameterized.jaxb.cases.domain
import javax.xml.bind.annotation.XmlElement;
/**
- * Drop migration process configuration test case.
+ * Drop pipeline process configuration test case.
*/
@Getter
@Setter
-public final class DropMigrationProcessConfigurationStatementTestCase extends
SQLParserTestCase {
+public final class DropPipelineProcessConfigurationStatementTestCase extends
SQLParserTestCase {
@XmlElement(name = "conf-path")
private String confPath;