Remove DiscoveryNode#id in favour of existing DiscoveryNode#getId

Original commit: elastic/x-pack-elasticsearch@69bd4a9640
This commit is contained in:
javanna 2016-03-30 14:42:13 +02:00 committed by Luca Cavanna
parent b056fed38b
commit 770de79a92
4 changed files with 4 additions and 4 deletions

View File

@ -84,7 +84,7 @@ public class NodeStatsCollector extends AbstractCollector<NodeStatsCollector> {
nodeStatsDoc.setClusterUUID(clusterUUID());
nodeStatsDoc.setTimestamp(System.currentTimeMillis());
nodeStatsDoc.setSourceNode(sourceNode);
nodeStatsDoc.setNodeId(sourceNode.id());
nodeStatsDoc.setNodeId(sourceNode.getId());
nodeStatsDoc.setNodeMaster(isLocalNodeMaster());
nodeStatsDoc.setNodeStats(nodeStats);
nodeStatsDoc.setMlockall(BootstrapInfo.isMemoryLocked());

View File

@ -38,7 +38,7 @@ public class ClusterStateResolverTests extends MonitoringIndexNameResolverTestCa
DiscoveryNode masterNode = new DiscoveryNode("master", new LocalTransportAddress("master"),
emptyMap(), emptySet(), Version.CURRENT);
DiscoveryNode otherNode = new DiscoveryNode("other", new LocalTransportAddress("other"), emptyMap(), emptySet(), Version.CURRENT);
DiscoveryNodes discoveryNodes = DiscoveryNodes.builder().put(masterNode).put(otherNode).masterNodeId(masterNode.id()).build();
DiscoveryNodes discoveryNodes = DiscoveryNodes.builder().put(masterNode).put(otherNode).masterNodeId(masterNode.getId()).build();
ClusterState clusterState = ClusterState.builder(new ClusterName("test")).nodes(discoveryNodes).build();
doc.setClusterState(clusterState);
return doc;

View File

@ -53,7 +53,7 @@ public class ClearRealmCacheResponse extends BaseNodesResponse<ClearRealmCacheRe
builder.field("cluster_name", getClusterName().value());
builder.startObject("nodes");
for (ClearRealmCacheResponse.Node node: getNodes()) {
builder.startObject(node.getNode().id());
builder.startObject(node.getNode().getId());
builder.field("name", node.getNode().name());
builder.endObject();
}

View File

@ -53,7 +53,7 @@ public class ClearRolesCacheResponse extends BaseNodesResponse<ClearRolesCacheRe
builder.field("cluster_name", getClusterName().value());
builder.startObject("nodes");
for (ClearRolesCacheResponse.Node node: getNodes()) {
builder.startObject(node.getNode().id());
builder.startObject(node.getNode().getId());
builder.field("name", node.getNode().name());
builder.endObject();
}