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

allow url parameters in query configuration #100

Open
piif opened this issue Mar 3, 2022 · 1 comment
Open

allow url parameters in query configuration #100

piif opened this issue Mar 3, 2022 · 1 comment

Comments

@piif
Copy link

piif commented Mar 3, 2022

Aggregation query results may be polluted by extra fields which implies many useless metrics.
To filter there fields, one may use ?filter_path= parameters to url.
Thus a query configuration options should be usefull to add this query string on called URL.

@piif
Copy link
Author

piif commented Mar 3, 2022

here is an example :
with following aggregator, the exporter will return my_query_le_doc_count and my_query_le_to :

            "aggs": {
              "le": {
                  "range": {
                    "field": "time_request",
                    "ranges": [
                        { "to":    "1", "key":    "1" },
                        { "to":    "10", "key":    "10" },
                        { "to":    "100", "key":    "100" },
                        { "from":    "100", "key":    "+Inf" }
                  ]
                }
              }

Metric my_query_le_doc_count may be use as an histogram metric and quantile function works directly on it
On the other hand, metric my_query_le_to is useless, thus i may appe,nd to the url ?filter_path=aggregations.le.buckets.key,aggregations.le.buckets.doc_count to filter out "to" field.
But the exporter has no way to specify this parameter

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

No branches or pull requests

1 participant