-
Notifications
You must be signed in to change notification settings - Fork 700
[#7185] Improvement(doris): Doris supports 'DISTRIBUTED BY HASH(columnName) BUCKETS AUTO' #7186
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
Conversation
...gs/catalog-jdbc-doris/src/main/java/org/apache/gravitino/catalog/doris/utils/DorisUtils.java
Show resolved
Hide resolved
| if (matcher.find(5)) { | ||
| bucketNum = Integer.valueOf(matcher.group(5)); | ||
| } | ||
| // Default bucket number is 1. auto is -1. |
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.
Should we also update the user doc to clarify this case?
BTW, how can a user create an auto-distributed Doris table by the Gravitino API?
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.
ok
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.
@mchades fixed , The Gravitino API can use Distributions.auto(Strategy.HASH, NamedReference.field("score"));.
c6c4af3 to
9c050ac
Compare
api/src/main/java/org/apache/gravitino/rel/expressions/distributions/Distributions.java
Outdated
Show resolved
Hide resolved
...gs/catalog-jdbc-doris/src/main/java/org/apache/gravitino/catalog/doris/utils/DorisUtils.java
Outdated
Show resolved
Hide resolved
yuqi1129
left a comment
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.
LGTM
…(columnName) BUCKETS AUTO' (apache#7186) <!-- 1. Title: [#<issue>] <type>(<scope>): <subject> Examples: - "[apache#123] feat(operator): support xxx" - "[apache#233] fix: check null before access result in xxx" - "[MINOR] refactor: fix typo in variable name" - "[MINOR] docs: fix typo in README" - "[apache#255] test: fix flaky test NameOfTheTest" Reference: https://www.conventionalcommits.org/en/v1.0.0/ 2. If the PR is unfinished, please mark this PR as draft. --> ### What changes were proposed in this pull request? Doris supports 'DISTRIBUTED BY HASH(dt_date) BUCKETS AUTO' ### Why are the changes needed? Fix: #([7185](apache#7185)) ### Does this PR introduce _any_ user-facing change? N/A ### How was this patch tested? org.apache.gravitino.catalog.doris.utils.TestDorisUtils#testDistributedInfoPattern org.apache.gravitino.catalog.doris.integration.test.CatalogDorisIT#testAllDistributionWithAuto
…(columnName) BUCKETS AUTO' (apache#7186) <!-- 1. Title: [#<issue>] <type>(<scope>): <subject> Examples: - "[apache#123] feat(operator): support xxx" - "[apache#233] fix: check null before access result in xxx" - "[MINOR] refactor: fix typo in variable name" - "[MINOR] docs: fix typo in README" - "[apache#255] test: fix flaky test NameOfTheTest" Reference: https://www.conventionalcommits.org/en/v1.0.0/ 2. If the PR is unfinished, please mark this PR as draft. --> ### What changes were proposed in this pull request? Doris supports 'DISTRIBUTED BY HASH(dt_date) BUCKETS AUTO' ### Why are the changes needed? Fix: #([7185](apache#7185)) ### Does this PR introduce _any_ user-facing change? N/A ### How was this patch tested? org.apache.gravitino.catalog.doris.utils.TestDorisUtils#testDistributedInfoPattern org.apache.gravitino.catalog.doris.integration.test.CatalogDorisIT#testAllDistributionWithAuto
What changes were proposed in this pull request?
Doris supports 'DISTRIBUTED BY HASH(dt_date) BUCKETS AUTO'
Why are the changes needed?
Fix: #(7185)
Does this PR introduce any user-facing change?
N/A
How was this patch tested?
org.apache.gravitino.catalog.doris.utils.TestDorisUtils#testDistributedInfoPattern
org.apache.gravitino.catalog.doris.integration.test.CatalogDorisIT#testAllDistributionWithAuto