Wildcards on indices upgraded to Elasticsearch 6.5 don't work correctly

We performed a rolling upgrade from Elasticsearch 5.6.7 to 6.5.0 (following the instructions reported on this page), without re-indexing any existing index.
After this upgrade, when you execute a search using a query string query with wildcards on any upgraded index, the results are incorrect:

  1. A question mark wildcard always returns all the documents;
  2. A star wildcard returns all the documents unless it is post-fixed.

For example, searching for serv?r or ?erver or serve? returns all the documents of the index; searching for serv*r or *erver returns again all the documents of the index.

Is this a known bug of Elasticsearch 6.5?
What are the possible workarounds for this issue? Re-indexing all the indices?

Can you show an example query?

For example, even using a simple URI search as the following one:
GET http://localhost:9200/alerts/_search?q=serv*r
it matches all the documents of the index alerts that was upgraded from 5.6.7 to 6.5.0 without re-indexing.

For now, I have resolved this issue by re-indexing all the indices created in Elasticsearch 5.6.7.

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