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

Switch iavl-disable-fastnode to true by default. #9432

Open
mhofman opened this issue May 31, 2024 · 0 comments
Open

Switch iavl-disable-fastnode to true by default. #9432

mhofman opened this issue May 31, 2024 · 0 comments
Labels
agoric-cosmos enhancement New feature or request state-sync state sync related

Comments

@mhofman
Copy link
Member

mhofman commented May 31, 2024

What is the Problem Being Solved?

Investigating state-sync performance on devnet, we noticed that the amount of I/O while a state-sync snapshot is being created can cause a node to fall behind. This is apparently because the commits of the cosmos DB take much longer when a significant amount of changes occurred during the block. This behavior does not happen when the fast node mode is disabled.

We do not actually read / iterate much from the DB, except during state-sync export, which is impacted negatively by fast mode, so there is no reason to have it on.

The DefaultConfig() has IAVLDisableFastNode: false

Description of the Design

In #9424 we fixed the ability to control this mode by config.

Here we would either wwitch IAVLDisableFastNode: true in DefaultConfig() or find a better way to override defaults in agoric-sdk without patching cosmos-sdk. Unfortunately the only "blessed" path appears to be passing a different config to InterceptConfigsPreRunHandler in the root cmd, but from what we understand, this only affects the generation of the config file the first time around, not the actual default if nothing is specified in the config file.

Security Considerations

None

Scaling Considerations

Supposedly this config makes sequential iteration more efficient but we have yet to observe that. So far it has only caused performance issues.

Test Plan

TBD

Upgrade Considerations

Disabling the flag on a DB where the flag was previously enabled seems safe and effective. Reenabling it would likely cause the index to be re-created, which is expensive.

@mhofman mhofman added enhancement New feature or request agoric-cosmos state-sync state sync related labels May 31, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
agoric-cosmos enhancement New feature or request state-sync state sync related
Projects
None yet
Development

No branches or pull requests

1 participant