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

Speed up status page #1142

Merged

Conversation

Ahmad-Wahid
Copy link
Contributor

Description

Used most_recent_beliefs_only=False and most_recent_only=True to speed up status page query.

How to test

@Ahmad-Wahid Ahmad-Wahid linked an issue Aug 11, 2024 that may be closed by this pull request
@Ahmad-Wahid Ahmad-Wahid self-assigned this Aug 11, 2024
@Ahmad-Wahid Ahmad-Wahid added the enhancement New feature or request label Aug 11, 2024
@nhoening nhoening added this to the 0.24.0 milestone Sep 16, 2024
@Ahmad-Wahid Ahmad-Wahid marked this pull request as ready for review September 20, 2024 17:23
Copy link
Contributor

@nhoening nhoening left a comment

Choose a reason for hiding this comment

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

Is it possible to combine the change with an assessment? From the issue:

Ideally, report back with the measured improvement on some production data dump.

@nhoening
Copy link
Contributor

I made a quick check without in-depth profiling (page with 8 sensors):

  • Before: 18.04 seconds to serve http://localhost:5000/assets/1/status
  • After: 4.59 seconds to serve http://localhost:5000/assets/1/status.

Promising. Still I believe this is a little slow, but this PR (well, the underlying work in timely-beliefs I did months ago) seems to make a notable improvement!

@Ahmad-Wahid
Copy link
Contributor Author

What should be the next step?

@nhoening
Copy link
Contributor

nhoening commented Sep 27, 2024

I would say we merge this improvement and come back for more another time.

Copy link
Contributor

@nhoening nhoening left a comment

Choose a reason for hiding this comment

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

Thanks!
Can we add a changelog entry under Bugfixes/Infrastructure?

Signed-off-by: Nicolas Höning <[email protected]>
@nhoening nhoening merged commit e62a0cf into main Sep 27, 2024
6 of 7 checks passed
@nhoening nhoening deleted the 1126-use-new-most_recent-parameter-in-status-page-to-speed-it-up branch September 27, 2024 21:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Use new most_recent parameter in status page (to speed it up)
2 participants