From e16b38668e4a42256bb67e1f5eca54cf75fad10a Mon Sep 17 00:00:00 2001 From: "ievgen.degtiarenko" Date: Wed, 2 Jul 2025 13:25:56 +0200 Subject: [PATCH] Do not allow closed indices --- .../elasticsearch/xpack/esql/session/IndexResolver.java | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/x-pack/plugin/esql/src/main/java/org/elasticsearch/xpack/esql/session/IndexResolver.java b/x-pack/plugin/esql/src/main/java/org/elasticsearch/xpack/esql/session/IndexResolver.java index d2f79ceb1316f..66d4cccba7942 100644 --- a/x-pack/plugin/esql/src/main/java/org/elasticsearch/xpack/esql/session/IndexResolver.java +++ b/x-pack/plugin/esql/src/main/java/org/elasticsearch/xpack/esql/session/IndexResolver.java @@ -58,7 +58,7 @@ public class IndexResolver { public static final IndicesOptions FIELD_CAPS_INDICES_OPTIONS = IndicesOptions.builder() .concreteTargetOptions(IndicesOptions.ConcreteTargetOptions.ALLOW_UNAVAILABLE_TARGETS) .wildcardOptions( - IndicesOptions.WildcardOptions.builder() + IndicesOptions.WildcardOptions.builder() // .matchOpen(true) .matchClosed(false) .includeHidden(false) @@ -66,7 +66,10 @@ public class IndexResolver { .resolveAliases(true) ) .gatekeeperOptions( - IndicesOptions.GatekeeperOptions.builder().ignoreThrottled(true).allowClosedIndices(true).allowAliasToMultipleIndices(true) + IndicesOptions.GatekeeperOptions.builder() // + .ignoreThrottled(true) + .allowClosedIndices(false) + .allowAliasToMultipleIndices(true) ) .build();