Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Uses file io as default method to access account storages #4365

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

brooksprumo
Copy link

Problem

Account storages can be accessed via mmap or file io. The default is mmap, but @alessandrod has used his profiler to show this is bad for performance.

Summary of Changes

Set the default account storage access method to be file io. Node operators can still opt back to mmaps with --accounts-db-access-storages-method mmap.

The file io impl has been in the validator for many releases and has been running on various canaries/dev boxes/pop-net clusters for a while. I haven't observed any correctness issues. My metrics show replay perf isn't degraded. Alessandro may be able to add more details from profiler results as well.

/// ancient storages are created by 1-shot write to pack multiple accounts together more efficiently with new formats
#[default]
Copy link

Choose a reason for hiding this comment

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

yuck. config defaults like this should be made in the cli config, not pervade the codebase

@brooksprumo brooksprumo self-assigned this Jan 9, 2025
@brooksprumo brooksprumo marked this pull request as ready for review January 10, 2025 02:07
Copy link

@jeffwashington jeffwashington left a comment

Choose a reason for hiding this comment

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

lgtm

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants