You are viewing a plain text version of this content. The canonical link for it is here.
Posted to jira@kafka.apache.org by "ppatierno (via GitHub)" <gi...@apache.org> on 2026/05/03 12:54:50 UTC
[PR] Caching immutable voterKeys [kafka]
ppatierno opened a new pull request, #22198:
URL: https://github.com/apache/kafka/pull/22198
The `voters` field within the `VoterSet` is final an initialized within the constructor only and never changes.
The `voterKeys()` method is called several times and it always computes the mapping and the collection from the `voters` field on each call creating stream overhead and allocating a new HashSet. Unless I am missing anything it seems to be useless.
This PR changes such behaviour computing an immutable HashSet `voterKeys` one time in the constructor.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: jira-unsubscribe@kafka.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Caching immutable voterKeys [kafka]
Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on PR #22198:
URL: https://github.com/apache/kafka/pull/22198#issuecomment-4514978784
A label of 'needs-attention' was automatically added to this PR in order to raise the
attention of the committers. Once this issue has been triaged, the `triage` label
should be removed to prevent this automation from happening again.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: jira-unsubscribe@kafka.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Caching immutable voterKeys [kafka]
Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on PR #22198:
URL: https://github.com/apache/kafka/pull/22198#issuecomment-4417609415
A label of 'needs-attention' was automatically added to this PR in order to raise the
attention of the committers. Once this issue has been triaged, the `triage` label
should be removed to prevent this automation from happening again.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: jira-unsubscribe@kafka.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] MINOR: Caching immutable voterKeys [kafka]
Posted by "mimaison (via GitHub)" <gi...@apache.org>.
mimaison merged PR #22198:
URL: https://github.com/apache/kafka/pull/22198
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: jira-unsubscribe@kafka.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] MINOR: Caching immutable voterKeys [kafka]
Posted by "ppatierno (via GitHub)" <gi...@apache.org>.
ppatierno commented on PR #22198:
URL: https://github.com/apache/kafka/pull/22198#issuecomment-4727446461
@mimaison @showuon can you find some time to take a look at this please? Thanks!
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: jira-unsubscribe@kafka.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] MINOR: Caching immutable voterKeys [kafka]
Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on PR #22198:
URL: https://github.com/apache/kafka/pull/22198#issuecomment-4551335793
A label of 'needs-attention' was automatically added to this PR in order to raise the
attention of the committers. Once this issue has been triaged, the `triage` label
should be removed to prevent this automation from happening again.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: jira-unsubscribe@kafka.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org