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

[Feature]: Speedup baseapp.GetLastBlockHeight #22259

Closed
ValarDragon opened this issue Oct 14, 2024 · 0 comments · Fixed by #22305
Closed

[Feature]: Speedup baseapp.GetLastBlockHeight #22259

ValarDragon opened this issue Oct 14, 2024 · 0 comments · Fixed by #22305
Assignees

Comments

@ValarDragon
Copy link
Contributor

Summary

In Osmosis, since our upgrade to SDK v50, we have found that baseapp.GetLastBlockHeight has caused significant performance degredation in the mempool.

Image

This is coming from Skip's BlockSDK using GetLastBlockHeight internally, and baseapp using a method that requires re-computing the hash. This is quite easily mitigated performance-wise SDK side, by making the store Committer interface provide a GetLastVersion method, in addition to GetLastCommitInfo method.

Or alternatively, make the store interfaces cache the last CommitInfo rather than re-computing the hash every time.

Problem Definition

No response

Proposed Feature

Either:

  • Make the Committer interface have a GetLastVersion field
  • Make rootmulti store cache the LastCommitID and not re-compute the hash every time.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: 🥳 Done
Development

Successfully merging a pull request may close this issue.

2 participants