Skip to content
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

[improvement](mtmv) Improve the performance for query rewritting by materialized view #31886

Merged
merged 9 commits into from
Mar 8, 2024

Conversation

seawinde
Copy link
Contributor

@seawinde seawinde commented Mar 6, 2024

Proposed changes

  • Limit the number of times for the query rewritting to the group
  • Remove the unnecessary log and explain detail info in query

Further comments

If this is a relatively large or complex change, kick off the discussion at dev@doris.apache.org by explaining why you chose the solution you did and what alternatives you considered, etc...

@doris-robot
Copy link

Thank you for your contribution to Apache Doris.
Don't know what should be done next? See How to process your PR

@seawinde
Copy link
Contributor Author

seawinde commented Mar 6, 2024

run buildall

2 similar comments
@seawinde
Copy link
Contributor Author

seawinde commented Mar 7, 2024

run buildall

@seawinde
Copy link
Contributor Author

seawinde commented Mar 7, 2024

run buildall

@@ -1578,6 +1581,10 @@ public void setEnableLeftZigZag(boolean enableLeftZigZag) {
"whether to use a materialized view that contains the foreign table "
+ "when using rewriting based on struct info"})
public boolean materializedViewRewriteEnableContainExternalTable = false;
@VariableMgr.VarAttr(name = MATERIALIZED_VIEW_REWRITE_SUCCESS_CANDIDATE_NUM, needForward = true,
description = {"透明改写成功的结果集合,允许参与到CBO候选的最大数量",
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
description = {"透明改写成功的结果集合,允许参与到CBO候选的最大数量",
description = {"异步物化视图透明改写成功的结果集合,允许参与到CBO候选的最大数量",

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

OK,hava fixed it

@@ -150,13 +155,17 @@ public void setSuccess(boolean success) {
/**
* recordFailReason
*/
public void recordFailReason(ObjectId objectId, Pair<String, String> summaryAndReason) {
public void recordFailReason(StructInfo structInfo, Pair<String, String> summaryAndReason) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

maybe use this signature is better

Suggested change
public void recordFailReason(StructInfo structInfo, Pair<String, String> summaryAndReason) {
public void recordFailReason(StructInfo structInfo, String summary, Supplier<String> reasonSupplier) {
...
String reason = enableRecordFailureDetail ? reasonSupplier.get() : ""
...

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

have fixed it

@seawinde
Copy link
Contributor Author

seawinde commented Mar 7, 2024

run buildall

@seawinde seawinde requested a review from morrySnow March 8, 2024 02:19
@seawinde
Copy link
Contributor Author

seawinde commented Mar 8, 2024

run buildall

1 similar comment
@seawinde
Copy link
Contributor Author

seawinde commented Mar 8, 2024

run buildall

@seawinde seawinde force-pushed the performance_optimize branch from 8347f3b to d41189f Compare March 8, 2024 07:42
@seawinde
Copy link
Contributor Author

seawinde commented Mar 8, 2024

run buildall

Copy link
Contributor

github-actions bot commented Mar 8, 2024

PR approved by anyone and no changes requested.

@github-actions github-actions bot added the approved Indicates a PR has been approved by one committer. label Mar 8, 2024
Copy link
Contributor

github-actions bot commented Mar 8, 2024

PR approved by at least one committer and no changes requested.

@morrySnow morrySnow merged commit 0f013b5 into apache:master Mar 8, 2024
26 of 29 checks passed
yiguolei pushed a commit that referenced this pull request Mar 9, 2024
…aterialized view (#31886)

- Limit the number of times for the query rewritting to the group
- Remove the unnecessary log and explain detail info in query
yiguolei pushed a commit that referenced this pull request Mar 9, 2024
…aterialized view (#31886)

- Limit the number of times for the query rewritting to the group
- Remove the unnecessary log and explain detail info in query
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by one committer. reviewed
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants