8000 Fix replicasAssignment Hashmap by thkevin · Pull Request #340 · linkedin/kafka-monitor · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Fix replicasAssignment Hashmap #340

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

Merged
merged 1 commit into from
Apr 19, 2021

Conversation

thkevin
Copy link
Contributor
@thkevin thkevin commented Feb 7, 2021

Hello,

This is a fix for the issue #325. (Closed but not solved).
When creating a ClusterTopicManipulationService topic, the constructor uses a Hasmap containing the brokers id for each replica partition.
The problem is that has it is, the same broker id can be repeated.
With this fix, a simple shuffle of the brokers allows a random repartition of the brokers ids.
No need for the while loop.

Thanks

@zigarn
Copy link
Contributor
zigarn commented Feb 11, 2021

With the current code we have a simple random sampling with replacement, which has no sense for a replica assignment.

@zigarn
Copy link
Contributor
zigarn commented Apr 6, 2021

Any chance to see this reviewed and integrated? @andrewchoi5 @Lincong?

Copy link
@andrewchoi5 andrewchoi5 left a comment

Choose a reason for hiding this comment

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

lgtm, would also like to have @smccauliff give a +1.

@andrewchoi5 andrewchoi5 merged commit a0f1b0f into linkedin:master Apr 19, 2021
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
0