Join GitHub today
GitHub is home to over 40 million developers working together to host and review code, manage projects, and build software together.Sign up
Add support for aliases in queries on _index. #46640
Previously, queries on the _index field were not able to specify index aliases. This was a regression in functionality compared to the 'indices' query, which was deprecated and removed in 6.0.
Now queries on _index can specify an alias, which is resolved to the concrete index names when we check whether an index matches. To match a remote shard target, the pattern needs to be of the form 'cluster:index' to match the fully-qualified index name. Aliases can be specified in the following query types:
There are two complexities that I was hoping to get your thoughts on:
jimczi left a comment
IMO it is ok, we need a way to ensure that we can detect remote cluster name easily otherwise any pattern could potentially match so I am +1 to introduce this breaking change. We never really documented this feature so we could also backport it to 7x ?
+1 to deprecate/remove support for regexp on the _index field. This shouldn't be needed.
I tend to see the breaking change for remote indices more as a bugfix. When we resolve remote clusters