Package org.elasticsearch.action.admin.cluster.node.info

Examples of org.elasticsearch.action.admin.cluster.node.info.NodesInfoResponse.nodes()


        startNode("server2");
        String server1NodeId = ((InternalNode) node("server1")).injector().getInstance(ClusterService.class).state().nodes().localNodeId();
        String server2NodeId = ((InternalNode) node("server2")).injector().getInstance(ClusterService.class).state().nodes().localNodeId();

        NodesInfoResponse response = client("server1").admin().cluster().prepareNodesInfo().execute().actionGet();
        assertThat(response.nodes().length, equalTo(2));
        assertThat(response.nodesMap().get(server1NodeId), notNullValue());
        assertThat(response.nodesMap().get(server2NodeId), notNullValue());

        response = client("server2").admin().cluster().nodesInfo(nodesInfoRequest()).actionGet();
        assertThat(response.nodes().length, equalTo(2));
View Full Code Here


        assertThat(response.nodes().length, equalTo(2));
        assertThat(response.nodesMap().get(server1NodeId), notNullValue());
        assertThat(response.nodesMap().get(server2NodeId), notNullValue());

        response = client("server2").admin().cluster().nodesInfo(nodesInfoRequest()).actionGet();
        assertThat(response.nodes().length, equalTo(2));
        assertThat(response.nodesMap().get(server1NodeId), notNullValue());
        assertThat(response.nodesMap().get(server2NodeId), notNullValue());

        response = client("server1").admin().cluster().nodesInfo(nodesInfoRequest(server1NodeId)).actionGet();
        assertThat(response.nodes().length, equalTo(1));
View Full Code Here

        assertThat(response.nodes().length, equalTo(2));
        assertThat(response.nodesMap().get(server1NodeId), notNullValue());
        assertThat(response.nodesMap().get(server2NodeId), notNullValue());

        response = client("server1").admin().cluster().nodesInfo(nodesInfoRequest(server1NodeId)).actionGet();
        assertThat(response.nodes().length, equalTo(1));
        assertThat(response.nodesMap().get(server1NodeId), notNullValue());

        response = client("server2").admin().cluster().nodesInfo(nodesInfoRequest(server1NodeId)).actionGet();
        assertThat(response.nodes().length, equalTo(1));
        assertThat(response.nodesMap().get(server1NodeId), notNullValue());
View Full Code Here

        response = client("server1").admin().cluster().nodesInfo(nodesInfoRequest(server1NodeId)).actionGet();
        assertThat(response.nodes().length, equalTo(1));
        assertThat(response.nodesMap().get(server1NodeId), notNullValue());

        response = client("server2").admin().cluster().nodesInfo(nodesInfoRequest(server1NodeId)).actionGet();
        assertThat(response.nodes().length, equalTo(1));
        assertThat(response.nodesMap().get(server1NodeId), notNullValue());

        response = client("server1").admin().cluster().nodesInfo(nodesInfoRequest(server2NodeId)).actionGet();
        assertThat(response.nodes().length, equalTo(1));
        assertThat(response.nodesMap().get(server2NodeId), notNullValue());
View Full Code Here

        response = client("server2").admin().cluster().nodesInfo(nodesInfoRequest(server1NodeId)).actionGet();
        assertThat(response.nodes().length, equalTo(1));
        assertThat(response.nodesMap().get(server1NodeId), notNullValue());

        response = client("server1").admin().cluster().nodesInfo(nodesInfoRequest(server2NodeId)).actionGet();
        assertThat(response.nodes().length, equalTo(1));
        assertThat(response.nodesMap().get(server2NodeId), notNullValue());

        response = client("server2").admin().cluster().nodesInfo(nodesInfoRequest(server2NodeId)).actionGet();
        assertThat(response.nodes().length, equalTo(1));
        assertThat(response.nodesMap().get(server2NodeId), notNullValue());
View Full Code Here

        response = client("server1").admin().cluster().nodesInfo(nodesInfoRequest(server2NodeId)).actionGet();
        assertThat(response.nodes().length, equalTo(1));
        assertThat(response.nodesMap().get(server2NodeId), notNullValue());

        response = client("server2").admin().cluster().nodesInfo(nodesInfoRequest(server2NodeId)).actionGet();
        assertThat(response.nodes().length, equalTo(1));
        assertThat(response.nodesMap().get(server2NodeId), notNullValue());
    }
}
View Full Code Here

        // Looking for nodes configuration
        if (log.isInfoEnabled()) {
            final NodesInfoResponse nir =
                    client().admin().cluster().prepareNodesInfo().execute().actionGet();

            log.info("Elasticsearch client is now connected to the " + nir.nodes().length + " node(s) cluster named \""
                    + nir.clusterName() + "\"");
        }
    }

    @PreDestroy
View Full Code Here

        if (log.isInfoEnabled()) {
            NodesInfoResponse nir =
                    client.admin().cluster().nodesInfo(new NodesInfoRequest()).actionGet();

            log.info("Elasticsearch client is now connected to the " + nir.nodes().length + " node(s) cluster named \""
                    + nir.clusterName() + "\"");
        }
    }

    @PreDestroy
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.