|
80 | 80 | import org.elasticsearch.common.Strings;
|
81 | 81 | import org.elasticsearch.common.bytes.BytesReference;
|
82 | 82 | import org.elasticsearch.common.lucene.uid.Versions;
|
83 |
| -import org.elasticsearch.common.xcontent.DeprecationHandler; |
84 |
| -import org.elasticsearch.common.xcontent.NamedXContentRegistry; |
85 |
| -import org.elasticsearch.common.xcontent.ToXContent; |
86 |
| -import org.elasticsearch.common.xcontent.XContent; |
87 |
| -import org.elasticsearch.common.xcontent.XContentBuilder; |
88 | 83 | import org.elasticsearch.common.xcontent.XContentHelper;
|
89 |
| -import org.elasticsearch.common.xcontent.XContentParser; |
90 |
| -import org.elasticsearch.common.xcontent.XContentType; |
91 | 84 | import org.elasticsearch.core.SuppressForbidden;
|
92 | 85 | import org.elasticsearch.core.TimeValue;
|
93 | 86 | import org.elasticsearch.index.VersionType;
|
|
101 | 94 | import org.elasticsearch.script.mustache.SearchTemplateRequest;
|
102 | 95 | import org.elasticsearch.search.fetch.subphase.FetchSourceContext;
|
103 | 96 | import org.elasticsearch.tasks.TaskId;
|
| 97 | +import org.elasticsearch.xcontent.DeprecationHandler; |
| 98 | +import org.elasticsearch.xcontent.NamedXContentRegistry; |
| 99 | +import org.elasticsearch.xcontent.ToXContent; |
| 100 | +import org.elasticsearch.xcontent.XContent; |
| 101 | +import org.elasticsearch.xcontent.XContentBuilder; |
| 102 | +import org.elasticsearch.xcontent.XContentParser; |
| 103 | +import org.elasticsearch.xcontent.XContentType; |
104 | 104 | import org.springframework.data.elasticsearch.backend.elasticsearch7.client.reactive.ReactiveElasticsearchClient;
|
105 | 105 | import org.springframework.http.HttpMethod;
|
106 | 106 | import org.springframework.lang.Nullable;
|
@@ -1232,7 +1232,12 @@ Params withWaitForActiveShards(ActiveShardCount activeShardCount, ActiveShardCou
|
1232 | 1232 | return this;
|
1233 | 1233 | }
|
1234 | 1234 |
|
1235 |
| - Params withIndicesOptions(IndicesOptions indicesOptions) { |
| 1235 | + Params withIndicesOptions(@Nullable IndicesOptions indicesOptions) { |
| 1236 | + |
| 1237 | + if (indicesOptions == null) { |
| 1238 | + return this; |
| 1239 | + } |
| 1240 | + |
1236 | 1241 | withIgnoreUnavailable(indicesOptions.ignoreUnavailable());
|
1237 | 1242 | putParam("allow_no_indices", Boolean.toString(indicesOptions.allowNoIndices()));
|
1238 | 1243 | String expandWildcards;
|
|
0 commit comments