-
Notifications
You must be signed in to change notification settings - Fork 3.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Enhancement] (nereids)implement showReplicaDistributionCommand in nereids #44498
Conversation
Thank you for your contribution to Apache Doris. Please clearly describe your PR:
|
1441ad8
to
4b5b7ce
Compare
private final TableNameInfo tableNameInfo; | ||
private final TableScanParams scanParams; | ||
private final TableSnapshot tableSnapShot; | ||
private final PartitionNames partitionNames; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You can use PartitionNamesInfo.java from https://github.com/apache/doris/pull/44058/files . This pr has some extra work to do and will not be merged in a short time. So you can add PartitionNamesInfo.java in your pr.
40f1d48
to
4f77dff
Compare
run buildall |
/** | ||
* show replica distribution command | ||
*/ | ||
public class ShowReplicaDistributionCommand extends ShowCommand { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
please help update the two functions in Command.java (add ConnectContext as param)
public void verifyCommandSupported(ConnectContext ctx) throws DdlException {
// check command has been supported in cloud mode
if (Config.isCloudMode()) {
checkSupportedInCloudMode(ctx);
}
}
protected void checkSupportedInCloudMode(ConnectContext ctx) throws DdlException {}
and then change the caller in StmtExecutor.java
((Command) logicalPlan).verifyCommandSupported(context);
at last, override checkSupportedInCloudMode method as bellow
protected void checkSupportedInCloudMode(ConnectContext ctx) throws DdlException {
if (!ctx.getCurrentUserIdentity().getUser().equals(Auth.ROOT_USER)) {
LOG.info("stmt={}, not supported in cloud mode", stmt.toString());
throw new AnalysisException("Unsupported operation");
}
}
a7eec1f
to
a3903bb
Compare
run buildall |
a3903bb
to
e712844
Compare
run buildall |
4e1062c
to
42452a5
Compare
run buildall |
run buildall |
1 similar comment
run buildall |
run buildall |
PR approved by at least one committer and no changes requested. |
PR approved by anyone and no changes requested. |
What problem does this PR solve?
Issue Number: close #42782
#42837
Related PR: #xxx
Problem Summary:
implement showReplicaDistributionCommand in nereids
Release note
None
Check List (For Author)
Test
Behavior changed:
Does this need documentation?
Check List (For Reviewer who merge this PR)