Copilot commented on code in PR #60263:
URL: https://github.com/apache/doris/pull/60263#discussion_r2730767118
##########
fe/fe-core/src/main/java/org/apache/doris/nereids/trees/plans/commands/AdminSetPartitionVersionCommand.java:
##########
@@ -99,4 +100,9 @@ private void checkProperties() throws AnalysisException {
throw new AnalysisException("Unknown properties: " +
properties.keySet());
}
}
+
+ @Override
+ protected void checkSupportedInCloudMode(ConnectContext ctx) throws
DdlException {
+ throw new DdlException("Unsupported operation");
Review Comment:
This change introduces new cloud-mode behavior (command becomes unsupported
via `checkSupportedInCloudMode`). There are existing unit tests for this
command (e.g.
`fe/fe-core/src/test/java/org/apache/doris/nereids/trees/plans/commands/AdminSetPartitionVersionCommandTest.java`),
but none assert the cloud-mode rejection path. Please add a test that sets
`Config.deploy_mode` (or `cloud_unique_id`) to enable cloud mode and verifies
`verifyCommandSupported(...)` (or the statement execution path) throws
`DdlException`.
##########
fe/fe-core/src/main/java/org/apache/doris/nereids/trees/plans/commands/AdminSetPartitionVersionCommand.java:
##########
@@ -99,4 +100,9 @@ private void checkProperties() throws AnalysisException {
throw new AnalysisException("Unknown properties: " +
properties.keySet());
}
}
+
+ @Override
+ protected void checkSupportedInCloudMode(ConnectContext ctx) throws
DdlException {
+ throw new DdlException("Unsupported operation");
+ }
Review Comment:
`checkSupportedInCloudMode` overrides in this package consistently log that
the command is not supported in cloud mode before throwing (e.g.
`AdminCheckTabletsCommand` logs at
fe/fe-core/src/main/java/org/apache/doris/nereids/trees/plans/commands/AdminCheckTabletsCommand.java:100-103).
Consider adding a `private static final Logger LOG` and a
`LOG.info("AdminSetPartitionVersionCommand not supported in cloud mode")` here
for operational visibility before throwing.
--
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]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]