[SERVER-77703] Replace MurmurHash3 with absl::Hash if possible in oplog_applier_utils.cpp Created: 01/Jun/23  Updated: 29/Oct/23  Resolved: 22/Jun/23

Status: Closed
Project: Core Server
Component/s: None
Affects Version/s: None
Fix Version/s: 7.1.0-rc0, 7.0.0-rc6

Type: Task Priority: Major - P3
Reporter: Dan Larkin-York Assignee: Wenbin Zhu
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Backports
Depends
is depended on by SERVER-78302 Add micro-benchmark for getWriterId()... Closed
Related
related to SERVER-78126 For specific kinds of input, mongo::V... Closed
Assigned Teams:
Service Arch
Backwards Compatibility: Fully Compatible
Backport Requested:
v7.0
Sprint: Service Arch 2023-06-26
Participants:

 Description   

MurmurHash3 is a pretty old hash function that's slow and produces low-quality hashes compared to modern alternatives like absl::Hash (CityHash). We want to replace any uses of MurmurHash3 which are for in-memory use only, as we expect this to yield quick perf wins. Hash values that are persisted to disk across restarts or sent across the network between servers are likely unsafe to change, and should be annotated with a clear explanation for why the usage requires a stable hash computation.



 Comments   
Comment by Githook User [ 22/Jun/23 ]

Author:

{'name': 'Wenbin Zhu', 'email': 'wenbin.zhu@mongodb.com', 'username': 'WenbinZhu'}

Message: SERVER-77703 Replace MurmurHash3 with absl::Hash when determining the ID of applier thread.
Branch: v7.0
https://github.com/mongodb/mongo/commit/81bfc5c48d331e6aa84b07b3810595a0c3f6fcd0

Comment by Githook User [ 22/Jun/23 ]

Author:

{'name': 'Wenbin Zhu', 'email': 'wenbin.zhu@mongodb.com', 'username': 'WenbinZhu'}

Message: SERVER-77703 Replace MurmurHash3 with absl::Hash when determining the ID of applier thread.
Branch: master
https://github.com/mongodb/mongo/commit/b2c78aafaead96bdb826bf4a423214fe52f72804

Comment by Dan Larkin-York [ 13/Jun/23 ]

blake.oler@mongodb.com It definitely depends on the size of the data being hashed. You can find some results for hashing field names of different lengths in this PR.

Generated at Thu Feb 08 06:36:20 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.