Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
remove the event cache initial size and refactor putInternal (#4698)
<!-- Describe what has changed in this PR --> **What changed?** remove the cache initial size from lru cache and related configs. also refactor putInternal to better support different scenarios. and added more unittests for cache size. <!-- Tell your future self why have you made these changes --> **Why?** in #4621 I change the history cache to use item bytes instead item count. However it accidentally touched default number of key when cache initialized <!-- How have you verified this change? Tested locally? Added a unit test? Checked in staging env? --> **How did you test it?** unittest <!-- Assuming the worst case, what can be broken when deploying this change to production? --> **Potential risks** Memory usage increase and pined mutable state will never leave the cache, which cause block workflow. <!-- Is this PR a hotfix candidate or require that a notification be sent to the broader community? (Yes/No) --> **Is hotfix candidate?**
- Loading branch information
1 parent
a3a4ac5
commit a608721
Showing
20 changed files
with
318 additions
and
93 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
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
Oops, something went wrong.