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

Enable change replica leaders #287

Merged
merged 11 commits into from
Apr 23, 2022

Conversation

qoo332001
Copy link
Collaborator

這支PR在專案的library中新增了可以自行更換 replica leader的功能,以及修正了 ReplicaCollie的一些bug

Copy link
Collaborator

@garyparrot garyparrot left a comment

Choose a reason for hiding this comment

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

@garyparrot
Copy link
Collaborator

https://github.com/skiptests/astraea/blob/abbdeeea95793b44c6af30a54fcdcd5c4632a4a7/README.md?plain=1#L328-L332

README.md 這邊的 topics 好像少一個 -

@qoo332001
Copy link
Collaborator Author

我還沒看完整個程式碼,下面這些部分我看不懂 @@
https://github.com/skiptests/astraea/pull/287/files?diff=split&w=1#diff-fb5374a4b587fda71a03827beb6435a53dd95b0850ec4f72fbbbf4c7b31d7281R128-R136

這邊主要是在篩選搬移"目的" broker 與 "來源" broker ,扣掉重複的之後,算出還需要搬移幾個replicas,再把可用的broker加進搬移
目的的list中

我還沒看完整個程式碼,下面這些部分我看不懂 @@
https://github.com/skiptests/astraea/pull/287/files?diff=split&w=1#diff-fb5374a4b587fda71a03827beb6435a53dd95b0850ec4f72fbbbf4c7b31d7281R256-R274

這邊如果有'UNKNOWN'出現表示會跨broker但沒有指定路徑,所以要在這邊判斷最後搬移到哪裡,如果varify被設為true,表示不會真的搬移只會先預覽,但這邊使用者沒有指定搬移目的路徑,所以無法得知跨broker後會辦搬移到哪個folder,只好維持unknow

@qoo332001 qoo332001 requested a review from garyparrot March 19, 2022 06:22
@chia7712
Copy link
Contributor

@qoo332001 感謝patch,不過我想問一下這次的修正主要是為了什麼功用嗎?這個工具是在我們自動化負載平衡還沒出來時,可以方便我們手動做搬移的工具。因此如果負載平衡工具做得完善的話,這個工具其實就該準備退休了

@qoo332001
Copy link
Collaborator Author

@chia7712

不過我想問一下這次的修正主要是為了什麼功用嗎?

這邊主要是在新增選擇replica leader的功能,因為有調整moveTo這個function的參數型態,所以有用到這個function的replicaCollie也需要修正,然後最近在測試confluent balancer有用到這個搬移工具遇到一些小問題想說順便把它修正

@chia7712 chia7712 merged commit ce6841c into opensource4you:main Apr 23, 2022
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.

3 participants