From 6e4f3cf42dfb139637505c02c255fd1455d118ae Mon Sep 17 00:00:00 2001 From: Simon Willnauer Date: Thu, 27 Nov 2014 16:19:26 +0100 Subject: [PATCH] [CLIENT] Only fetch the node info during node sampling Today we are fetching a lot of information that is unneeded for the sampling phase. We only really need the DiscoveryNode to ensure the node is still there. This commit clears all flags to be false on the NodeInfo call. --- .../client/transport/TransportClientNodesService.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/java/org/elasticsearch/client/transport/TransportClientNodesService.java b/src/main/java/org/elasticsearch/client/transport/TransportClientNodesService.java index 37d3ed137e0..eaa2884dc6f 100644 --- a/src/main/java/org/elasticsearch/client/transport/TransportClientNodesService.java +++ b/src/main/java/org/elasticsearch/client/transport/TransportClientNodesService.java @@ -348,7 +348,7 @@ public class TransportClientNodesService extends AbstractComponent { } try { NodesInfoResponse nodeInfo = transportService.submitRequest(listedNode, NodesInfoAction.NAME, - headers.applyTo(Requests.nodesInfoRequest("_local")), + headers.applyTo(Requests.nodesInfoRequest("_local").clear()), TransportRequestOptions.options().withType(TransportRequestOptions.Type.STATE).withTimeout(pingTimeout), new FutureTransportResponseHandler() { @Override