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

Add cache support to eth_getBalance #1059

Closed
Tracked by #1058
Nana-EC opened this issue Apr 14, 2023 · 0 comments · Fixed by #1064
Closed
Tracked by #1058

Add cache support to eth_getBalance #1059

Nana-EC opened this issue Apr 14, 2023 · 0 comments · Fixed by #1064
Assignees
Labels
enhancement New feature or request P1
Milestone

Comments

@Nana-EC
Copy link
Collaborator

Nana-EC commented Apr 14, 2023

Problem

Currently the eth_getBalance queries the Mirror Node for the latest block.
Under high load a mirror node may limit RPS

Solution

To reduce the number of calls needed and therefore the load on a mirror node a cache may be added to eth_getBalance endpoint.

Mirror Node processes a block every 2 secs, however balance is updated in realtime based off of crypto transfers so a cache of 500ms may be a fair balance between optimization and data freshness.
This should be added as a configureable property

Alternatives

No response

@Nana-EC Nana-EC added this to the 0.23.0 milestone Apr 14, 2023
@Nana-EC Nana-EC added enhancement New feature or request P1 labels Apr 14, 2023
@Nana-EC Nana-EC changed the title eth_getBalance Add cache support to eth_getBalance Apr 14, 2023
@Nana-EC Nana-EC moved this to In Review in Smart Contract Sprint Board Apr 14, 2023
@github-project-automation github-project-automation bot moved this from In Review to Done in Smart Contract Sprint Board Apr 14, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request P1
Projects
Archived in project
Development

Successfully merging a pull request may close this issue.

2 participants