Skip to content

computeScore performance issue #169

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

Closed
twoeths opened this issue Nov 30, 2021 · 1 comment · Fixed by #175
Closed

computeScore performance issue #169

twoeths opened this issue Nov 30, 2021 · 1 comment · Fixed by #175
Assignees

Comments

@twoeths
Copy link
Contributor

twoeths commented Nov 30, 2021

Motivation

  • We keep computing peer score in a lot of places without any cache
  • It's not scalable: the more messages, the more function calls we have for computeScore()(). When there are a lot of messages, it takes 4% cpu time of lodestar
    1130_lodestar_subscribeAllSubnets_local.cpuprofile.zip

Screen Shot 2021-11-30 at 13 14 38

Note

  • It's not likely it's a performance issue of computeScore() function itself
@dapplion
Copy link
Contributor

@tuyennhv I had the same though on this, we compute the scores incredibly often. You could add some quick and dirty metrics to know how many times computeScore() is called per second

@twoeths twoeths self-assigned this Dec 2, 2021
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 a pull request may close this issue.

2 participants