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

feat restrict partition num #598

Merged
merged 1 commit into from
Jan 31, 2023

Conversation

Rachelint
Copy link
Contributor

Which issue does this PR close?

Closes #

Rationale for this change

Now partition num in table partition is not restricted, you can set the partition num to an unaccpetable huge number.

What changes are included in this PR?

In this pr we make a restriction on it, it cannot be greater than MAX_PARTITION_NUM(1024 now).

Are there any user-facing changes?

User can not set a partition num greater than MAX_PARTITION_NUM while creating partitioned table.

How does this change test

Test by ut.

@codecov-commenter
Copy link

Codecov Report

Merging #598 (edf060f) into main (6d57582) will increase coverage by 3.36%.
The diff coverage is 92.30%.

@@            Coverage Diff             @@
##             main     #598      +/-   ##
==========================================
+ Coverage   62.61%   65.98%   +3.36%     
==========================================
  Files         326      285      -41     
  Lines       50232    44342    -5890     
==========================================
- Hits        31454    29257    -2197     
+ Misses      18778    15085    -3693     
Impacted Files Coverage Δ
sql/src/partition.rs 0.00% <ø> (ø)
sql/src/parser.rs 89.49% <92.30%> (+0.26%) ⬆️
server/src/grpc/storage_service/write.rs 38.99% <0.00%> (-3.67%) ⬇️
analytic_engine/src/sst/file.rs 76.17% <0.00%> (-1.09%) ⬇️
analytic_engine/src/instance/write_worker.rs 72.60% <0.00%> (-0.58%) ⬇️
analytic_engine/src/row_iter/merge.rs 88.58% <0.00%> (-0.19%) ⬇️
server/src/http.rs 0.00% <0.00%> (ø)
server/src/server.rs 0.00% <0.00%> (ø)
server/src/handlers/sql.rs 0.00% <0.00%> (ø)
server/src/mysql/worker.rs 0.00% <0.00%> (ø)
... and 45 more

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

Copy link
Contributor

@chunshao90 chunshao90 left a comment

Choose a reason for hiding this comment

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

LGTM

@chunshao90 chunshao90 merged commit 2e2cd08 into apache:main Jan 31, 2023
chunshao90 pushed a commit to chunshao90/ceresdb that referenced this pull request May 15, 2023
@Rachelint Rachelint deleted the restrict-partition-num branch May 27, 2023 12:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants