Browse Source
Prior to this commit, `SimpleKey` would be used in Spring Framework's caching support and its `hashCode` value would be used to efficiently store this key in data structures. While the current hashcode strategy works, the resulting values don't spread well enough when input keys are sequential (which is often the case). This can have negative performance impacts, depending on the data structures used by the cache implementation. This commit improves the `hashCode` function with a mixer to better spread the hash values. This is using the mixer function from the MurMur3 hash algorithm. Closes gh-34483pull/34492/head
1 changed files with 15 additions and 3 deletions
Loading…
Reference in new issue