-
Notifications
You must be signed in to change notification settings - Fork 61
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
refactor replica migrate size moveCost #1584
refactor replica migrate size moveCost #1584
Conversation
…ctorReplicaMigrateSizeCost
不好意思,想先回頭討論一下這個題目: 現有的 所以在我的想象中,這個題目跟 另外一個要討論的則是這個題目討論的東西是否更適合放到 |
或許這邊可以把
或許可以建立一個新的 |
同意,原本的限制意義不大,可以直接改 |
資料的進出是需要分開計算的,主要是要分別算出移出/移入需要花多少時間,而分開限制移出或移入的資料量似乎是沒有必要的,這隻PR的邏輯是計算移入/移出總量找大值當移動的log size |
…ctorReplicaMigrateSizeCost
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
此PR將計算搬移資料量成本拆分成"移入"與"移出" ,如此才能表示"實際需要搬移的資料量",若是這支沒問題,未來也會把
ReplicaLeaderCost
,ReplicaNumberCost
改成類似的形式舉個例子:
一個broker在一個搬移計畫中移出5GB且移入3GB,原本的計算方式看到的成本會是 -5+3 也就是只能看到此broker的搬移成本為移出2GB,沒辦法實際得知移出多少以及移入多少,這會導致在估計搬移時間上有誤差