lhotari opened a new pull request, #21107:
URL: https://github.com/apache/pulsar/pull/21107
Fixes #21106
### Motivation
- Fix a bug in ConcurrentLongLongPairHashMap, ConcurrentLongPairSet and
ConcurrentOpenHashMap where the hash bucket's storage index was incorrectly
calculated.
- the impact of the bug has been that the implementations have been rather
unoptimal because of of frequent collisions in storing the item to the
underlying array. Essentially the hash bucket algorithm hasn't been properly
used.
### Modifications
- rename `bucket` to `bucketIndex` to indicate that it's the bucket index in
the storage array that needs to be calculated.
- calculate bucketIndex by multiplying the hash bucket by the item size (4
or 2).
### Documentation
<!-- DO NOT REMOVE THIS SECTION. CHECK THE PROPER BOX ONLY. -->
- [ ] `doc` <!-- Your PR contains doc changes. -->
- [ ] `doc-required` <!-- Your PR changes impact docs and you will update
later -->
- [x] `doc-not-needed` <!-- Your PR changes do not impact docs -->
- [ ] `doc-complete` <!-- Docs have been already added -->
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]