Package org.elasticsearch.action.admin.indices.warmer.get

Examples of org.elasticsearch.action.admin.indices.warmer.get.GetWarmersRequest


    public void handleRequest(final RestRequest request, final RestChannel channel, final Client client) {
        final String[] indices = Strings.splitStringByCommaToArray(request.param("index"));
        final String[] types = Strings.splitStringByCommaToArray(request.param("type"));
        final String[] names = request.paramAsStringArray("name", Strings.EMPTY_ARRAY);

        GetWarmersRequest getWarmersRequest = new GetWarmersRequest();
        getWarmersRequest.indices(indices).types(types).warmers(names);
        getWarmersRequest.local(request.paramAsBoolean("local", getWarmersRequest.local()));
        getWarmersRequest.indicesOptions(IndicesOptions.fromRequest(request, getWarmersRequest.indicesOptions()));
        client.admin().indices().getWarmers(getWarmersRequest, new RestBuilderListener<GetWarmersResponse>(channel) {

            @Override
            public RestResponse buildResponse(GetWarmersResponse response, XContentBuilder builder) throws Exception {
                if (indices.length > 0 && response.warmers().isEmpty()) {
View Full Code Here

TOP

Related Classes of org.elasticsearch.action.admin.indices.warmer.get.GetWarmersRequest

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.