Skip to content

Documentation feedback: /docs/sources/mimir/visualize/native-histograms/_index.md #11102

Open
@teyyubismayil

Description

@teyyubismayil

I’d like a recommendation on the best call order for using native histogram functions. Specifically, which of the following variants is recommended?

  1. histogram_sum(sum(rate(http_server_duration{}[5m])) by (cluster, service_namespace, service_name, http_route, http_method))
  2. sum(histogram_sum(rate(http_server_duration{}[5m]))) by (cluster, service_namespace, service_name, http_route, http_method)

I compared the execution times of these queries (also for histogram_count function) in Mimir and found that the second one is about 20% faster. However, the documentation provides the first variant as an example.

What is the reasoning behind this choice?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions