A bout early termination of search request -- track_total_hits

ref :A bout early termination of search request

GET /events/_search
{
    "size": 10,
    "sort": [ 
        { "timestamp": "desc" }
    ],
    "track_total_hits": false
}

If the search query to join other query conditions,
whether it will match the query regardless of the value of track_total_hits ? such as :

GET test4/_search
{
  "size": 100,
  "query": {
    "wildcard" : { "desc" : "x*G" }
  },
  "sort": [
    {
      "testDate": "desc"
    }
  ],
  "track_total_hits": true
}

The result looks like it does not matter if this parameter(track_total_hits) is configured

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