-
Notifications
You must be signed in to change notification settings - Fork 535
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Historian: Improve cache hits for specific summary shas (#14624)
## Description Historian caches latest summary, but it doesn't check if a requested summary version is already cached as latest. A bug in the R11s-driver was recently fixed in #14400 where the driver will request latest summary, then also request it again by its ID. This is fixed in the driver now, but will take some time to saturate clients using r11s-driver. We can lessen the impact of this bug on the server by causing that 2nd read to be a Cache Hit instead of a 100% miss. ## Breaking Changes None, but I removed a commented out section of code from #12036 and replaced it with a reference to an issue I opened to track it instead (#14623). ## Reviewer Guidance The goal here is to check if the requested summary sha is the same as the cached latest summary sha. However, we do not want to read the entire summary from cache into memory just to read its sha, in case it is not a cache hit. Instead, I added an additional cache key which will store specifically the cached latest summary's sha, which will improve efficiency of the sha equality check.
- Loading branch information
Showing
1 changed file
with
75 additions
and
35 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters