From e1488a0fc7ddc2ba01ca72f92409c8a6dd92a10c Mon Sep 17 00:00:00 2001 From: Ryan Ernst Date: Sat, 3 Feb 2024 20:48:11 -0800 Subject: [PATCH] Fix compilation of example rest handler (#105101) --- .../example/resthandler/ExampleRestHandlerPlugin.java | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/plugins/examples/rest-handler/src/main/java/org/elasticsearch/example/resthandler/ExampleRestHandlerPlugin.java b/plugins/examples/rest-handler/src/main/java/org/elasticsearch/example/resthandler/ExampleRestHandlerPlugin.java index e142ba80147e..a820973c19ca 100644 --- a/plugins/examples/rest-handler/src/main/java/org/elasticsearch/example/resthandler/ExampleRestHandlerPlugin.java +++ b/plugins/examples/rest-handler/src/main/java/org/elasticsearch/example/resthandler/ExampleRestHandlerPlugin.java @@ -15,12 +15,14 @@ import org.elasticsearch.common.settings.ClusterSettings; import org.elasticsearch.common.settings.IndexScopedSettings; import org.elasticsearch.common.settings.Settings; import org.elasticsearch.common.settings.SettingsFilter; +import org.elasticsearch.features.NodeFeature; import org.elasticsearch.plugins.ActionPlugin; import org.elasticsearch.plugins.Plugin; import org.elasticsearch.rest.RestController; import org.elasticsearch.rest.RestHandler; import java.util.List; +import java.util.function.Predicate; import java.util.function.Supplier; import static java.util.Collections.singletonList; @@ -35,8 +37,8 @@ public class ExampleRestHandlerPlugin extends Plugin implements ActionPlugin { final IndexScopedSettings indexScopedSettings, final SettingsFilter settingsFilter, final IndexNameExpressionResolver indexNameExpressionResolver, - final Supplier nodesInCluster) { - + final Supplier nodesInCluster, + final Predicate clusterSupportsFeature) { return singletonList(new ExampleCatAction()); } }