Find the number of search requests per day hitting ES Cluster

Is there a way to know the (average) number of search requests per day hitting the Elasticsearch cluster?

If my ES cluster contains day-wise indices and I want find the no of search requests that hit ES cluster in last 16 days, then

GET <my_index_prefix>-2022-08-2*,<my_index_prefix>-2022-08-3*,<my_index_prefix>-2022-09-*/_stats/search?filter_path=_all.total.search.fetch_total,_all.total.search.query_total.

It's output:

{
  "_all" : {
    "total" : {
      "search" : {
        "query_total" : 5567,
        "fetch_total" : 976
      }
    }
  }
}

Perform summation of query_total with fetch_total which would give 5567 + 976 = 6543.

Since this was for 16 days, per day would be approx 6543/16 = 408 search requests per day.

Is this the correct approach?

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.