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

[MAIN-2169] Prometheus preformance fix #1563

Merged
merged 10 commits into from
Sep 25, 2024
Merged

Conversation

Avi-Robusta
Copy link
Contributor

@Avi-Robusta Avi-Robusta commented Sep 19, 2024

We updated prometrix for faster preformance.
https://pypi.org/project/prometrix/0.2.0/

There were issues with speed and cpu when serialising the Hikaru object.
you can see the speed improvements here

As you can see it is used practically in the same way but now needs some slight changes

  • dict(block.data) to de-serialise it
  • the sub objects from PrometheusQueryResult are all treated as a dict object
    • i.e instead of query_result.vector_result[0].value we need to use query_result.vector_result[0]["value"]

Tests ran

  • UI - (krr, nodes, metrics exporter, apps page + apps custom graphs)
  • DB - (verified the node average usage query reports correct data to DB)
  • Actions - actions impacted - prometheus_sla_enricher - graph enrichers like node_graph_enricher

pyproject.toml Outdated Show resolved Hide resolved
Base automatically changed from remove-hikaru-from-pods-list to master September 23, 2024 06:18
@Avi-Robusta Avi-Robusta changed the title [DONT MERGE] Prometheus preformance fix - Needs new prometrix release before merge [MAIN-2169] Prometheus preformance fix Sep 23, 2024
Copy link
Contributor

@arikalon1 arikalon1 left a comment

Choose a reason for hiding this comment

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

nice work

left some comments

@Avi-Robusta
Copy link
Contributor Author

Copy link
Contributor

@arikalon1 arikalon1 left a comment

Choose a reason for hiding this comment

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

nice work

@arikalon1 arikalon1 merged commit d937c5b into master Sep 25, 2024
5 checks passed
@arikalon1 arikalon1 deleted the prometheus_preformance_fix branch September 25, 2024 11:49
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 this pull request may close these issues.

2 participants