Skip to content
This repository has been archived by the owner on Jan 22, 2025. It is now read-only.

AcctIdx: respect disk idx mem size param #22050

Merged
merged 1 commit into from
Dec 22, 2021

Conversation

jeffwashington
Copy link
Contributor

@jeffwashington jeffwashington commented Dec 21, 2021

Problem

If clean or cache flushing gets behind, then the in-mem accounts index can grow very large since it is holding items in the cache or items with > 1 account info in memory. When the in-mem accounts index grows large, it can take ever longer to flush, resulting in poor system performance.

Summary of Changes

Respect the max size the cache is allowed to grow to.
Fixes #

@codecov
Copy link

codecov bot commented Dec 21, 2021

Codecov Report

Merging #22050 (a370c17) into master (d896ff7) will increase coverage by 0.0%.
The diff coverage is 79.3%.

@@           Coverage Diff           @@
##           master   #22050   +/-   ##
=======================================
  Coverage    81.3%    81.3%           
=======================================
  Files         517      517           
  Lines      145586   145624   +38     
=======================================
+ Hits       118445   118529   +84     
+ Misses      27141    27095   -46     

Copy link
Contributor

@brooksprumo brooksprumo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good; have a few suggestions

runtime/src/in_mem_accounts_index.rs Show resolved Hide resolved
runtime/src/in_mem_accounts_index.rs Show resolved Hide resolved
@jeffwashington jeffwashington merged commit 61cc7b1 into solana-labs:master Dec 22, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants