Package org.elasticsearch.action.admin.cluster.ping.replication

Examples of org.elasticsearch.action.admin.cluster.ping.replication.ReplicationPingRequest


    public static BroadcastPingRequest pingBroadcastRequest(String... indices) {
        return new BroadcastPingRequest(indices);
    }

    public static ReplicationPingRequest pingReplicationRequest(String... indices) {
        return new ReplicationPingRequest(indices);
    }
View Full Code Here


        controller.registerHandler(RestRequest.Method.GET, "/{index}/_ping/replication", this);
        controller.registerHandler(RestRequest.Method.GET, "/_cluster/{index}/_ping/replication", this);
    }

    @Override public void handleRequest(final RestRequest request, final RestChannel channel) {
        ReplicationPingRequest replicationPingRequest = new ReplicationPingRequest(RestActions.splitIndices(request.param("index")));
        replicationPingRequest.timeout(request.paramAsTime("timeout", ShardReplicationPingRequest.DEFAULT_TIMEOUT));
        replicationPingRequest.listenerThreaded(false);
        String replicationType = request.param("replication");
        if (replicationType != null) {
            replicationPingRequest.replicationType(ReplicationType.fromString(replicationType));
        }
        client.admin().cluster().ping(replicationPingRequest, new ActionListener<ReplicationPingResponse>() {
            @Override public void onResponse(ReplicationPingResponse result) {
                try {
                    XContentBuilder builder = RestXContentBuilder.restContentBuilder(request);
View Full Code Here

* @author kimchy (shay.banon)
*/
public class ReplicationPingRequestBuilder extends BaseClusterRequestBuilder<ReplicationPingRequest, ReplicationPingResponse> {

    public ReplicationPingRequestBuilder(ClusterAdminClient clusterClient) {
        super(clusterClient, new ReplicationPingRequest());
    }
View Full Code Here

TOP

Related Classes of org.elasticsearch.action.admin.cluster.ping.replication.ReplicationPingRequest

Copyright © 2018 www.massapicom. 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.