org.elasticsearch.client.UpdateByQueryClientWrapper Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of elasticsearch-action-updatebyquery Show documentation
Show all versions of elasticsearch-action-updatebyquery Show documentation
The Update By Query feature, as an action plugin for ElasticSearch.
package org.elasticsearch.client;
import org.elasticsearch.action.ActionFuture;
import org.elasticsearch.action.ActionListener;
import org.elasticsearch.action.updatebyquery.UpdateByQueryAction;
import org.elasticsearch.action.updatebyquery.UpdateByQueryRequest;
import org.elasticsearch.action.updatebyquery.UpdateByQueryRequestBuilder;
import org.elasticsearch.action.updatebyquery.UpdateByQueryResponse;
public class UpdateByQueryClientWrapper implements UpdateByQueryClient {
protected final Client client;
public UpdateByQueryClientWrapper(Client client) {
this.client = client;
}
@Override
public void updateByQuery(UpdateByQueryRequest request, ActionListener listener) {
client.execute(UpdateByQueryAction.INSTANCE, request, listener);
}
@Override
public ActionFuture updateByQuery(UpdateByQueryRequest request) {
return client.execute(UpdateByQueryAction.INSTANCE, request);
}
@Override
public UpdateByQueryRequestBuilder prepareUpdateByQuery() {
return new UpdateByQueryRequestBuilder(client);
}
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy