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

Pyroscope: Add query range to ProfileTypes API call #79574

Closed
wants to merge 1 commit into from

Conversation

aleks-p
Copy link
Contributor

@aleks-p aleks-p commented Dec 15, 2023

What is this feature?

This change makes the Pyroscope user experience more consistent by making sure the query interval is included in requests to fetch available profile types.

Why do we need this feature?

The feature solves 2 problems:

  1. The user sees an accurate list of available profile types
  2. The Pyroscope backend (querier) can improve the query execution knowing the interval

Who is this feature for?

Users of the Pyroscope datasource in Grafana.

Special notes for your reviewer:

See grafana/pyroscope#2852 for a related Pyroscope change

Please check that:

  • It works as expected from a user's perspective.
  • If this is a pre-GA feature, it is behind a feature toggle.
  • The docs are updated, and if this is a notable improvement, it's added to our What's New doc.

@aleks-p aleks-p requested review from a team as code owners December 15, 2023 12:38
@aleks-p aleks-p requested review from Clarity-89 and L-M-K-B and removed request for a team December 15, 2023 12:38
@grafana-delivery-bot grafana-delivery-bot bot added this to the 10.3.x milestone Dec 15, 2023
Comment on lines +58 to +60
const end = Date.now();
const start = end - 24 * 60 * 60 * 1000; // 1 day ago
dataSource.getProfileTypes(start, end).then((profileTypes) => {
Copy link
Contributor Author

Choose a reason for hiding this comment

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

@joey-grafana I am not entirely sure if this is a good thing to do and what its impact is

@aleks-p
Copy link
Contributor Author

aleks-p commented Jan 2, 2024

Closing as it overlaps with #77523. @bryanhuhta will merge a few improvements into the original PR.

@aleks-p aleks-p closed this Jan 2, 2024
@grafana-delivery-bot grafana-delivery-bot bot removed this from the 10.3.x milestone Jan 2, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant