I am trying to collect data while a user is using the _search API and I stumbled into a tag that can be put into the search query that might simplify everything for me but I can't find enough information on it.
Does the stats tag in a _search body affect anything; like the results returned?
The only information I could find on it was this page https://www.elastic.co/guide/en/elasticsearch/client/javascript-api/current/api-reference.html and all that it states is String, String[], Boolean — Specific tag of the request for logging and statistical purposes . Is elasticsearch actually logging it somewhere?
Example of my _search request:
GET myindex/doc/_search
{
"query": {
"match_all": {}
},
"stats": ["my string of data"]
}