Examples of externalTransportAddress()


Examples of org.elasticsearch.test.CompositeTestCluster.externalTransportAddress()

        Settings settings = ImmutableSettings.builder().put(requiredSettings()).put("client.transport.nodes_sampler_interval", "1s")
                .put("name", "transport_client_sniff_mode").put(ClusterName.SETTING, cluster().getClusterName())
                .put("client.transport.sniff", true).build();

        CompositeTestCluster compositeTestCluster = backwardsCluster();
        TransportAddress transportAddress = compositeTestCluster.externalTransportAddress();

        try(TransportClient client = new TransportClient(settings)) {
            client.addTransportAddress(transportAddress);

            assertAcked(client.admin().indices().prepareCreate("test"));
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.