Package org.elasticsearch.action.admin.indices.status

Examples of org.elasticsearch.action.admin.indices.status.IndicesStatusRequest


     * @param indices The indices to query status about. Use <tt>null</tt> or <tt>_all</tt> to execute against all indices
     * @return The indices status request
     * @see org.elasticsearch.client.IndicesAdminClient#status(org.elasticsearch.action.admin.indices.status.IndicesStatusRequest)
     */
    public static IndicesStatusRequest indicesStatusRequest(String... indices) {
        return new IndicesStatusRequest(indices);
    }
View Full Code Here


* @author kimchy (shay.banon)
*/
public class IndicesStatusRequestBuilder extends BaseIndicesRequestBuilder<IndicesStatusRequest, IndicesStatusResponse> {

    public IndicesStatusRequestBuilder(IndicesAdminClient indicesClient) {
        super(indicesClient, new IndicesStatusRequest());
    }
View Full Code Here

        this.settingsFilter = settingsFilter;
    }

    @Override public void handleRequest(final RestRequest request, final RestChannel channel) {
        IndicesStatusRequest indicesStatusRequest = new IndicesStatusRequest(splitIndices(request.param("index")));
        // we just send back a response, no need to fork a listener
        indicesStatusRequest.listenerThreaded(false);
        indicesStatusRequest.recovery(request.paramAsBoolean("recovery", indicesStatusRequest.recovery()));
        indicesStatusRequest.snapshot(request.paramAsBoolean("snapshot", indicesStatusRequest.snapshot()));
        BroadcastOperationThreading operationThreading = BroadcastOperationThreading.fromString(request.param("operation_threading"), BroadcastOperationThreading.SINGLE_THREAD);
        if (operationThreading == BroadcastOperationThreading.NO_THREADS) {
            // since we don't spawn, don't allow no_threads, but change it to a single thread
            operationThreading = BroadcastOperationThreading.SINGLE_THREAD;
        }
        indicesStatusRequest.operationThreading(operationThreading);
        client.admin().indices().status(indicesStatusRequest, new ActionListener<IndicesStatusResponse>() {
            @Override public void onResponse(IndicesStatusResponse response) {
                try {
                    XContentBuilder builder = RestXContentBuilder.restContentBuilder(request);
                    builder.startObject();
View Full Code Here

*/
@SuppressWarnings("unused")
public class StatusRequestBuilder<JsonInput, JsonOutput> extends AbstractRequestBuilderJsonOutput<IndicesStatusRequest, IndicesStatusResponse, JsonInput, JsonOutput> {

    public StatusRequestBuilder(Client client, JsonToString<JsonInput> jsonToString, StringToJson<JsonOutput> stringToJson) {
        super(client, new IndicesStatusRequest(), jsonToString, stringToJson);
    }
View Full Code Here

TOP

Related Classes of org.elasticsearch.action.admin.indices.status.IndicesStatusRequest

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.