diff --git a/plugins/ingest/src/main/java/org/elasticsearch/plugin/ingest/IngestPlugin.java b/plugins/ingest/src/main/java/org/elasticsearch/plugin/ingest/IngestPlugin.java index 9dfbf314499..11365167732 100644 --- a/plugins/ingest/src/main/java/org/elasticsearch/plugin/ingest/IngestPlugin.java +++ b/plugins/ingest/src/main/java/org/elasticsearch/plugin/ingest/IngestPlugin.java @@ -22,6 +22,7 @@ package org.elasticsearch.plugin.ingest; import org.elasticsearch.action.ActionModule; import org.elasticsearch.client.Client; +import org.elasticsearch.client.transport.TransportClient; import org.elasticsearch.common.component.LifecycleComponent; import org.elasticsearch.common.inject.Module; import org.elasticsearch.common.settings.Settings; @@ -56,7 +57,7 @@ public class IngestPlugin extends Plugin { public IngestPlugin(Settings nodeSettings) { this.nodeSettings = nodeSettings; - transportClient = "transport".equals(nodeSettings.get(Client.CLIENT_TYPE_SETTING)); + transportClient = TransportClient.CLIENT_TYPE.equals(nodeSettings.get(Client.CLIENT_TYPE_SETTING)); } @Override @@ -95,7 +96,7 @@ public class IngestPlugin extends Plugin { } public void onModule(ActionModule module) { - if (!transportClient) { + if (transportClient == false) { module.registerFilter(IngestActionFilter.class); } module.registerAction(PutPipelineAction.INSTANCE, PutPipelineTransportAction.class); @@ -108,5 +109,4 @@ public class IngestPlugin extends Plugin { restModule.addRestAction(RestGetPipelineAction.class); restModule.addRestAction(RestDeletePipelineAction.class); } - }