Issues Summary:
- Repeated Data in Grafana Table Panel: Despite using
maxandmax_over_timefunctions in Prometheus queries, the Grafana table panel continues to display repeated data entries for the samemethodandpod, with different timestamps. The desired outcome is to show only the maximum value within the specified time interval for eachmethodandpodcombination. - Query Used: The current PromQL query being used is:
prometheus
复制代码
max(
max_over_time(
rate(application_timer_metrics_seconds_sum{application="$application"}[5m]) * 1000 /
rate(application_timer_metrics_seconds_count{application="$application"}[5m])
[$interval:]
)
) by (pod, method)
This query aims to compute the maximum response time for each method and pod combination by aggregating data over a specified interval.
3. Expected Behavior:
- The table should display only the maximum response time for each
methodandpodcombination within the specified interval. - There should be no repeated entries for the same
methodandpodcombination with different timestamps.
- Issues Encountered:
- The Grafana table panel displays multiple entries for the same
methodandpodcombination, each with different timestamps, despite usingmaxandmax_over_time. - Removing the “Time” column only hides the timestamps, but does not resolve the issue of repeated data.
- Additional Information:
- The current setup includes filtering by
applicationandcontroller. - The goal is to group by
podandmethodand display only the highest value per group.
Seeking Assistance:
- How can we ensure that the Grafana table panel displays only one entry per
methodandpodcombination, showing the maximum value without repeating data? - Is there an issue with the PromQL query or Grafana settings causing this repeated display?
- Are there any best practices for visualizing this kind of data in Grafana?
