opensearch-project / OpenSearch

🔎 Open source distributed and RESTful search engine.
https://opensearch.org/docs/latest/opensearch/index/
Apache License 2.0
9.01k stars 1.67k forks source link

[Feature Request] Aggregations for the flat_object type #14225

Open ivanguravel opened 2 weeks ago

ivanguravel commented 2 weeks ago

Is your feature request related to a problem? Please describe

In general there is no support of the aggregations inside the OpenSearch for now. Reference is available here . Absence of this functionality is painful in case of integration OpenSearch with Grafana.

Describe the solution you'd like

It could be great something like the same functionality in ElasticSearch

Related component

Search:Aggregations

Describe alternatives you've considered

In terms of absence of this functionality there are some workarounds present. The easiest one is about reindex with moving related field for aggregation from the flat_object to keyword.

Additional context

No response

etolbakov commented 1 week ago

Just copying the message from @msfroh

the prefix-based filtering that I’m adding in https://github.com/opensearch-project/OpenSearch/pull/14371 could be used to efficiently allow terms aggregations on flat_object fields with a given path (or multiple paths).

So maybe it will resolve this issue as well