sandynz commented on code in PR #30339:
URL: https://github.com/apache/shardingsphere/pull/30339#discussion_r1505685799
##########
kernel/data-pipeline/distsql/handler/src/main/java/org/apache/shardingsphere/data/pipeline/migration/distsql/handler/update/MigrateTableExecutor.java:
##########
@@ -43,7 +43,7 @@ public final class MigrateTableExecutor implements
DistSQLUpdateExecutor<Migrate
@Override
public void executeUpdate(final MigrateTableStatement sqlStatement, final
ContextManager contextManager) {
String modeType =
contextManager.getInstanceContext().getModeConfiguration().getType();
- ShardingSpherePreconditions.checkState(!"Standalone".equals(modeType),
() -> new PipelineInvalidParameterException("Unsupported mode type of
`Standalone`"));
+ ShardingSpherePreconditions.checkState("Cluster".equals(modeType), ()
-> new PipelineInvalidParameterException("Only `Cluster` of mode type is
supported for now"));
Review Comment:
1, Could we invoke `InstanceContext.isCluster()`? Looks there's another one
`Compatible_Cluster` except `Cluster`
2, Could we put current mode type in error message?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]