From bc7641fc19e50c6319ed0633cc5e1e538c1075c1 Mon Sep 17 00:00:00 2001 From: Laura Trotta Date: Fri, 18 Jul 2025 14:09:29 +0200 Subject: [PATCH 1/5] bump version --- config/version.txt | 2 +- .../java/co/elastic/clients/transport/VersionInfo.java | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/config/version.txt b/config/version.txt index 77063fc9e..48e97c8f8 100644 --- a/config/version.txt +++ b/config/version.txt @@ -1 +1 @@ -9.0.4 +9.0.5 diff --git a/java-client/src/main-flavored/java/co/elastic/clients/transport/VersionInfo.java b/java-client/src/main-flavored/java/co/elastic/clients/transport/VersionInfo.java index 89da0b3f0..e68fc6daf 100644 --- a/java-client/src/main-flavored/java/co/elastic/clients/transport/VersionInfo.java +++ b/java-client/src/main-flavored/java/co/elastic/clients/transport/VersionInfo.java @@ -21,5 +21,5 @@ // Package private class VersionInfo { - static final String VERSION = "9.0.4"; + static final String VERSION = "9.0.5"; } From 8ac49dd13c53d5e5beb2ffb7519e811530807ea1 Mon Sep 17 00:00:00 2001 From: Laura Trotta Date: Fri, 18 Jul 2025 14:24:58 +0200 Subject: [PATCH 2/5] release notes 9.0.4 --- docs/release-notes/9-0-4.md | 31 +++++++++++++++++++++++++++++++ docs/release-notes/toc.yml | 1 + 2 files changed, 32 insertions(+) create mode 100644 docs/release-notes/9-0-4.md diff --git a/docs/release-notes/9-0-4.md b/docs/release-notes/9-0-4.md new file mode 100644 index 000000000..7a113f693 --- /dev/null +++ b/docs/release-notes/9-0-4.md @@ -0,0 +1,31 @@ +--- +navigation_title: "9.0.4" +--- +# Elasticsearch Java Client 9.0.4 [elasticsearch-java-client-904] + +Discover what changed in the 9.0.4 version of the java client. + +### Features and enhancements [elasticsearch-java-client-900-features-enhancements] + +::::{dropdown} Added callbacks to Rest5Client builder +Rest5ClientBuilder now has the same level of in depth configuration the Legacy RestClientBuilder has, allowing to customize the underlying Apache HttpClient through callback functions; for example, this is how to configure the IOReactor's thread count: +```java +Rest5ClientBuilder builder = Rest5Client + .builder(new HttpHost("localhost", 9200)) + .setHttpClientConfigCallback(c -> c + .setIOReactorConfig(IOReactorConfig.custom() + .setIoThreadCount(1).build() + ) + ); +``` +And this is how to customize the response timeout: +```java +Rest5ClientBuilder builder = Rest5Client + .builder(new HttpHost("localhost", 9200)) + .setRequestConfigCallback(r -> r + .setConnectTimeout(Timeout.of(5000, TimeUnit.MILLISECONDS)) + .setResponseTimeout(Timeout.of(30000, TimeUnit.MILLISECONDS)) + .build() + ); +``` +:::: diff --git a/docs/release-notes/toc.yml b/docs/release-notes/toc.yml index 73ad0ca9a..7280720d6 100644 --- a/docs/release-notes/toc.yml +++ b/docs/release-notes/toc.yml @@ -2,3 +2,4 @@ toc: - file: index.md - file: known-issues.md - file: 9-0-0.md + - file: 9-0-4.md From 5619730e1d2c109e04025d5f87ecb860c87e4e20 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Mon, 11 Aug 2025 17:45:00 +0200 Subject: [PATCH 3/5] Safe response consumer for rest5client (#1049) (#1050) * safe response consumer for rest5client * unused import Co-authored-by: Laura Trotta <153528055+l-trotta@users.noreply.github.com> --- .../rest5_client/Rest5ClientOptions.java | 2 +- .../rest5_client/SafeResponseConsumer.java | 137 +++++++++++++++ .../low_level/SafeResponseConsumerTest.java | 158 ++++++++++++++++++ 3 files changed, 296 insertions(+), 1 deletion(-) create mode 100644 java-client/src/main/java/co/elastic/clients/transport/rest5_client/SafeResponseConsumer.java create mode 100644 java-client/src/test/java/co/elastic/clients/transport/rest5_client/low_level/SafeResponseConsumerTest.java diff --git a/java-client/src/main/java/co/elastic/clients/transport/rest5_client/Rest5ClientOptions.java b/java-client/src/main/java/co/elastic/clients/transport/rest5_client/Rest5ClientOptions.java index 0e553088a..6135a6738 100644 --- a/java-client/src/main/java/co/elastic/clients/transport/rest5_client/Rest5ClientOptions.java +++ b/java-client/src/main/java/co/elastic/clients/transport/rest5_client/Rest5ClientOptions.java @@ -209,7 +209,7 @@ public Rest5ClientOptions build() { } static Rest5ClientOptions initialOptions() { - return new Rest5ClientOptions(RequestOptions.DEFAULT, false); + return new Rest5ClientOptions(SafeResponseConsumer.DEFAULT_REQUEST_OPTIONS, false); } private static RequestOptions.Builder addBuiltinHeaders(RequestOptions.Builder builder) { diff --git a/java-client/src/main/java/co/elastic/clients/transport/rest5_client/SafeResponseConsumer.java b/java-client/src/main/java/co/elastic/clients/transport/rest5_client/SafeResponseConsumer.java new file mode 100644 index 000000000..69fccfdfe --- /dev/null +++ b/java-client/src/main/java/co/elastic/clients/transport/rest5_client/SafeResponseConsumer.java @@ -0,0 +1,137 @@ +/* + * Licensed to Elasticsearch B.V. under one or more contributor + * license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright + * ownership. Elasticsearch B.V. licenses this file to you under + * the Apache License, Version 2.0 (the "License"); you may + * not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +package co.elastic.clients.transport.rest5_client; + +import co.elastic.clients.transport.rest5_client.low_level.HttpAsyncResponseConsumerFactory; +import co.elastic.clients.transport.rest5_client.low_level.RequestOptions; +import org.apache.hc.core5.concurrent.FutureCallback; +import org.apache.hc.core5.http.EntityDetails; +import org.apache.hc.core5.http.Header; +import org.apache.hc.core5.http.HttpResponse; +import org.apache.hc.core5.http.nio.AsyncResponseConsumer; +import org.apache.hc.core5.http.nio.CapacityChannel; +import org.apache.hc.core5.http.protocol.HttpContext; + +import java.nio.ByteBuffer; +import java.util.List; + +/** + * A response consumer that will propagate Errors as RuntimeExceptions to avoid crashing the IOReactor. + */ +public class SafeResponseConsumer implements AsyncResponseConsumer { + + private final AsyncResponseConsumer delegate; + + public SafeResponseConsumer(AsyncResponseConsumer delegate) { + this.delegate = delegate; + } + + /** + * A consumer factory that safely wraps the one provided by {@code RequestOptions.DEFAULT}. + */ + public static final HttpAsyncResponseConsumerFactory DEFAULT_FACTORY = () -> new SafeResponseConsumer<>( + RequestOptions.DEFAULT.getHttpAsyncResponseConsumerFactory().createHttpAsyncResponseConsumer() + ); + + /** + * Same as {@code RequestOptions.DEFAULT} with a safe consumer factory + */ + public static final RequestOptions DEFAULT_REQUEST_OPTIONS = RequestOptions.DEFAULT + .toBuilder() + .setHttpAsyncResponseConsumerFactory(DEFAULT_FACTORY) + .build(); + + @SuppressWarnings("unchecked") + private static void throwUnchecked(Throwable thr) throws T { + throw (T) thr; + } + + @Override + public void consumeResponse(HttpResponse response, EntityDetails entityDetails, HttpContext context, + FutureCallback resultCallback) { + try { + delegate.consumeResponse(response, entityDetails, context, resultCallback); + } catch (Exception e) { + throwUnchecked(e); + } catch (Throwable e) { + throw new RuntimeException("Error consuming response", e); + } + } + + @Override + public void informationResponse(HttpResponse response, HttpContext context) { + try { + delegate.informationResponse(response, context); + } catch (Exception e) { + throwUnchecked(e); + } catch (Throwable e) { + throw new RuntimeException("Error information response", e); + } + } + + @Override + public void failed(Exception cause) { + try { + delegate.failed(cause); + } catch (Exception e) { + throwUnchecked(e); + } catch (Throwable e) { + throw new RuntimeException("Error handling failure", e); + } + } + + @Override + public void updateCapacity(CapacityChannel capacityChannel) { + try { + delegate.updateCapacity(capacityChannel); + } catch (Exception e) { + throwUnchecked(e); + } catch (Throwable e) { + throw new RuntimeException("Error updating capacity", e); + } + } + + @Override + public void consume(ByteBuffer src) { + try { + delegate.consume(src); + } catch (Exception e) { + throwUnchecked(e); + } catch (Throwable e) { + throw new RuntimeException("Error consuming data", e); + } + } + + @Override + public void streamEnd(List trailers) { + try { + delegate.streamEnd(trailers); + } catch (Exception e) { + throwUnchecked(e); + } catch (Throwable e) { + throw new RuntimeException("Error triggering stream end", e); + } + } + + @Override + public void releaseResources() { + delegate.releaseResources(); + } +} diff --git a/java-client/src/test/java/co/elastic/clients/transport/rest5_client/low_level/SafeResponseConsumerTest.java b/java-client/src/test/java/co/elastic/clients/transport/rest5_client/low_level/SafeResponseConsumerTest.java new file mode 100644 index 000000000..d22f1fbc9 --- /dev/null +++ b/java-client/src/test/java/co/elastic/clients/transport/rest5_client/low_level/SafeResponseConsumerTest.java @@ -0,0 +1,158 @@ +/* + * Licensed to Elasticsearch B.V. under one or more contributor + * license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright + * ownership. Elasticsearch B.V. licenses this file to you under + * the Apache License, Version 2.0 (the "License"); you may + * not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +package co.elastic.clients.transport.rest5_client.low_level; + +import co.elastic.clients.transport.rest5_client.SafeResponseConsumer; +import com.sun.net.httpserver.HttpServer; +import org.apache.hc.core5.http.ContentType; +import org.apache.hc.core5.http.HttpHost; +import org.apache.hc.core5.http.HttpResponse; +import org.apache.hc.core5.http.io.entity.ByteArrayEntity; +import org.apache.hc.core5.http.message.BasicClassicHttpResponse; +import org.apache.hc.core5.http.protocol.HttpContext; +import org.junit.jupiter.api.AfterAll; +import org.junit.jupiter.api.Assertions; +import org.junit.jupiter.api.BeforeAll; +import org.junit.jupiter.api.Test; + +import java.net.InetAddress; +import java.net.InetSocketAddress; +import java.nio.charset.StandardCharsets; + +public class SafeResponseConsumerTest { + + static HttpServer Server; + static HttpHost ESHost; + + // A consumer factory that throws an Error, to simulate the effect of an OOME + static HttpAsyncResponseConsumerFactory FailingConsumerFactory = + () -> new BasicAsyncResponseConsumer(new BufferedByteConsumer(100 * 1024 * 1024)) { + @Override + public void informationResponse(HttpResponse response, HttpContext context) { + super.informationResponse(response, context); + } + + @Override + protected BasicClassicHttpResponse buildResult(HttpResponse response, ByteArrayEntity entity, + ContentType contentType) { + super.buildResult(response, entity, contentType); + throw new Error("Error in buildResult"); + } + }; + + @BeforeAll + public static void setup() throws Exception { + Server = HttpServer.create(new InetSocketAddress(InetAddress.getLoopbackAddress(), 0), 0); + Server.start(); + + Server.createContext("/", exchange -> { + String path = exchange.getRequestURI().getPath(); + exchange.getResponseHeaders().set("Content-Type", "application/json"); + exchange.getResponseHeaders().set("X-Elastic-Product", "Elasticsearch"); + + if (path.equals("/")) { + byte[] bytes = Info.getBytes(StandardCharsets.UTF_8); + exchange.sendResponseHeaders(200, bytes.length); + exchange.getResponseBody().write(bytes); + exchange.close(); + return; + } + + exchange.sendResponseHeaders(404, -1); + exchange.close(); + }); + + Runtime.getRuntime().addShutdownHook(new Thread(() -> { + try { + Server.stop(1); + } catch (Exception e) { + // Ignore + } + })); + + ESHost = new HttpHost(Server.getAddress().getAddress(), Server.getAddress().getPort()); + } + + @AfterAll + public static void tearDown() { + Server.stop(0); + } + + // testReactorDeath cannot be tested, as the io reactor thread gets stuck and the test never completes + + @Test + public void testReactorSurvival() throws Exception { + + // Request options that will simulate an OOME and wrapped in the safe consumer that will + // avoid the reactor's death + RequestOptions.Builder protectedFailingOptionsBuilder = RequestOptions.DEFAULT.toBuilder(); + protectedFailingOptionsBuilder.setHttpAsyncResponseConsumerFactory(() -> + new SafeResponseConsumer<>(FailingConsumerFactory.createHttpAsyncResponseConsumer()) + ); + RequestOptions protectedFailingOptions = protectedFailingOptionsBuilder.build(); + + Rest5Client restClient = Rest5Client.builder(ESHost).build(); + + // First request, to warm things up. + // An "indice exists" request, that has no response body + Request existsReq = new Request("HEAD", "/index-name"); + restClient.performRequest(existsReq); + + try { + Request infoReq = new Request("GET", "/"); + infoReq.setOptions(protectedFailingOptions); + + restClient.performRequest(infoReq); + Assertions.fail("First request should not succeed"); + } catch (Exception t) { + System.err.println("Request 1 error"); + } + { + // 2nd request with no specific options + Request infoReq = new Request("GET", "/"); + + Response resp = restClient.performRequest(infoReq); + Assertions.assertEquals(200, resp.getStatusCode()); + } + { + // final request to make sure that the reactor isn't closed + restClient.performRequest(existsReq); + } + restClient.close(); + } + + private static final String Info = "{\n" + + " \"cluster_name\": \"foo\",\n" + + " \"cluster_uuid\": \"bar\",\n" + + " \"version\": {\n" + + " \"build_date\": \"2022-01-28T08:36:04.875279988Z\",\n" + + " \"minimum_wire_compatibility_version\": \"6.8.0\",\n" + + " \"build_hash\": \"bee86328705acaa9a6daede7140defd4d9ec56bd\",\n" + + " \"number\": \"7.17.0\",\n" + + " \"lucene_version\": \"8.11.1\",\n" + + " \"minimum_index_compatibility_version\": \"6.0.0-beta1\",\n" + + " \"build_flavor\": \"default\",\n" + + " \"build_snapshot\": false,\n" + + " \"build_type\": \"docker\"\n" + + " },\n" + + " \"name\": \"instance-0000000000\",\n" + + " \"tagline\": \"You Know, for Search\"\n" + + "}"; +} From 3d86b74a98db0aeca6cdba81edbfac8dfde85b8d Mon Sep 17 00:00:00 2001 From: Laura Trotta Date: Tue, 12 Aug 2025 15:02:10 +0200 Subject: [PATCH 4/5] [codegen] update to latest spec --- .../ElasticsearchAsyncClient.java | 4 +- .../elasticsearch/ElasticsearchClient.java | 4 +- .../_types/ElasticsearchVersionInfo.java | 10 ++ .../DateHistogramAggregation.java | 1 + .../_types/aggregations/FiltersBucket.java | 39 ++++++ .../aggregations/HistogramAggregation.java | 1 + .../aggregations/MultiTermsAggregation.java | 1 + .../_types/aggregations/TermsAggregation.java | 1 + .../_types/mapping/TypeMapping.java | 1 + .../async_search/SubmitRequest.java | 1 + .../elasticsearch/core/InfoRequest.java | 4 +- .../elasticsearch/core/SearchRequest.java | 1 + .../core/search/SearchRequestBody.java | 1 + .../elasticsearch/doc-files/api-spec.html | 125 +++++++++--------- .../elasticsearch/esql/QueryRequest.java | 8 ++ .../fleet/FleetSearchRequest.java | 1 + .../indices/DeleteAliasResponse.java | 8 +- .../indices/PutMappingRequest.java | 1 + .../IndicesAliasesResponseBody.java | 115 ++++++++++++++++ .../elasticsearch/watcher/ChainInput.java | 1 + 20 files changed, 259 insertions(+), 69 deletions(-) create mode 100644 java-client/src/main/java/co/elastic/clients/elasticsearch/indices/delete_alias/IndicesAliasesResponseBody.java diff --git a/java-client/src/main/java/co/elastic/clients/elasticsearch/ElasticsearchAsyncClient.java b/java-client/src/main/java/co/elastic/clients/elasticsearch/ElasticsearchAsyncClient.java index c0ec75865..88f124c04 100644 --- a/java-client/src/main/java/co/elastic/clients/elasticsearch/ElasticsearchAsyncClient.java +++ b/java-client/src/main/java/co/elastic/clients/elasticsearch/ElasticsearchAsyncClient.java @@ -3284,7 +3284,9 @@ public final CompletableFuture index( // ----- Endpoint: info /** - * Get cluster info. Get basic build, version, and cluster information. + * Get cluster info. Get basic build, version, and cluster information. ::: In + * Serverless, this API is retained for backward compatibility only. Some + * response fields, such as the version number, should be ignored. * * @see Documentation diff --git a/java-client/src/main/java/co/elastic/clients/elasticsearch/ElasticsearchClient.java b/java-client/src/main/java/co/elastic/clients/elasticsearch/ElasticsearchClient.java index 91fcfba08..96e290446 100644 --- a/java-client/src/main/java/co/elastic/clients/elasticsearch/ElasticsearchClient.java +++ b/java-client/src/main/java/co/elastic/clients/elasticsearch/ElasticsearchClient.java @@ -3304,7 +3304,9 @@ public final IndexResponse index( // ----- Endpoint: info /** - * Get cluster info. Get basic build, version, and cluster information. + * Get cluster info. Get basic build, version, and cluster information. ::: In + * Serverless, this API is retained for backward compatibility only. Some + * response fields, such as the version number, should be ignored. * * @see Documentation diff --git a/java-client/src/main/java/co/elastic/clients/elasticsearch/_types/ElasticsearchVersionInfo.java b/java-client/src/main/java/co/elastic/clients/elasticsearch/_types/ElasticsearchVersionInfo.java index df9708ec0..7c4a66b87 100644 --- a/java-client/src/main/java/co/elastic/clients/elasticsearch/_types/ElasticsearchVersionInfo.java +++ b/java-client/src/main/java/co/elastic/clients/elasticsearch/_types/ElasticsearchVersionInfo.java @@ -181,6 +181,11 @@ public final String minimumWireCompatibilityVersion() { /** * Required - The Elasticsearch version number. *

