Class ElasticsearchAsyncSearchAsyncClient
java.lang.Object
co.elastic.clients.base.ApiClient
co.elastic.clients.elasticsearch.async_search.ElasticsearchAsyncSearchAsyncClient
public class ElasticsearchAsyncSearchAsyncClient extends ApiClient
Client for the async_search namespace.
-
Field Summary
-
Constructor Summary
Constructors Constructor Description ElasticsearchAsyncSearchAsyncClient(Transport transport)
-
Method Summary
Modifier and Type Method Description java.util.concurrent.CompletableFuture<DeleteResponse>
delete(DeleteRequest request)
Deletes an async search by ID.java.util.concurrent.CompletableFuture<DeleteResponse>
delete(java.util.function.Function<DeleteRequest.Builder,ObjectBuilder<DeleteRequest>> fn)
Deletes an async search by ID.<TDocument>
java.util.concurrent.CompletableFuture<GetResponse<TDocument>>get(GetRequest request, java.lang.Class<TDocument> tDocumentClass)
Retrieves the results of a previously submitted async search request given its ID.<TDocument>
java.util.concurrent.CompletableFuture<GetResponse<TDocument>>get(java.util.function.Function<GetRequest.Builder,ObjectBuilder<GetRequest>> fn, java.lang.Class<TDocument> tDocumentClass)
Retrieves the results of a previously submitted async search request given its ID.<TDocument>
java.util.concurrent.CompletableFuture<StatusResponse<TDocument>>status(StatusRequest request, java.lang.Class<TDocument> tDocumentClass)
Retrieves the status of a previously submitted async search request given its ID.<TDocument>
java.util.concurrent.CompletableFuture<StatusResponse<TDocument>>status(java.util.function.Function<StatusRequest.Builder,ObjectBuilder<StatusRequest>> fn, java.lang.Class<TDocument> tDocumentClass)
Retrieves the status of a previously submitted async search request given its ID.<TDocument>
java.util.concurrent.CompletableFuture<SubmitResponse<TDocument>>submit(SubmitRequest request, java.lang.Class<TDocument> tDocumentClass)
Executes a search request asynchronously.<TDocument>
java.util.concurrent.CompletableFuture<SubmitResponse<TDocument>>submit(java.util.function.Function<SubmitRequest.Builder,ObjectBuilder<SubmitRequest>> fn, java.lang.Class<TDocument> tDocumentClass)
Executes a search request asynchronously.Methods inherited from class co.elastic.clients.base.ApiClient
_transport, getDeserializer
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Constructor Details
-
ElasticsearchAsyncSearchAsyncClient
-
-
Method Details
-
delete
public java.util.concurrent.CompletableFuture<DeleteResponse> delete(DeleteRequest request) throws java.io.IOExceptionDeletes an async search by ID. If the search is still running, the search request will be cancelled. Otherwise, the saved search results are deleted.- Throws:
java.io.IOException
- See Also:
- Documentation on elastic.co
-
delete
public final java.util.concurrent.CompletableFuture<DeleteResponse> delete(java.util.function.Function<DeleteRequest.Builder,ObjectBuilder<DeleteRequest>> fn) throws java.io.IOExceptionDeletes an async search by ID. If the search is still running, the search request will be cancelled. Otherwise, the saved search results are deleted.- Parameters:
fn
- a function that initializes a freshly created builder. This function can either return its builder argument after having set its properties or return another builder.- Throws:
java.io.IOException
- See Also:
- Documentation on elastic.co
-
get
public <TDocument> java.util.concurrent.CompletableFuture<GetResponse<TDocument>> get(GetRequest request, java.lang.Class<TDocument> tDocumentClass) throws java.io.IOExceptionRetrieves the results of a previously submitted async search request given its ID.- Throws:
java.io.IOException
- See Also:
- Documentation on elastic.co
-
get
public final <TDocument> java.util.concurrent.CompletableFuture<GetResponse<TDocument>> get(java.util.function.Function<GetRequest.Builder,ObjectBuilder<GetRequest>> fn, java.lang.Class<TDocument> tDocumentClass) throws java.io.IOExceptionRetrieves the results of a previously submitted async search request given its ID.- Parameters:
fn
- a function that initializes a freshly created builder. This function can either return its builder argument after having set its properties or return another builder.- Throws:
java.io.IOException
- See Also:
- Documentation on elastic.co
-
status
public <TDocument> java.util.concurrent.CompletableFuture<StatusResponse<TDocument>> status(StatusRequest request, java.lang.Class<TDocument> tDocumentClass) throws java.io.IOExceptionRetrieves the status of a previously submitted async search request given its ID.- Throws:
java.io.IOException
- See Also:
- Documentation on elastic.co
-
status
public final <TDocument> java.util.concurrent.CompletableFuture<StatusResponse<TDocument>> status(java.util.function.Function<StatusRequest.Builder,ObjectBuilder<StatusRequest>> fn, java.lang.Class<TDocument> tDocumentClass) throws java.io.IOExceptionRetrieves the status of a previously submitted async search request given its ID.- Parameters:
fn
- a function that initializes a freshly created builder. This function can either return its builder argument after having set its properties or return another builder.- Throws:
java.io.IOException
- See Also:
- Documentation on elastic.co
-
submit
public <TDocument> java.util.concurrent.CompletableFuture<SubmitResponse<TDocument>> submit(SubmitRequest request, java.lang.Class<TDocument> tDocumentClass) throws java.io.IOExceptionExecutes a search request asynchronously.- Throws:
java.io.IOException
- See Also:
- Documentation on elastic.co
-
submit
public final <TDocument> java.util.concurrent.CompletableFuture<SubmitResponse<TDocument>> submit(java.util.function.Function<SubmitRequest.Builder,ObjectBuilder<SubmitRequest>> fn, java.lang.Class<TDocument> tDocumentClass) throws java.io.IOExceptionExecutes a search request asynchronously.- Parameters:
fn
- a function that initializes a freshly created builder. This function can either return its builder argument after having set its properties or return another builder.- Throws:
java.io.IOException
- See Also:
- Documentation on elastic.co
-