-
Notifications
You must be signed in to change notification settings - Fork 458
[server] Introduce new rebalance API #1380
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
base: main
Are you sure you want to change the base?
Conversation
367414b to
c70310a
Compare
fluss-server/src/main/java/com/alibaba/fluss/server/zk/data/RebalancePlan.java
Outdated
Show resolved
Hide resolved
ac2f7eb to
8b604e4
Compare
291382b to
edb52c5
Compare
d88c76c to
434a4f4
Compare
7ab4dcb to
a60f459
Compare
a60f459 to
f2e8744
Compare
LiebingYu
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.
Left some minor comments.
fluss-client/src/main/java/org/apache/fluss/client/admin/Admin.java
Outdated
Show resolved
Hide resolved
fluss-client/src/main/java/org/apache/fluss/client/admin/Admin.java
Outdated
Show resolved
Hide resolved
fluss-client/src/main/java/org/apache/fluss/client/admin/Admin.java
Outdated
Show resolved
Hide resolved
fluss-rpc/src/main/java/org/apache/fluss/rpc/protocol/Errors.java
Outdated
Show resolved
Hide resolved
e879be6 to
72579c8
Compare
72579c8 to
4f69637
Compare
wuchong
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.
Thanks @swuferhong , I left some comments.
fluss-client/src/main/java/org/apache/fluss/client/admin/Admin.java
Outdated
Show resolved
Hide resolved
fluss-client/src/main/java/org/apache/fluss/client/admin/Admin.java
Outdated
Show resolved
Hide resolved
fluss-common/src/main/java/org/apache/fluss/cluster/rebalance/RebalanceStatusForBucket.java
Outdated
Show resolved
Hide resolved
fluss-common/src/main/java/org/apache/fluss/cluster/rebalance/RebalanceStatusForBucket.java
Outdated
Show resolved
Hide resolved
| return getOrEmpty(path).map(RebalanceZNode::decode); | ||
| } | ||
|
|
||
| public void deleteRebalancePlan() throws Exception { |
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.
I doubt whether we should delete the rebalance node on ZK. If we delete it once the rebalance successfully finished, we don't have the ability to respond users the status of the rebalance plan.
Maybe we can just soft delete the rebalance node by mark the rebalance plan is cancelled or failed or completed (the RebalanceStatus), so listRebalanceProgress still work after the rebalance finished, and can be overriden by next rebalance task.
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.
I agree with your changes. I've removed the deleteRebalancePlan method and added a new updateRebalancePlan method. Additionally, I introduced a new field rebalance_status in the RebalancePlan. Now, each time we check the status to determine whether the rebalance has completed or already failed.
4f69637 to
9ddb717
Compare
|
@wuchong comments addressed. |
Purpose
Linked issue: #1371
This pr is aims to introduce new rebalance API. For more details, please refer to https://cwiki.apache.org/confluence/display/FLUSS/FIP-8%3A+Support+Cluster+Reblance
Brief change log
Tests
API and Format
Documentation