+ * ::: IMPORTANT: For Serverless deployments, this static value is always + * 8.11.0 and is used solely for backward compatibility with legacy + * clients. Serverless environments are versionless and automatically upgraded, + * so this value can be safely ignored. + *

* API name: {@code number} */ public final String number() { @@ -346,6 +351,11 @@ public final Builder minimumWireCompatibilityVersion(String value) { /** * Required - The Elasticsearch version number. *

+ * ::: IMPORTANT: For Serverless deployments, this static value is always + * 8.11.0 and is used solely for backward compatibility with legacy + * clients. Serverless environments are versionless and automatically upgraded, + * so this value can be safely ignored. + *

* API name: {@code number} */ public final Builder number(String value) { diff --git a/java-client/src/main/java/co/elastic/clients/elasticsearch/_types/aggregations/DateHistogramAggregation.java b/java-client/src/main/java/co/elastic/clients/elasticsearch/_types/aggregations/DateHistogramAggregation.java index 5a3ad063b..17b3cd7ad 100644 --- a/java-client/src/main/java/co/elastic/clients/elasticsearch/_types/aggregations/DateHistogramAggregation.java +++ b/java-client/src/main/java/co/elastic/clients/elasticsearch/_types/aggregations/DateHistogramAggregation.java @@ -656,6 +656,7 @@ public final Builder order(List> list) { *

* Adds one or more values to order. */ + @SafeVarargs public final Builder order(NamedValue value, NamedValue... values) { this.order = _listAdd(this.order, value, values); return this; diff --git a/java-client/src/main/java/co/elastic/clients/elasticsearch/_types/aggregations/FiltersBucket.java b/java-client/src/main/java/co/elastic/clients/elasticsearch/_types/aggregations/FiltersBucket.java index 7d4d92e89..f178f5e12 100644 --- a/java-client/src/main/java/co/elastic/clients/elasticsearch/_types/aggregations/FiltersBucket.java +++ b/java-client/src/main/java/co/elastic/clients/elasticsearch/_types/aggregations/FiltersBucket.java @@ -21,12 +21,15 @@ import co.elastic.clients.json.JsonpDeserializable; import co.elastic.clients.json.JsonpDeserializer; +import co.elastic.clients.json.JsonpMapper; import co.elastic.clients.json.ObjectBuilderDeserializer; import co.elastic.clients.json.ObjectDeserializer; import co.elastic.clients.util.ObjectBuilder; import jakarta.json.stream.JsonGenerator; +import java.lang.String; import java.util.Objects; import java.util.function.Function; +import javax.annotation.Nullable; //---------------------------------------------------------------- // THIS CODE IS GENERATED. MANUAL EDITS WILL BE LOST. @@ -53,17 +56,41 @@ */ @JsonpDeserializable public class FiltersBucket extends MultiBucketBase { + @Nullable + private final String key; + // --------------------------------------------------------------------------------------------- private FiltersBucket(Builder builder) { super(builder); + this.key = builder.key; + } public static FiltersBucket of(Function> fn) { return fn.apply(new Builder()).build(); } + /** + * API name: {@code key} + */ + @Nullable + public final String key() { + return this.key; + } + + protected void serializeInternal(JsonGenerator generator, JsonpMapper mapper) { + + super.serializeInternal(generator, mapper); + if (this.key != null) { + generator.writeKey("key"); + generator.write(this.key); + + } + + } + // --------------------------------------------------------------------------------------------- /** @@ -73,6 +100,17 @@ public static FiltersBucket of(Function> f public static class Builder extends MultiBucketBase.AbstractBuilder implements ObjectBuilder { + @Nullable + private String key; + + /** + * API name: {@code key} + */ + public final Builder key(@Nullable String value) { + this.key = value; + return this; + } + @Override protected Builder self() { return this; @@ -101,6 +139,7 @@ public FiltersBucket build() { protected static void setupFiltersBucketDeserializer(ObjectDeserializer op) { MultiBucketBase.setupMultiBucketBaseDeserializer(op); + op.add(Builder::key, JsonpDeserializer.stringDeserializer(), "key"); } diff --git a/java-client/src/main/java/co/elastic/clients/elasticsearch/_types/aggregations/HistogramAggregation.java b/java-client/src/main/java/co/elastic/clients/elasticsearch/_types/aggregations/HistogramAggregation.java index 9fefe77b0..31775e72e 100644 --- a/java-client/src/main/java/co/elastic/clients/elasticsearch/_types/aggregations/HistogramAggregation.java +++ b/java-client/src/main/java/co/elastic/clients/elasticsearch/_types/aggregations/HistogramAggregation.java @@ -500,6 +500,7 @@ public final Builder order(List> list) { *

* Adds one or more values to order. */ + @SafeVarargs public final Builder order(NamedValue value, NamedValue... values) { this.order = _listAdd(this.order, value, values); return this; diff --git a/java-client/src/main/java/co/elastic/clients/elasticsearch/_types/aggregations/MultiTermsAggregation.java b/java-client/src/main/java/co/elastic/clients/elasticsearch/_types/aggregations/MultiTermsAggregation.java index 78409eeb5..5d0a75a67 100644 --- a/java-client/src/main/java/co/elastic/clients/elasticsearch/_types/aggregations/MultiTermsAggregation.java +++ b/java-client/src/main/java/co/elastic/clients/elasticsearch/_types/aggregations/MultiTermsAggregation.java @@ -329,6 +329,7 @@ public final Builder order(List> list) { *

* Adds one or more values to order. */ + @SafeVarargs public final Builder order(NamedValue value, NamedValue... values) { this.order = _listAdd(this.order, value, values); return this; diff --git a/java-client/src/main/java/co/elastic/clients/elasticsearch/_types/aggregations/TermsAggregation.java b/java-client/src/main/java/co/elastic/clients/elasticsearch/_types/aggregations/TermsAggregation.java index ff8002baf..2d3b47d8d 100644 --- a/java-client/src/main/java/co/elastic/clients/elasticsearch/_types/aggregations/TermsAggregation.java +++ b/java-client/src/main/java/co/elastic/clients/elasticsearch/_types/aggregations/TermsAggregation.java @@ -713,6 +713,7 @@ public final Builder order(List> list) { *

* Adds one or more values to order. */ + @SafeVarargs public final Builder order(NamedValue value, NamedValue... values) { this.order = _listAdd(this.order, value, values); return this; diff --git a/java-client/src/main/java/co/elastic/clients/elasticsearch/_types/mapping/TypeMapping.java b/java-client/src/main/java/co/elastic/clients/elasticsearch/_types/mapping/TypeMapping.java index dde04f111..2458388a0 100644 --- a/java-client/src/main/java/co/elastic/clients/elasticsearch/_types/mapping/TypeMapping.java +++ b/java-client/src/main/java/co/elastic/clients/elasticsearch/_types/mapping/TypeMapping.java @@ -527,6 +527,7 @@ public final Builder dynamicTemplates(List> list) { *

* Adds one or more values to dynamicTemplates. */ + @SafeVarargs public final Builder dynamicTemplates(NamedValue value, NamedValue... values) { this.dynamicTemplates = _listAdd(this.dynamicTemplates, value, values); diff --git a/java-client/src/main/java/co/elastic/clients/elasticsearch/async_search/SubmitRequest.java b/java-client/src/main/java/co/elastic/clients/elasticsearch/async_search/SubmitRequest.java index 6ef0d1b3c..a70ae140f 100644 --- a/java-client/src/main/java/co/elastic/clients/elasticsearch/async_search/SubmitRequest.java +++ b/java-client/src/main/java/co/elastic/clients/elasticsearch/async_search/SubmitRequest.java @@ -1688,6 +1688,7 @@ public final Builder indicesBoost(List> list) { *

* Adds one or more values to indicesBoost. */ + @SafeVarargs public final Builder indicesBoost(NamedValue value, NamedValue... values) { this.indicesBoost = _listAdd(this.indicesBoost, value, values); return this; diff --git a/java-client/src/main/java/co/elastic/clients/elasticsearch/core/InfoRequest.java b/java-client/src/main/java/co/elastic/clients/elasticsearch/core/InfoRequest.java index 598e07652..34c510364 100644 --- a/java-client/src/main/java/co/elastic/clients/elasticsearch/core/InfoRequest.java +++ b/java-client/src/main/java/co/elastic/clients/elasticsearch/core/InfoRequest.java @@ -50,7 +50,9 @@ // typedef: _global.info.Request /** - * Get cluster info. Get basic build, version, and cluster information. + * Get cluster info. Get basic build, version, and cluster information. ::: In + * Serverless, this API is retained for backward compatibility only. Some + * response fields, such as the version number, should be ignored. * * @see API * specification diff --git a/java-client/src/main/java/co/elastic/clients/elasticsearch/core/SearchRequest.java b/java-client/src/main/java/co/elastic/clients/elasticsearch/core/SearchRequest.java index b7839538e..f87f0ec9b 100644 --- a/java-client/src/main/java/co/elastic/clients/elasticsearch/core/SearchRequest.java +++ b/java-client/src/main/java/co/elastic/clients/elasticsearch/core/SearchRequest.java @@ -1977,6 +1977,7 @@ public final Builder indicesBoost(List> list) { *

* Adds one or more values to indicesBoost. */ + @SafeVarargs public final Builder indicesBoost(NamedValue value, NamedValue... values) { this.indicesBoost = _listAdd(this.indicesBoost, value, values); return this; diff --git a/java-client/src/main/java/co/elastic/clients/elasticsearch/core/search/SearchRequestBody.java b/java-client/src/main/java/co/elastic/clients/elasticsearch/core/search/SearchRequestBody.java index c974217fa..f8b37fb9b 100644 --- a/java-client/src/main/java/co/elastic/clients/elasticsearch/core/search/SearchRequestBody.java +++ b/java-client/src/main/java/co/elastic/clients/elasticsearch/core/search/SearchRequestBody.java @@ -1157,6 +1157,7 @@ public final Builder indicesBoost(List> list) { *

* Adds one or more values to indicesBoost. */ + @SafeVarargs public final Builder indicesBoost(NamedValue value, NamedValue... values) { this.indicesBoost = _listAdd(this.indicesBoost, value, values); return this; diff --git a/java-client/src/main/java/co/elastic/clients/elasticsearch/doc-files/api-spec.html b/java-client/src/main/java/co/elastic/clients/elasticsearch/doc-files/api-spec.html index ba05eb04a..592ca2624 100644 --- a/java-client/src/main/java/co/elastic/clients/elasticsearch/doc-files/api-spec.html +++ b/java-client/src/main/java/co/elastic/clients/elasticsearch/doc-files/api-spec.html @@ -92,7 +92,7 @@ '_global.health_report.StagnatingBackingIndices': '_global/health_report/types.ts#L159-L163', '_global.index.Request': '_global/index/IndexRequest.ts#L35-L273', '_global.index.Response': '_global/index/IndexResponse.ts#L22-L25', -'_global.info.Request': '_global/info/RootNodeInfoRequest.ts#L22-L39', +'_global.info.Request': '_global/info/RootNodeInfoRequest.ts#L22-L40', '_global.info.Response': '_global/info/RootNodeInfoResponse.ts#L23-L40', '_global.mget.MultiGetError': '_global/mget/types.ts#L62-L66', '_global.mget.Operation': '_global/mget/types.ts#L32-L55', @@ -102,7 +102,7 @@ '_global.msearch.MultiSearchItem': '_global/msearch/types.ts#L58-L61', '_global.msearch.MultiSearchResult': '_global/msearch/types.ts#L48-L51', '_global.msearch.MultisearchHeader': '_global/msearch/types.ts#L31-L46', -'_global.msearch.Request': '_global/msearch/MultiSearchRequest.ts#L25-L136', +'_global.msearch.Request': '_global/msearch/MultiSearchRequest.ts#L25-L140', '_global.msearch.Response': '_global/msearch/MultiSearchResponse.ts#L25-L28', '_global.msearch.ResponseItem': '_global/msearch/types.ts#L53-L56', '_global.msearch_template.Request': '_global/msearch_template/MultiSearchTemplateRequest.ts#L25-L116', @@ -274,11 +274,11 @@ '_types.DFRBasicModel': '_types/Similarity.ts#L32-L40', '_types.DistanceUnit': '_types/Geo.ts#L30-L40', '_types.DocStats': '_types/Stats.ts#L100-L121', -'_types.ElasticsearchVersionInfo': '_types/Base.ts#L76-L115', -'_types.ElasticsearchVersionMinInfo': '_types/Base.ts#L117-L125', +'_types.ElasticsearchVersionInfo': '_types/Base.ts#L76-L118', +'_types.ElasticsearchVersionMinInfo': '_types/Base.ts#L120-L128', '_types.EmptyObject': '_types/common.ts#L157-L158', '_types.ErrorCause': '_types/Errors.ts#L25-L50', -'_types.ErrorResponseBase': '_types/Base.ts#L127-L136', +'_types.ErrorResponseBase': '_types/Base.ts#L130-L139', '_types.ExpandWildcard': '_types/common.ts#L198-L212', '_types.FieldMemoryUsage': '_types/Stats.ts#L143-L146', '_types.FieldSizeUsage': '_types/Stats.ts#L95-L98', @@ -302,7 +302,7 @@ '_types.IBLambda': '_types/Similarity.ts#L47-L50', '_types.IndexingStats': '_types/Stats.ts#L168-L184', '_types.IndicesOptions': '_types/common.ts#L334-L361', -'_types.IndicesResponseBase': '_types/Base.ts#L138-L140', +'_types.IndicesResponseBase': '_types/Base.ts#L141-L143', '_types.InlineGet': '_types/common.ts#L319-L332', '_types.InnerRetriever': '_types/Retriever.ts#L82-L86', '_types.KnnQuery': '_types/Knn.ts#L64-L87', @@ -356,7 +356,7 @@ '_types.SegmentsStats': '_types/Stats.ts#L298-L393', '_types.ShardFailure': '_types/Errors.ts#L52-L58', '_types.ShardStatistics': '_types/Stats.ts#L54-L69', -'_types.ShardsOperationResponseBase': '_types/Base.ts#L142-L145', +'_types.ShardsOperationResponseBase': '_types/Base.ts#L145-L148', '_types.SlicedScroll': '_types/SlicedScroll.ts#L23-L27', '_types.Slices': '_types/common.ts#L363-L368', '_types.SlicesCalculation': '_types/common.ts#L370-L378', @@ -384,9 +384,9 @@ '_types.WarmerStats': '_types/Stats.ts#L434-L439', '_types.WktGeoBounds': '_types/Geo.ts#L150-L152', '_types.WriteResponseBase': '_types/Base.ts#L36-L67', -'_types.aggregations.AdjacencyMatrixAggregate': '_types/aggregations/Aggregate.ts#L647-L652', +'_types.aggregations.AdjacencyMatrixAggregate': '_types/aggregations/Aggregate.ts#L649-L654', '_types.aggregations.AdjacencyMatrixAggregation': '_types/aggregations/bucket.ts#L60-L70', -'_types.aggregations.AdjacencyMatrixBucket': '_types/aggregations/Aggregate.ts#L654-L656', +'_types.aggregations.AdjacencyMatrixBucket': '_types/aggregations/Aggregate.ts#L656-L658', '_types.aggregations.Aggregate': '_types/aggregations/Aggregate.ts#L38-L125', '_types.aggregations.AggregateBase': '_types/aggregations/Aggregate.ts#L136-L138', '_types.aggregations.Aggregation': '_types/aggregations/Aggregation.ts#L20-L20', @@ -398,7 +398,7 @@ '_types.aggregations.AverageAggregation': '_types/aggregations/metric.ts#L55-L55', '_types.aggregations.AverageBucketAggregation': '_types/aggregations/pipeline.ts#L78-L81', '_types.aggregations.AvgAggregate': '_types/aggregations/Aggregate.ts#L218-L222', -'_types.aggregations.BoxPlotAggregate': '_types/aggregations/Aggregate.ts#L806-L825', +'_types.aggregations.BoxPlotAggregate': '_types/aggregations/Aggregate.ts#L808-L827', '_types.aggregations.BoxplotAggregation': '_types/aggregations/metric.ts#L57-L62', '_types.aggregations.BucketAggregationBase': '_types/aggregations/bucket.ts#L53-L58', '_types.aggregations.BucketCorrelationAggregation': '_types/aggregations/pipeline.ts#L139-L146', @@ -420,18 +420,18 @@ '_types.aggregations.CategorizeTextAggregation': '_types/aggregations/bucket.ts#L1117-L1183', '_types.aggregations.CategorizeTextAnalyzer': '_types/aggregations/bucket.ts#L1185-L1188', '_types.aggregations.ChiSquareHeuristic': '_types/aggregations/bucket.ts#L782-L791', -'_types.aggregations.ChildrenAggregate': '_types/aggregations/Aggregate.ts#L888-L892', +'_types.aggregations.ChildrenAggregate': '_types/aggregations/Aggregate.ts#L890-L894', '_types.aggregations.ChildrenAggregation': '_types/aggregations/bucket.ts#L121-L126', -'_types.aggregations.CompositeAggregate': '_types/aggregations/Aggregate.ts#L698-L703', +'_types.aggregations.CompositeAggregate': '_types/aggregations/Aggregate.ts#L700-L705', '_types.aggregations.CompositeAggregation': '_types/aggregations/bucket.ts#L130-L149', '_types.aggregations.CompositeAggregationBase': '_types/aggregations/bucket.ts#L170-L179', '_types.aggregations.CompositeAggregationSource': '_types/aggregations/bucket.ts#L151-L168', -'_types.aggregations.CompositeBucket': '_types/aggregations/Aggregate.ts#L705-L707', +'_types.aggregations.CompositeBucket': '_types/aggregations/Aggregate.ts#L707-L709', '_types.aggregations.CompositeDateHistogramAggregation': '_types/aggregations/bucket.ts#L187-L195', '_types.aggregations.CompositeGeoTileGridAggregation': '_types/aggregations/bucket.ts#L197-L200', '_types.aggregations.CompositeHistogramAggregation': '_types/aggregations/bucket.ts#L183-L185', '_types.aggregations.CompositeTermsAggregation': '_types/aggregations/bucket.ts#L181-L181', -'_types.aggregations.CumulativeCardinalityAggregate': '_types/aggregations/Aggregate.ts#L856-L864', +'_types.aggregations.CumulativeCardinalityAggregate': '_types/aggregations/Aggregate.ts#L858-L866', '_types.aggregations.CumulativeCardinalityAggregation': '_types/aggregations/pipeline.ts#L206-L209', '_types.aggregations.CumulativeSumAggregation': '_types/aggregations/pipeline.ts#L211-L214', '_types.aggregations.CustomCategorizeTextAnalyzer': '_types/aggregations/bucket.ts#L1190-L1194', @@ -457,12 +457,12 @@ '_types.aggregations.FilterAggregate': '_types/aggregations/Aggregate.ts#L552-L556', '_types.aggregations.FiltersAggregate': '_types/aggregations/Aggregate.ts#L639-L643', '_types.aggregations.FiltersAggregation': '_types/aggregations/bucket.ts#L374-L394', -'_types.aggregations.FiltersBucket': '_types/aggregations/Aggregate.ts#L645-L645', +'_types.aggregations.FiltersBucket': '_types/aggregations/Aggregate.ts#L645-L647', '_types.aggregations.FormatMetricAggregationBase': '_types/aggregations/metric.ts#L47-L49', '_types.aggregations.FormattableMetricAggregation': '_types/aggregations/metric.ts#L51-L53', -'_types.aggregations.FrequentItemSetsAggregate': '_types/aggregations/Aggregate.ts#L722-L723', +'_types.aggregations.FrequentItemSetsAggregate': '_types/aggregations/Aggregate.ts#L724-L725', '_types.aggregations.FrequentItemSetsAggregation': '_types/aggregations/bucket.ts#L1241-L1268', -'_types.aggregations.FrequentItemSetsBucket': '_types/aggregations/Aggregate.ts#L725-L728', +'_types.aggregations.FrequentItemSetsBucket': '_types/aggregations/Aggregate.ts#L727-L730', '_types.aggregations.FrequentItemSetsField': '_types/aggregations/bucket.ts#L1227-L1239', '_types.aggregations.GapPolicy': '_types/aggregations/pipeline.ts#L61-L76', '_types.aggregations.GeoBoundsAggregate': '_types/aggregations/Aggregate.ts#L327-L333', @@ -476,7 +476,7 @@ '_types.aggregations.GeoHashGridBucket': '_types/aggregations/Aggregate.ts#L570-L572', '_types.aggregations.GeoHexGridAggregate': '_types/aggregations/Aggregate.ts#L585-L586', '_types.aggregations.GeoHexGridBucket': '_types/aggregations/Aggregate.ts#L588-L590', -'_types.aggregations.GeoLineAggregate': '_types/aggregations/Aggregate.ts#L902-L912', +'_types.aggregations.GeoLineAggregate': '_types/aggregations/Aggregate.ts#L904-L914', '_types.aggregations.GeoLineAggregation': '_types/aggregations/metric.ts#L124-L149', '_types.aggregations.GeoLinePoint': '_types/aggregations/metric.ts#L158-L163', '_types.aggregations.GeoLineSort': '_types/aggregations/metric.ts#L151-L156', @@ -498,15 +498,15 @@ '_types.aggregations.HoltWintersModelSettings': '_types/aggregations/pipeline.ts#L301-L308', '_types.aggregations.HoltWintersMovingAverageAggregation': '_types/aggregations/pipeline.ts#L288-L291', '_types.aggregations.HoltWintersType': '_types/aggregations/pipeline.ts#L309-L312', -'_types.aggregations.InferenceAggregate': '_types/aggregations/Aggregate.ts#L755-L770', +'_types.aggregations.InferenceAggregate': '_types/aggregations/Aggregate.ts#L757-L772', '_types.aggregations.InferenceAggregation': '_types/aggregations/pipeline.ts#L225-L234', -'_types.aggregations.InferenceClassImportance': '_types/aggregations/Aggregate.ts#L784-L787', +'_types.aggregations.InferenceClassImportance': '_types/aggregations/Aggregate.ts#L786-L789', '_types.aggregations.InferenceConfigContainer': '_types/aggregations/pipeline.ts#L236-L242', -'_types.aggregations.InferenceFeatureImportance': '_types/aggregations/Aggregate.ts#L778-L782', -'_types.aggregations.InferenceTopClassEntry': '_types/aggregations/Aggregate.ts#L772-L776', -'_types.aggregations.IpPrefixAggregate': '_types/aggregations/Aggregate.ts#L709-L713', +'_types.aggregations.InferenceFeatureImportance': '_types/aggregations/Aggregate.ts#L780-L784', +'_types.aggregations.InferenceTopClassEntry': '_types/aggregations/Aggregate.ts#L774-L778', +'_types.aggregations.IpPrefixAggregate': '_types/aggregations/Aggregate.ts#L711-L715', '_types.aggregations.IpPrefixAggregation': '_types/aggregations/bucket.ts#L1196-L1225', -'_types.aggregations.IpPrefixBucket': '_types/aggregations/Aggregate.ts#L715-L720', +'_types.aggregations.IpPrefixBucket': '_types/aggregations/Aggregate.ts#L717-L722', '_types.aggregations.IpRangeAggregate': '_types/aggregations/Aggregate.ts#L624-L629', '_types.aggregations.IpRangeAggregation': '_types/aggregations/bucket.ts#L567-L576', '_types.aggregations.IpRangeAggregationRange': '_types/aggregations/bucket.ts#L578-L591', @@ -517,9 +517,9 @@ '_types.aggregations.LongTermsAggregate': '_types/aggregations/Aggregate.ts#L439-L444', '_types.aggregations.LongTermsBucket': '_types/aggregations/Aggregate.ts#L446-L449', '_types.aggregations.MatrixAggregation': '_types/aggregations/matrix.ts#L26-L36', -'_types.aggregations.MatrixStatsAggregate': '_types/aggregations/Aggregate.ts#L866-L873', +'_types.aggregations.MatrixStatsAggregate': '_types/aggregations/Aggregate.ts#L868-L875', '_types.aggregations.MatrixStatsAggregation': '_types/aggregations/matrix.ts#L38-L44', -'_types.aggregations.MatrixStatsFields': '_types/aggregations/Aggregate.ts#L875-L884', +'_types.aggregations.MatrixStatsFields': '_types/aggregations/Aggregate.ts#L877-L886', '_types.aggregations.MaxAggregate': '_types/aggregations/Aggregate.ts#L205-L209', '_types.aggregations.MaxAggregation': '_types/aggregations/metric.ts#L165-L165', '_types.aggregations.MaxBucketAggregation': '_types/aggregations/pipeline.ts#L244-L247', @@ -548,7 +548,7 @@ '_types.aggregations.NestedAggregation': '_types/aggregations/bucket.ts#L655-L660', '_types.aggregations.NormalizeAggregation': '_types/aggregations/pipeline.ts#L351-L359', '_types.aggregations.NormalizeMethod': '_types/aggregations/pipeline.ts#L361-L387', -'_types.aggregations.ParentAggregate': '_types/aggregations/Aggregate.ts#L894-L898', +'_types.aggregations.ParentAggregate': '_types/aggregations/Aggregate.ts#L896-L900', '_types.aggregations.ParentAggregation': '_types/aggregations/bucket.ts#L662-L667', '_types.aggregations.PercentageScoreHeuristic': '_types/aggregations/bucket.ts#L811-L811', '_types.aggregations.PercentileRanksAggregation': '_types/aggregations/metric.ts#L180-L202', @@ -563,7 +563,7 @@ '_types.aggregations.RangeAggregation': '_types/aggregations/bucket.ts#L669-L689', '_types.aggregations.RangeBucket': '_types/aggregations/Aggregate.ts#L600-L607', '_types.aggregations.RareTermsAggregation': '_types/aggregations/bucket.ts#L706-L739', -'_types.aggregations.RateAggregate': '_types/aggregations/Aggregate.ts#L847-L854', +'_types.aggregations.RateAggregate': '_types/aggregations/Aggregate.ts#L849-L856', '_types.aggregations.RateAggregation': '_types/aggregations/metric.ts#L239-L250', '_types.aggregations.RateMode': '_types/aggregations/metric.ts#L252-L261', '_types.aggregations.ReverseNestedAggregate': '_types/aggregations/Aggregate.ts#L540-L544', @@ -572,16 +572,16 @@ '_types.aggregations.SamplerAggregation': '_types/aggregations/bucket.ts#L771-L780', '_types.aggregations.SamplerAggregationExecutionHint': '_types/aggregations/bucket.ts#L359-L372', '_types.aggregations.ScriptedHeuristic': '_types/aggregations/bucket.ts#L813-L815', -'_types.aggregations.ScriptedMetricAggregate': '_types/aggregations/Aggregate.ts#L739-L745', +'_types.aggregations.ScriptedMetricAggregate': '_types/aggregations/Aggregate.ts#L741-L747', '_types.aggregations.ScriptedMetricAggregation': '_types/aggregations/metric.ts#L263-L289', '_types.aggregations.SerialDifferencingAggregation': '_types/aggregations/pipeline.ts#L399-L408', -'_types.aggregations.SignificantLongTermsAggregate': '_types/aggregations/Aggregate.ts#L668-L670', -'_types.aggregations.SignificantLongTermsBucket': '_types/aggregations/Aggregate.ts#L677-L680', -'_types.aggregations.SignificantStringTermsAggregate': '_types/aggregations/Aggregate.ts#L682-L684', -'_types.aggregations.SignificantStringTermsBucket': '_types/aggregations/Aggregate.ts#L686-L688', -'_types.aggregations.SignificantTermsAggregateBase': '_types/aggregations/Aggregate.ts#L658-L666', +'_types.aggregations.SignificantLongTermsAggregate': '_types/aggregations/Aggregate.ts#L670-L672', +'_types.aggregations.SignificantLongTermsBucket': '_types/aggregations/Aggregate.ts#L679-L682', +'_types.aggregations.SignificantStringTermsAggregate': '_types/aggregations/Aggregate.ts#L684-L686', +'_types.aggregations.SignificantStringTermsBucket': '_types/aggregations/Aggregate.ts#L688-L690', +'_types.aggregations.SignificantTermsAggregateBase': '_types/aggregations/Aggregate.ts#L660-L668', '_types.aggregations.SignificantTermsAggregation': '_types/aggregations/bucket.ts#L817-L884', -'_types.aggregations.SignificantTermsBucketBase': '_types/aggregations/Aggregate.ts#L672-L675', +'_types.aggregations.SignificantTermsBucketBase': '_types/aggregations/Aggregate.ts#L674-L677', '_types.aggregations.SignificantTextAggregation': '_types/aggregations/bucket.ts#L886-L961', '_types.aggregations.SimpleMovingAverageAggregation': '_types/aggregations/pipeline.ts#L273-L276', '_types.aggregations.SimpleValueAggregate': '_types/aggregations/Aggregate.ts#L238-L239', @@ -595,7 +595,7 @@ '_types.aggregations.StatsBucketAggregation': '_types/aggregations/pipeline.ts#L410-L410', '_types.aggregations.StringRareTermsAggregate': '_types/aggregations/Aggregate.ts#L483-L487', '_types.aggregations.StringRareTermsBucket': '_types/aggregations/Aggregate.ts#L489-L491', -'_types.aggregations.StringStatsAggregate': '_types/aggregations/Aggregate.ts#L793-L804', +'_types.aggregations.StringStatsAggregate': '_types/aggregations/Aggregate.ts#L795-L806', '_types.aggregations.StringStatsAggregation': '_types/aggregations/metric.ts#L293-L299', '_types.aggregations.StringTermsAggregate': '_types/aggregations/Aggregate.ts#L424-L429', '_types.aggregations.StringTermsBucket': '_types/aggregations/Aggregate.ts#L435-L437', @@ -605,7 +605,7 @@ '_types.aggregations.TDigest': '_types/aggregations/metric.ts#L232-L237', '_types.aggregations.TDigestPercentileRanksAggregate': '_types/aggregations/Aggregate.ts#L177-L178', '_types.aggregations.TDigestPercentilesAggregate': '_types/aggregations/Aggregate.ts#L174-L175', -'_types.aggregations.TTestAggregate': '_types/aggregations/Aggregate.ts#L838-L845', +'_types.aggregations.TTestAggregate': '_types/aggregations/Aggregate.ts#L840-L847', '_types.aggregations.TTestAggregation': '_types/aggregations/metric.ts#L303-L317', '_types.aggregations.TTestType': '_types/aggregations/metric.ts#L331-L344', '_types.aggregations.TermsAggregateBase': '_types/aggregations/Aggregate.ts#L417-L422', @@ -617,18 +617,18 @@ '_types.aggregations.TermsInclude': '_types/aggregations/bucket.ts#L1074-L1075', '_types.aggregations.TermsPartition': '_types/aggregations/bucket.ts#L1080-L1089', '_types.aggregations.TestPopulation': '_types/aggregations/metric.ts#L319-L329', -'_types.aggregations.TimeSeriesAggregate': '_types/aggregations/Aggregate.ts#L730-L731', +'_types.aggregations.TimeSeriesAggregate': '_types/aggregations/Aggregate.ts#L732-L733', '_types.aggregations.TimeSeriesAggregation': '_types/aggregations/bucket.ts#L1033-L1046', -'_types.aggregations.TimeSeriesBucket': '_types/aggregations/Aggregate.ts#L733-L735', -'_types.aggregations.TopHitsAggregate': '_types/aggregations/Aggregate.ts#L747-L753', +'_types.aggregations.TimeSeriesBucket': '_types/aggregations/Aggregate.ts#L735-L737', +'_types.aggregations.TopHitsAggregate': '_types/aggregations/Aggregate.ts#L749-L755', '_types.aggregations.TopHitsAggregation': '_types/aggregations/metric.ts#L346-L406', -'_types.aggregations.TopMetrics': '_types/aggregations/Aggregate.ts#L832-L836', -'_types.aggregations.TopMetricsAggregate': '_types/aggregations/Aggregate.ts#L827-L830', +'_types.aggregations.TopMetrics': '_types/aggregations/Aggregate.ts#L834-L838', +'_types.aggregations.TopMetricsAggregate': '_types/aggregations/Aggregate.ts#L829-L832', '_types.aggregations.TopMetricsAggregation': '_types/aggregations/metric.ts#L408-L425', '_types.aggregations.TopMetricsValue': '_types/aggregations/metric.ts#L427-L432', '_types.aggregations.UnmappedRareTermsAggregate': '_types/aggregations/Aggregate.ts#L493-L499', '_types.aggregations.UnmappedSamplerAggregate': '_types/aggregations/Aggregate.ts#L561-L562', -'_types.aggregations.UnmappedSignificantTermsAggregate': '_types/aggregations/Aggregate.ts#L690-L696', +'_types.aggregations.UnmappedSignificantTermsAggregate': '_types/aggregations/Aggregate.ts#L692-L698', '_types.aggregations.UnmappedTermsAggregate': '_types/aggregations/Aggregate.ts#L463-L469', '_types.aggregations.ValueCountAggregate': '_types/aggregations/Aggregate.ts#L231-L236', '_types.aggregations.ValueCountAggregation': '_types/aggregations/metric.ts#L434-L434', @@ -680,7 +680,7 @@ '_types.analysis.DutchStemTokenFilter': '_types/analysis/token_filters.ts#L559-L561', '_types.analysis.EdgeNGramSide': '_types/analysis/token_filters.ts#L92-L95', '_types.analysis.EdgeNGramTokenFilter': '_types/analysis/token_filters.ts#L97-L107', -'_types.analysis.EdgeNGramTokenizer': '_types/analysis/tokenizers.ts#L48-L54', +'_types.analysis.EdgeNGramTokenizer': '_types/analysis/tokenizers.ts#L48-L58', '_types.analysis.ElisionTokenFilter': '_types/analysis/token_filters.ts#L245-L258', '_types.analysis.EnglishAnalyzer': '_types/analysis/analyzers.ts#L152-L157', '_types.analysis.EstonianAnalyzer': '_types/analysis/analyzers.ts#L159-L163', @@ -727,7 +727,7 @@ '_types.analysis.KeywordAnalyzer': '_types/analysis/analyzers.ts#L66-L70', '_types.analysis.KeywordMarkerTokenFilter': '_types/analysis/token_filters.ts#L308-L322', '_types.analysis.KeywordRepeatTokenFilter': '_types/analysis/token_filters.ts#L510-L512', -'_types.analysis.KeywordTokenizer': '_types/analysis/tokenizers.ts#L65-L71', +'_types.analysis.KeywordTokenizer': '_types/analysis/tokenizers.ts#L69-L75', '_types.analysis.KuromojiAnalyzer': '_types/analysis/kuromoji-plugin.ts#L26-L30', '_types.analysis.KuromojiIterationMarkCharFilter': '_types/analysis/kuromoji-plugin.ts#L37-L41', '_types.analysis.KuromojiPartOfSpeechTokenFilter': '_types/analysis/kuromoji-plugin.ts#L43-L46', @@ -737,30 +737,30 @@ '_types.analysis.KuromojiTokenizer': '_types/analysis/kuromoji-plugin.ts#L64-L73', '_types.analysis.LatvianAnalyzer': '_types/analysis/analyzers.ts#L234-L239', '_types.analysis.LengthTokenFilter': '_types/analysis/token_filters.ts#L328-L334', -'_types.analysis.LetterTokenizer': '_types/analysis/tokenizers.ts#L73-L75', +'_types.analysis.LetterTokenizer': '_types/analysis/tokenizers.ts#L77-L79', '_types.analysis.LimitTokenCountTokenFilter': '_types/analysis/token_filters.ts#L336-L342', '_types.analysis.LithuanianAnalyzer': '_types/analysis/analyzers.ts#L241-L246', '_types.analysis.LowercaseNormalizer': '_types/analysis/normalizers.ts#L26-L28', '_types.analysis.LowercaseTokenFilter': '_types/analysis/token_filters.ts#L350-L354', '_types.analysis.LowercaseTokenFilterLanguages': '_types/analysis/token_filters.ts#L344-L348', -'_types.analysis.LowercaseTokenizer': '_types/analysis/tokenizers.ts#L77-L79', +'_types.analysis.LowercaseTokenizer': '_types/analysis/tokenizers.ts#L81-L83', '_types.analysis.MappingCharFilter': '_types/analysis/char_filters.ts#L51-L55', '_types.analysis.MinHashTokenFilter': '_types/analysis/token_filters.ts#L514-L525', '_types.analysis.MultiplexerTokenFilter': '_types/analysis/token_filters.ts#L356-L362', '_types.analysis.NGramTokenFilter': '_types/analysis/token_filters.ts#L364-L372', -'_types.analysis.NGramTokenizer': '_types/analysis/tokenizers.ts#L81-L90', +'_types.analysis.NGramTokenizer': '_types/analysis/tokenizers.ts#L85-L95', '_types.analysis.NoriAnalyzer': '_types/analysis/analyzers.ts#L323-L330', '_types.analysis.NoriDecompoundMode': '_types/analysis/nori-plugin.ts#L23-L27', '_types.analysis.NoriPartOfSpeechTokenFilter': '_types/analysis/nori-plugin.ts#L37-L41', '_types.analysis.NoriTokenizer': '_types/analysis/nori-plugin.ts#L29-L35', '_types.analysis.Normalizer': '_types/analysis/normalizers.ts#L20-L24', '_types.analysis.NorwegianAnalyzer': '_types/analysis/analyzers.ts#L248-L253', -'_types.analysis.PathHierarchyTokenizer': '_types/analysis/tokenizers.ts#L92-L99', +'_types.analysis.PathHierarchyTokenizer': '_types/analysis/tokenizers.ts#L97-L104', '_types.analysis.PatternAnalyzer': '_types/analysis/analyzers.ts#L332-L365', '_types.analysis.PatternCaptureTokenFilter': '_types/analysis/token_filters.ts#L374-L380', '_types.analysis.PatternReplaceCharFilter': '_types/analysis/char_filters.ts#L57-L62', '_types.analysis.PatternReplaceTokenFilter': '_types/analysis/token_filters.ts#L382-L391', -'_types.analysis.PatternTokenizer': '_types/analysis/tokenizers.ts#L101-L106', +'_types.analysis.PatternTokenizer': '_types/analysis/tokenizers.ts#L106-L111', '_types.analysis.PersianAnalyzer': '_types/analysis/analyzers.ts#L255-L259', '_types.analysis.PersianNormalizationTokenFilter': '_types/analysis/token_filters.ts#L527-L529', '_types.analysis.PersianStemTokenFilter': '_types/analysis/token_filters.ts#L571-L573', @@ -783,8 +783,8 @@ '_types.analysis.SerbianNormalizationTokenFilter': '_types/analysis/token_filters.ts#L539-L541', '_types.analysis.ShingleTokenFilter': '_types/analysis/token_filters.ts#L109-L123', '_types.analysis.SimpleAnalyzer': '_types/analysis/analyzers.ts#L367-L371', -'_types.analysis.SimplePatternSplitTokenizer': '_types/analysis/tokenizers.ts#L113-L116', -'_types.analysis.SimplePatternTokenizer': '_types/analysis/tokenizers.ts#L108-L111', +'_types.analysis.SimplePatternSplitTokenizer': '_types/analysis/tokenizers.ts#L118-L121', +'_types.analysis.SimplePatternTokenizer': '_types/analysis/tokenizers.ts#L113-L116', '_types.analysis.SnowballAnalyzer': '_types/analysis/analyzers.ts#L374-L380', '_types.analysis.SnowballLanguage': '_types/analysis/languages.ts#L20-L48', '_types.analysis.SnowballTokenFilter': '_types/analysis/token_filters.ts#L411-L415', @@ -792,7 +792,7 @@ '_types.analysis.SoraniNormalizationTokenFilter': '_types/analysis/token_filters.ts#L543-L545', '_types.analysis.SpanishAnalyzer': '_types/analysis/analyzers.ts#L296-L301', '_types.analysis.StandardAnalyzer': '_types/analysis/analyzers.ts#L382-L402', -'_types.analysis.StandardTokenizer': '_types/analysis/tokenizers.ts#L118-L121', +'_types.analysis.StandardTokenizer': '_types/analysis/tokenizers.ts#L123-L126', '_types.analysis.StemmerOverrideTokenFilter': '_types/analysis/token_filters.ts#L417-L423', '_types.analysis.StemmerTokenFilter': '_types/analysis/token_filters.ts#L425-L429', '_types.analysis.StopAnalyzer': '_types/analysis/analyzers.ts#L404-L419', @@ -803,22 +803,22 @@ '_types.analysis.SynonymTokenFilter': '_types/analysis/token_filters.ts#L167-L169', '_types.analysis.SynonymTokenFilterBase': '_types/analysis/token_filters.ts#L143-L161', '_types.analysis.ThaiAnalyzer': '_types/analysis/analyzers.ts#L317-L321', -'_types.analysis.ThaiTokenizer': '_types/analysis/tokenizers.ts#L123-L125', -'_types.analysis.TokenChar': '_types/analysis/tokenizers.ts#L56-L63', +'_types.analysis.ThaiTokenizer': '_types/analysis/tokenizers.ts#L128-L130', +'_types.analysis.TokenChar': '_types/analysis/tokenizers.ts#L60-L67', '_types.analysis.TokenFilter': '_types/analysis/token_filters.ts#L575-L580', '_types.analysis.TokenFilterBase': '_types/analysis/token_filters.ts#L41-L43', '_types.analysis.TokenFilterDefinition': '_types/analysis/token_filters.ts#L582-L660', -'_types.analysis.Tokenizer': '_types/analysis/tokenizers.ts#L137-L142', +'_types.analysis.Tokenizer': '_types/analysis/tokenizers.ts#L142-L147', '_types.analysis.TokenizerBase': '_types/analysis/tokenizers.ts#L27-L29', -'_types.analysis.TokenizerDefinition': '_types/analysis/tokenizers.ts#L144-L167', +'_types.analysis.TokenizerDefinition': '_types/analysis/tokenizers.ts#L149-L172', '_types.analysis.TrimTokenFilter': '_types/analysis/token_filters.ts#L431-L433', '_types.analysis.TruncateTokenFilter': '_types/analysis/token_filters.ts#L435-L439', '_types.analysis.TurkishAnalyzer': '_types/analysis/analyzers.ts#L310-L315', -'_types.analysis.UaxEmailUrlTokenizer': '_types/analysis/tokenizers.ts#L127-L130', +'_types.analysis.UaxEmailUrlTokenizer': '_types/analysis/tokenizers.ts#L132-L135', '_types.analysis.UniqueTokenFilter': '_types/analysis/token_filters.ts#L441-L445', '_types.analysis.UppercaseTokenFilter': '_types/analysis/token_filters.ts#L447-L449', '_types.analysis.WhitespaceAnalyzer': '_types/analysis/analyzers.ts#L421-L425', -'_types.analysis.WhitespaceTokenizer': '_types/analysis/tokenizers.ts#L132-L135', +'_types.analysis.WhitespaceTokenizer': '_types/analysis/tokenizers.ts#L137-L140', '_types.analysis.WordDelimiterGraphTokenFilter': '_types/analysis/token_filters.ts#L205-L211', '_types.analysis.WordDelimiterTokenFilter': '_types/analysis/token_filters.ts#L201-L203', '_types.analysis.WordDelimiterTokenFilterBase': '_types/analysis/token_filters.ts#L171-L199', @@ -1425,7 +1425,7 @@ 'eql.search.ResultPosition': 'eql/search/types.ts#L20-L32', 'esql._types.EsqlFormat': 'esql/_types/QueryParameters.ts#L20-L29', 'esql._types.TableValuesContainer': 'esql/_types/TableValuesContainer.ts#L22-L28', -'esql.query.Request': 'esql/query/QueryRequest.ts#L27-L105', +'esql.query.Request': 'esql/query/QueryRequest.ts#L27-L107', 'esql.query.Response': 'esql/query/QueryResponse.ts#L22-L25', 'features._types.Feature': 'features/_types/Feature.ts#L20-L23', 'features.get_features.Request': 'features/get_features/GetFeaturesRequest.ts#L23-L53', @@ -1602,6 +1602,7 @@ 'indices.data_streams_stats.Response': 'indices/data_streams_stats/IndicesDataStreamsStatsResponse.ts#L25-L43', 'indices.delete.Request': 'indices/delete/IndicesDeleteRequest.ts#L24-L86', 'indices.delete.Response': 'indices/delete/IndicesDeleteResponse.ts#L22-L25', +'indices.delete_alias.IndicesAliasesResponseBody': 'indices/delete_alias/IndicesDeleteAliasResponse.ts#L27-L29', 'indices.delete_alias.Request': 'indices/delete_alias/IndicesDeleteAliasRequest.ts#L24-L70', 'indices.delete_alias.Response': 'indices/delete_alias/IndicesDeleteAliasResponse.ts#L22-L25', 'indices.delete_data_lifecycle.Request': 'indices/delete_data_lifecycle/IndicesDeleteDataLifecycleRequest.ts#L24-L48', @@ -3287,10 +3288,10 @@ if (hash.length > 1) { hash = hash.substring(1); } - window.location = "https://github.com/elastic/elasticsearch-specification/tree/4f4c225806fb54b43636017cbefe7d108438ae9e/specification/" + (paths[hash] || ""); + window.location = "https://github.com/elastic/elasticsearch-specification/tree/3e1ec6798fc5c8ea1b48ce42a98e9005dc6bde27/specification/" + (paths[hash] || ""); - Please see the Elasticsearch API specification. + Please see the Elasticsearch API specification. diff --git a/java-client/src/main/java/co/elastic/clients/elasticsearch/esql/QueryRequest.java b/java-client/src/main/java/co/elastic/clients/elasticsearch/esql/QueryRequest.java index 926d833f9..e3a1dd29c 100644 --- a/java-client/src/main/java/co/elastic/clients/elasticsearch/esql/QueryRequest.java +++ b/java-client/src/main/java/co/elastic/clients/elasticsearch/esql/QueryRequest.java @@ -177,6 +177,10 @@ public final Query filter() { /** * A short version of the Accept header, e.g. json, yaml. *

+ * csv, tsv, and txt formats will return + * results in a tabular format, excluding other metadata fields from the + * response. + *

* API name: {@code format} */ @Nullable @@ -432,6 +436,10 @@ public final Builder filter(QueryVariant value) { /** * A short version of the Accept header, e.g. json, yaml. *

+ * csv, tsv, and txt formats will return + * results in a tabular format, excluding other metadata fields from the + * response. + *

* API name: {@code format} */ public final Builder format(@Nullable EsqlFormat value) { diff --git a/java-client/src/main/java/co/elastic/clients/elasticsearch/fleet/FleetSearchRequest.java b/java-client/src/main/java/co/elastic/clients/elasticsearch/fleet/FleetSearchRequest.java index 6a0e2fcef..7f11a2fcc 100644 --- a/java-client/src/main/java/co/elastic/clients/elasticsearch/fleet/FleetSearchRequest.java +++ b/java-client/src/main/java/co/elastic/clients/elasticsearch/fleet/FleetSearchRequest.java @@ -1552,6 +1552,7 @@ public final Builder indicesBoost(List> list) { *

* Adds one or more values to indicesBoost. */ + @SafeVarargs public final Builder indicesBoost(NamedValue value, NamedValue... values) { this.indicesBoost = _listAdd(this.indicesBoost, value, values); return this; diff --git a/java-client/src/main/java/co/elastic/clients/elasticsearch/indices/DeleteAliasResponse.java b/java-client/src/main/java/co/elastic/clients/elasticsearch/indices/DeleteAliasResponse.java index 1255191ab..94d0daf49 100644 --- a/java-client/src/main/java/co/elastic/clients/elasticsearch/indices/DeleteAliasResponse.java +++ b/java-client/src/main/java/co/elastic/clients/elasticsearch/indices/DeleteAliasResponse.java @@ -19,7 +19,7 @@ package co.elastic.clients.elasticsearch.indices; -import co.elastic.clients.elasticsearch._types.AcknowledgedResponseBase; +import co.elastic.clients.elasticsearch.indices.delete_alias.IndicesAliasesResponseBody; import co.elastic.clients.json.JsonpDeserializable; import co.elastic.clients.json.JsonpDeserializer; import co.elastic.clients.json.ObjectBuilderDeserializer; @@ -52,7 +52,7 @@ * specification */ @JsonpDeserializable -public class DeleteAliasResponse extends AcknowledgedResponseBase { +public class DeleteAliasResponse extends IndicesAliasesResponseBody { // --------------------------------------------------------------------------------------------- private DeleteAliasResponse(Builder builder) { @@ -70,7 +70,7 @@ public static DeleteAliasResponse of(Function + public static class Builder extends IndicesAliasesResponseBody.AbstractBuilder implements ObjectBuilder { @Override @@ -100,7 +100,7 @@ public DeleteAliasResponse build() { .lazy(Builder::new, DeleteAliasResponse::setupDeleteAliasResponseDeserializer); protected static void setupDeleteAliasResponseDeserializer(ObjectDeserializer op) { - AcknowledgedResponseBase.setupAcknowledgedResponseBaseDeserializer(op); + IndicesAliasesResponseBody.setupIndicesAliasesResponseBodyDeserializer(op); } diff --git a/java-client/src/main/java/co/elastic/clients/elasticsearch/indices/PutMappingRequest.java b/java-client/src/main/java/co/elastic/clients/elasticsearch/indices/PutMappingRequest.java index 0c36e2e3d..a07833ec5 100644 --- a/java-client/src/main/java/co/elastic/clients/elasticsearch/indices/PutMappingRequest.java +++ b/java-client/src/main/java/co/elastic/clients/elasticsearch/indices/PutMappingRequest.java @@ -690,6 +690,7 @@ public final Builder dynamicTemplates(List> list) { *

* Adds one or more values to dynamicTemplates. */ + @SafeVarargs public final Builder dynamicTemplates(NamedValue value, NamedValue... values) { this.dynamicTemplates = _listAdd(this.dynamicTemplates, value, values); diff --git a/java-client/src/main/java/co/elastic/clients/elasticsearch/indices/delete_alias/IndicesAliasesResponseBody.java b/java-client/src/main/java/co/elastic/clients/elasticsearch/indices/delete_alias/IndicesAliasesResponseBody.java new file mode 100644 index 000000000..9f391e64b --- /dev/null +++ b/java-client/src/main/java/co/elastic/clients/elasticsearch/indices/delete_alias/IndicesAliasesResponseBody.java @@ -0,0 +1,115 @@ +/* + * Licensed to Elasticsearch B.V. under one or more contributor + * license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright + * ownership. Elasticsearch B.V. licenses this file to you under + * the Apache License, Version 2.0 (the "License"); you may + * not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +package co.elastic.clients.elasticsearch.indices.delete_alias; + +import co.elastic.clients.elasticsearch._types.AcknowledgedResponseBase; +import co.elastic.clients.json.JsonpDeserializable; +import co.elastic.clients.json.JsonpDeserializer; +import co.elastic.clients.json.JsonpMapper; +import co.elastic.clients.json.ObjectBuilderDeserializer; +import co.elastic.clients.json.ObjectDeserializer; +import co.elastic.clients.util.ObjectBuilder; +import co.elastic.clients.util.WithJsonObjectBuilderBase; +import jakarta.json.stream.JsonGenerator; +import java.lang.Boolean; +import java.util.Objects; +import javax.annotation.Nullable; + +//---------------------------------------------------------------- +// THIS CODE IS GENERATED. MANUAL EDITS WILL BE LOST. +//---------------------------------------------------------------- +// +// This code is generated from the Elasticsearch API specification +// at https://github.com/elastic/elasticsearch-specification +// +// Manual updates to this file will be lost when the code is +// re-generated. +// +// If you find a property that is missing or wrongly typed, please +// open an issue or a PR on the API specification repository. +// +//---------------------------------------------------------------- + +// typedef: indices.delete_alias.IndicesAliasesResponseBody + +/** + * + * @see API + * specification + */ + +public abstract class IndicesAliasesResponseBody extends AcknowledgedResponseBase { + @Nullable + private final Boolean errors; + + // --------------------------------------------------------------------------------------------- + + protected IndicesAliasesResponseBody(AbstractBuilder builder) { + super(builder); + + this.errors = builder.errors; + + } + + /** + * API name: {@code errors} + */ + @Nullable + public final Boolean errors() { + return this.errors; + } + + protected void serializeInternal(JsonGenerator generator, JsonpMapper mapper) { + + super.serializeInternal(generator, mapper); + if (this.errors != null) { + generator.writeKey("errors"); + generator.write(this.errors); + + } + + } + + public abstract static class AbstractBuilder> + extends + AcknowledgedResponseBase.AbstractBuilder { + @Nullable + private Boolean errors; + + /** + * API name: {@code errors} + */ + public final BuilderT errors(@Nullable Boolean value) { + this.errors = value; + return self(); + } + + } + + // --------------------------------------------------------------------------------------------- + protected static > void setupIndicesAliasesResponseBodyDeserializer( + ObjectDeserializer op) { + AcknowledgedResponseBase.setupAcknowledgedResponseBaseDeserializer(op); + op.add(AbstractBuilder::errors, JsonpDeserializer.booleanDeserializer(), "errors"); + + } + +} diff --git a/java-client/src/main/java/co/elastic/clients/elasticsearch/watcher/ChainInput.java b/java-client/src/main/java/co/elastic/clients/elasticsearch/watcher/ChainInput.java index 3b1d712b3..639399926 100644 --- a/java-client/src/main/java/co/elastic/clients/elasticsearch/watcher/ChainInput.java +++ b/java-client/src/main/java/co/elastic/clients/elasticsearch/watcher/ChainInput.java @@ -146,6 +146,7 @@ public final Builder inputs(List> list) { *

* Adds one or more values to inputs. */ + @SafeVarargs public final Builder inputs(NamedValue value, NamedValue... values) { this.inputs = _listAdd(this.inputs, value, values); return this; From 119cb450b13cd40bc74f34601199925002e470e7 Mon Sep 17 00:00:00 2001 From: Laura Trotta Date: Tue, 12 Aug 2025 15:45:37 +0200 Subject: [PATCH 5/5] fix error status code in sniff test --- .../low_level/sniffer/ElasticsearchNodesSnifferTests.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/java-client/src/test/java/co/elastic/clients/transport/rest5_client/low_level/sniffer/ElasticsearchNodesSnifferTests.java b/java-client/src/test/java/co/elastic/clients/transport/rest5_client/low_level/sniffer/ElasticsearchNodesSnifferTests.java index 4cb820e04..02f90181a 100644 --- a/java-client/src/test/java/co/elastic/clients/transport/rest5_client/low_level/sniffer/ElasticsearchNodesSnifferTests.java +++ b/java-client/src/test/java/co/elastic/clients/transport/rest5_client/low_level/sniffer/ElasticsearchNodesSnifferTests.java @@ -373,6 +373,6 @@ static SniffResponse buildResponse(String nodesInfoBody, List nodes) { } private static int randomErrorResponseCode() { - return randomIntBetween(400, 599); + return randomIntBetween(500, 599); } }