From b9eda3bd2f962734105f5283390a3c524dde8e14 Mon Sep 17 00:00:00 2001 From: Serhii Plyhun Date: Wed, 19 Jun 2024 16:50:29 +0200 Subject: [PATCH 1/2] GPU-1602: No more deprecated logging --- .../java/com/gentics/elasticsearch/AbstractDockerTest.java | 7 ------- 1 file changed, 7 deletions(-) diff --git a/src/test/java/com/gentics/elasticsearch/AbstractDockerTest.java b/src/test/java/com/gentics/elasticsearch/AbstractDockerTest.java index b13192e..125c0a9 100644 --- a/src/test/java/com/gentics/elasticsearch/AbstractDockerTest.java +++ b/src/test/java/com/gentics/elasticsearch/AbstractDockerTest.java @@ -7,16 +7,9 @@ import com.gentics.elasticsearch.docker.ElasticsearchContainer; import io.vertx.core.json.JsonObject; -import io.vertx.core.logging.LoggerFactory; -import io.vertx.core.logging.SLF4JLogDelegateFactory; public class AbstractDockerTest { - static { - // Use slf4j instead of JUL - System.setProperty(LoggerFactory.LOGGER_DELEGATE_FACTORY_CLASS_NAME, SLF4JLogDelegateFactory.class.getName()); - } - @ClassRule public static ElasticsearchContainer elasticsearch = new ElasticsearchContainer(true); From 8c106f653a179744ac398d0ef328284746eb71a9 Mon Sep 17 00:00:00 2001 From: Serhii Plyhun Date: Fri, 6 Dec 2024 15:25:42 +0100 Subject: [PATCH 2/2] PUT cluster/settings --- .../elasticsearch/client/methods/ClusterMethods.java | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/src/main/java/com/gentics/elasticsearch/client/methods/ClusterMethods.java b/src/main/java/com/gentics/elasticsearch/client/methods/ClusterMethods.java index 4536526..77884bb 100644 --- a/src/main/java/com/gentics/elasticsearch/client/methods/ClusterMethods.java +++ b/src/main/java/com/gentics/elasticsearch/client/methods/ClusterMethods.java @@ -2,7 +2,6 @@ import static com.gentics.elasticsearch.client.ClientUtility.join; -import com.gentics.elasticsearch.client.HttpErrorException; import com.gentics.elasticsearch.client.okhttp.RequestBuilder; /** @@ -25,4 +24,13 @@ default RequestBuilder nodesInfo(String... nodeIds) { return getBuilder(path); } + /** + * Update the cluster settings + * + * @param settings + * @return + */ + default RequestBuilder settings(T settings) { + return putBuilder("_cluster/settings", settings); + } }