public interface ReactiveElasticsearchClient
ClientConfiguration
,
ReactiveRestClients
Modifier and Type | Interface and Description |
---|---|
static interface |
ReactiveElasticsearchClient.Indices
Encapsulation of methods for accessing the Indices API.
|
static interface |
ReactiveElasticsearchClient.ReactiveElasticsearchClientCallback
Low level callback interface operating upon
WebClient to send commands towards elasticsearch. |
static interface |
ReactiveElasticsearchClient.Status
Cumulative client
ElasticsearchHost information. |
Modifier and Type | Method and Description |
---|---|
default reactor.core.publisher.Mono<org.elasticsearch.action.bulk.BulkResponse> |
bulk(org.elasticsearch.action.bulk.BulkRequest bulkRequest)
Execute a
BulkRequest against the bulk API. |
default reactor.core.publisher.Mono<org.elasticsearch.action.bulk.BulkResponse> |
bulk(Consumer<org.elasticsearch.action.bulk.BulkRequest> consumer)
Execute a
BulkRequest against the bulk API. |
reactor.core.publisher.Mono<org.elasticsearch.action.bulk.BulkResponse> |
bulk(HttpHeaders headers,
org.elasticsearch.action.bulk.BulkRequest bulkRequest)
Execute a
BulkRequest against the bulk API. |
default reactor.core.publisher.Mono<Long> |
count(Consumer<org.elasticsearch.client.core.CountRequest> consumer)
Execute a
SearchRequest against the count API. |
default reactor.core.publisher.Mono<Long> |
count(org.elasticsearch.client.core.CountRequest countRequest)
Execute a
SearchRequest against the count API. |
reactor.core.publisher.Mono<Long> |
count(HttpHeaders headers,
org.elasticsearch.client.core.CountRequest countRequest)
Execute a
SearchRequest against the count API. |
default reactor.core.publisher.Mono<org.elasticsearch.action.delete.DeleteResponse> |
delete(Consumer<org.elasticsearch.action.delete.DeleteRequest> consumer)
Execute a
DeleteRequest against the delete API to remove a document. |
default reactor.core.publisher.Mono<org.elasticsearch.action.delete.DeleteResponse> |
delete(org.elasticsearch.action.delete.DeleteRequest deleteRequest)
Execute the given
DeleteRequest against the delete API to remove a document. |
reactor.core.publisher.Mono<org.elasticsearch.action.delete.DeleteResponse> |
delete(HttpHeaders headers,
org.elasticsearch.action.delete.DeleteRequest deleteRequest)
Execute the given
DeleteRequest against the delete API to remove a document. |
default reactor.core.publisher.Mono<org.elasticsearch.index.reindex.BulkByScrollResponse> |
deleteBy(Consumer<org.elasticsearch.index.reindex.DeleteByQueryRequest> consumer)
Execute a
DeleteByQueryRequest against the delete by query API. |
default reactor.core.publisher.Mono<org.elasticsearch.index.reindex.BulkByScrollResponse> |
deleteBy(org.elasticsearch.index.reindex.DeleteByQueryRequest deleteRequest)
Execute a
DeleteByQueryRequest against the delete by query API. |
reactor.core.publisher.Mono<org.elasticsearch.index.reindex.BulkByScrollResponse> |
deleteBy(HttpHeaders headers,
org.elasticsearch.index.reindex.DeleteByQueryRequest deleteRequest)
Execute a
DeleteByQueryRequest against the delete by query API. |
reactor.core.publisher.Mono<ClientResponse> |
execute(ReactiveElasticsearchClient.ReactiveElasticsearchClientCallback callback)
Compose the actual command/s to run against Elasticsearch using the underlying
connection . |
default reactor.core.publisher.Mono<Boolean> |
exists(Consumer<org.elasticsearch.action.get.GetRequest> consumer)
Checks for the existence of a document.
|
default reactor.core.publisher.Mono<Boolean> |
exists(org.elasticsearch.action.get.GetRequest getRequest)
Checks for the existence of a document.
|
reactor.core.publisher.Mono<Boolean> |
exists(HttpHeaders headers,
org.elasticsearch.action.get.GetRequest getRequest)
Checks for the existence of a document.
|
default reactor.core.publisher.Mono<org.elasticsearch.index.get.GetResult> |
get(Consumer<org.elasticsearch.action.get.GetRequest> consumer)
Execute a
GetRequest against the get API to retrieve a document by id. |
default reactor.core.publisher.Mono<org.elasticsearch.index.get.GetResult> |
get(org.elasticsearch.action.get.GetRequest getRequest)
Execute the given
GetRequest against the get API to retrieve a document by id. |
reactor.core.publisher.Mono<org.elasticsearch.index.get.GetResult> |
get(HttpHeaders headers,
org.elasticsearch.action.get.GetRequest getRequest)
Execute the given
GetRequest against the get API to retrieve a document by id. |
default reactor.core.publisher.Mono<org.elasticsearch.action.index.IndexResponse> |
index(Consumer<org.elasticsearch.action.index.IndexRequest> consumer)
Execute an
IndexRequest against the index API to index a document. |
reactor.core.publisher.Mono<org.elasticsearch.action.index.IndexResponse> |
index(HttpHeaders headers,
org.elasticsearch.action.index.IndexRequest indexRequest)
Execute the given
IndexRequest against the index API to index a document. |
default reactor.core.publisher.Mono<org.elasticsearch.action.index.IndexResponse> |
index(org.elasticsearch.action.index.IndexRequest indexRequest)
Execute the given
IndexRequest against the index API to index a document. |
ReactiveElasticsearchClient.Indices |
indices()
Gain access to index related commands.
|
default reactor.core.publisher.Mono<org.elasticsearch.action.main.MainResponse> |
info()
Get the cluster info otherwise provided when sending an HTTP request to port 9200.
|
reactor.core.publisher.Mono<org.elasticsearch.action.main.MainResponse> |
info(HttpHeaders headers)
Get the cluster info otherwise provided when sending an HTTP request to port 9200.
|
default reactor.core.publisher.Flux<org.elasticsearch.index.get.GetResult> |
multiGet(Consumer<org.elasticsearch.action.get.MultiGetRequest> consumer)
Execute a
MultiGetRequest against the multi-get API to retrieve multiple documents by id. |
reactor.core.publisher.Flux<org.elasticsearch.index.get.GetResult> |
multiGet(HttpHeaders headers,
org.elasticsearch.action.get.MultiGetRequest multiGetRequest)
Execute the given
MultiGetRequest against the multi-get API to retrieve multiple documents by
id. |
default reactor.core.publisher.Flux<org.elasticsearch.index.get.GetResult> |
multiGet(org.elasticsearch.action.get.MultiGetRequest multiGetRequest)
Execute the given
MultiGetRequest against the multi-get API to retrieve multiple documents by
id. |
default reactor.core.publisher.Mono<Boolean> |
ping()
Pings the remote Elasticsearch cluster and emits true if the ping succeeded, false otherwise.
|
reactor.core.publisher.Mono<Boolean> |
ping(HttpHeaders headers)
Pings the remote Elasticsearch cluster and emits true if the ping succeeded, false otherwise.
|
reactor.core.publisher.Flux<org.elasticsearch.search.SearchHit> |
scroll(HttpHeaders headers,
org.elasticsearch.action.search.SearchRequest searchRequest)
Execute the given
SearchRequest against the search scroll API. |
default reactor.core.publisher.Flux<org.elasticsearch.search.SearchHit> |
scroll(org.elasticsearch.action.search.SearchRequest searchRequest)
Execute the given
SearchRequest against the search scroll API. |
default reactor.core.publisher.Flux<org.elasticsearch.search.SearchHit> |
search(Consumer<org.elasticsearch.action.search.SearchRequest> consumer)
Execute a
SearchRequest against the search API. |
reactor.core.publisher.Flux<org.elasticsearch.search.SearchHit> |
search(HttpHeaders headers,
org.elasticsearch.action.search.SearchRequest searchRequest)
Execute the given
SearchRequest against the search API. |
default reactor.core.publisher.Flux<org.elasticsearch.search.SearchHit> |
search(org.elasticsearch.action.search.SearchRequest searchRequest)
Execute the given
SearchRequest against the search API. |
reactor.core.publisher.Mono<ReactiveElasticsearchClient.Status> |
status()
Get the current client
ReactiveElasticsearchClient.Status . |
default reactor.core.publisher.Mono<org.elasticsearch.action.update.UpdateResponse> |
update(Consumer<org.elasticsearch.action.update.UpdateRequest> consumer)
Execute an
UpdateRequest against the update API to alter a document. |
reactor.core.publisher.Mono<org.elasticsearch.action.update.UpdateResponse> |
update(HttpHeaders headers,
org.elasticsearch.action.update.UpdateRequest updateRequest)
Execute the given
UpdateRequest against the update API to alter a document. |
default reactor.core.publisher.Mono<org.elasticsearch.action.update.UpdateResponse> |
update(org.elasticsearch.action.update.UpdateRequest updateRequest)
Execute the given
UpdateRequest against the update API to alter a document. |
default reactor.core.publisher.Mono<Boolean> ping()
Mono
emitting the result of the ping attempt.reactor.core.publisher.Mono<Boolean> ping(HttpHeaders headers)
headers
- Use HttpHeaders
to provide eg. authentication data. Must not be null.Mono
emitting the result of the ping attempt.default reactor.core.publisher.Mono<org.elasticsearch.action.main.MainResponse> info()
Mono
emitting the result of the info request.reactor.core.publisher.Mono<org.elasticsearch.action.main.MainResponse> info(HttpHeaders headers)
headers
- Use HttpHeaders
to provide eg. authentication data. Must not be null.Mono
emitting the result of the info request.default reactor.core.publisher.Mono<org.elasticsearch.index.get.GetResult> get(Consumer<org.elasticsearch.action.get.GetRequest> consumer)
GetRequest
against the get API to retrieve a document by id.consumer
- never null.Mono
emitting the result
.default reactor.core.publisher.Mono<org.elasticsearch.index.get.GetResult> get(org.elasticsearch.action.get.GetRequest getRequest)
GetRequest
against the get API to retrieve a document by id.getRequest
- must not be null.Mono
emitting the result
.reactor.core.publisher.Mono<org.elasticsearch.index.get.GetResult> get(HttpHeaders headers, org.elasticsearch.action.get.GetRequest getRequest)
GetRequest
against the get API to retrieve a document by id.headers
- Use HttpHeaders
to provide eg. authentication data. Must not be null.getRequest
- must not be null.Mono
emitting the result
.default reactor.core.publisher.Flux<org.elasticsearch.index.get.GetResult> multiGet(Consumer<org.elasticsearch.action.get.MultiGetRequest> consumer)
MultiGetRequest
against the multi-get API to retrieve multiple documents by id.consumer
- never null.Flux
emitting the result
.default reactor.core.publisher.Flux<org.elasticsearch.index.get.GetResult> multiGet(org.elasticsearch.action.get.MultiGetRequest multiGetRequest)
MultiGetRequest
against the multi-get API to retrieve multiple documents by
id.multiGetRequest
- must not be null.Flux
emitting the result
.reactor.core.publisher.Flux<org.elasticsearch.index.get.GetResult> multiGet(HttpHeaders headers, org.elasticsearch.action.get.MultiGetRequest multiGetRequest)
MultiGetRequest
against the multi-get API to retrieve multiple documents by
id.headers
- Use HttpHeaders
to provide eg. authentication data. Must not be null.multiGetRequest
- must not be null.Flux
emitting the result
.default reactor.core.publisher.Mono<Boolean> exists(Consumer<org.elasticsearch.action.get.GetRequest> consumer)
consumer
- never null.Mono
emitting true if it exists, false otherwise.default reactor.core.publisher.Mono<Boolean> exists(org.elasticsearch.action.get.GetRequest getRequest)
getRequest
- must not be null.Mono
emitting true if it exists, false otherwise.reactor.core.publisher.Mono<Boolean> exists(HttpHeaders headers, org.elasticsearch.action.get.GetRequest getRequest)
headers
- Use HttpHeaders
to provide eg. authentication data. Must not be null.getRequest
- must not be null.Mono
emitting true if it exists, false otherwise.default reactor.core.publisher.Mono<org.elasticsearch.action.index.IndexResponse> index(Consumer<org.elasticsearch.action.index.IndexRequest> consumer)
IndexRequest
against the index API to index a document.consumer
- never null.Mono
emitting the IndexResponse
.default reactor.core.publisher.Mono<org.elasticsearch.action.index.IndexResponse> index(org.elasticsearch.action.index.IndexRequest indexRequest)
IndexRequest
against the index API to index a document.indexRequest
- must not be null.Mono
emitting the IndexResponse
.reactor.core.publisher.Mono<org.elasticsearch.action.index.IndexResponse> index(HttpHeaders headers, org.elasticsearch.action.index.IndexRequest indexRequest)
IndexRequest
against the index API to index a document.headers
- Use HttpHeaders
to provide eg. authentication data. Must not be null.indexRequest
- must not be null.Mono
emitting the IndexResponse
.ReactiveElasticsearchClient.Indices indices()
default reactor.core.publisher.Mono<org.elasticsearch.action.update.UpdateResponse> update(Consumer<org.elasticsearch.action.update.UpdateRequest> consumer)
UpdateRequest
against the update API to alter a document.consumer
- never null.Mono
emitting the UpdateResponse
.default reactor.core.publisher.Mono<org.elasticsearch.action.update.UpdateResponse> update(org.elasticsearch.action.update.UpdateRequest updateRequest)
UpdateRequest
against the update API to alter a document.updateRequest
- must not be null.Mono
emitting the UpdateResponse
.reactor.core.publisher.Mono<org.elasticsearch.action.update.UpdateResponse> update(HttpHeaders headers, org.elasticsearch.action.update.UpdateRequest updateRequest)
UpdateRequest
against the update API to alter a document.headers
- Use HttpHeaders
to provide eg. authentication data. Must not be null.updateRequest
- must not be null.Mono
emitting the UpdateResponse
.default reactor.core.publisher.Mono<org.elasticsearch.action.delete.DeleteResponse> delete(Consumer<org.elasticsearch.action.delete.DeleteRequest> consumer)
DeleteRequest
against the delete API to remove a document.consumer
- never null.Mono
emitting the DeleteResponse
.default reactor.core.publisher.Mono<org.elasticsearch.action.delete.DeleteResponse> delete(org.elasticsearch.action.delete.DeleteRequest deleteRequest)
DeleteRequest
against the delete API to remove a document.deleteRequest
- must not be null.Mono
emitting the DeleteResponse
.reactor.core.publisher.Mono<org.elasticsearch.action.delete.DeleteResponse> delete(HttpHeaders headers, org.elasticsearch.action.delete.DeleteRequest deleteRequest)
DeleteRequest
against the delete API to remove a document.headers
- Use HttpHeaders
to provide eg. authentication data. Must not be null.deleteRequest
- must not be null.Mono
emitting the DeleteResponse
.default reactor.core.publisher.Mono<Long> count(Consumer<org.elasticsearch.client.core.CountRequest> consumer)
SearchRequest
against the count API.consumer
- new null.Mono
emitting the count result.default reactor.core.publisher.Mono<Long> count(org.elasticsearch.client.core.CountRequest countRequest)
SearchRequest
against the count API.countRequest
- must not be null.Mono
emitting the count result.reactor.core.publisher.Mono<Long> count(HttpHeaders headers, org.elasticsearch.client.core.CountRequest countRequest)
SearchRequest
against the count API.headers
- Use HttpHeaders
to provide eg. authentication data. Must not be null.countRequest
- must not be null.Mono
emitting the count result.default reactor.core.publisher.Flux<org.elasticsearch.search.SearchHit> search(Consumer<org.elasticsearch.action.search.SearchRequest> consumer)
SearchRequest
against the search API.consumer
- never null.Flux
emitting hits
one by one.default reactor.core.publisher.Flux<org.elasticsearch.search.SearchHit> search(org.elasticsearch.action.search.SearchRequest searchRequest)
SearchRequest
against the search API.searchRequest
- must not be null.Flux
emitting hits
one by one.reactor.core.publisher.Flux<org.elasticsearch.search.SearchHit> search(HttpHeaders headers, org.elasticsearch.action.search.SearchRequest searchRequest)
SearchRequest
against the search API.headers
- Use HttpHeaders
to provide eg. authentication data. Must not be null.searchRequest
- must not be null.Flux
emitting hits
one by one.default reactor.core.publisher.Flux<org.elasticsearch.search.SearchHit> scroll(org.elasticsearch.action.search.SearchRequest searchRequest)
SearchRequest
against the search scroll API.searchRequest
- must not be null.Flux
emitting hits
one by one.reactor.core.publisher.Flux<org.elasticsearch.search.SearchHit> scroll(HttpHeaders headers, org.elasticsearch.action.search.SearchRequest searchRequest)
SearchRequest
against the search scroll API. scrollIds
returned by the server and provides them when
requesting more results via _search/scroll
. All bound server resources are freed on completion.headers
- Use HttpHeaders
to provide eg. authentication data. Must not be null.searchRequest
- must not be null.Flux
emitting hits
one by one.default reactor.core.publisher.Mono<org.elasticsearch.index.reindex.BulkByScrollResponse> deleteBy(Consumer<org.elasticsearch.index.reindex.DeleteByQueryRequest> consumer)
DeleteByQueryRequest
against the delete by query API.consumer
- never null.Mono
emitting the emitting operation response.default reactor.core.publisher.Mono<org.elasticsearch.index.reindex.BulkByScrollResponse> deleteBy(org.elasticsearch.index.reindex.DeleteByQueryRequest deleteRequest)
DeleteByQueryRequest
against the delete by query API.deleteRequest
- must not be null.Mono
emitting the emitting operation response.reactor.core.publisher.Mono<org.elasticsearch.index.reindex.BulkByScrollResponse> deleteBy(HttpHeaders headers, org.elasticsearch.index.reindex.DeleteByQueryRequest deleteRequest)
DeleteByQueryRequest
against the delete by query API.headers
- Use HttpHeaders
to provide eg. authentication data. Must not be null.deleteRequest
- must not be null.Mono
emitting operation response.default reactor.core.publisher.Mono<org.elasticsearch.action.bulk.BulkResponse> bulk(Consumer<org.elasticsearch.action.bulk.BulkRequest> consumer)
BulkRequest
against the bulk API.consumer
- never null.Mono
emitting the emitting operation response.default reactor.core.publisher.Mono<org.elasticsearch.action.bulk.BulkResponse> bulk(org.elasticsearch.action.bulk.BulkRequest bulkRequest)
BulkRequest
against the bulk API.bulkRequest
- must not be null.Mono
emitting the emitting operation response.reactor.core.publisher.Mono<org.elasticsearch.action.bulk.BulkResponse> bulk(HttpHeaders headers, org.elasticsearch.action.bulk.BulkRequest bulkRequest)
BulkRequest
against the bulk API.headers
- Use HttpHeaders
to provide eg. authentication data. Must not be null.bulkRequest
- must not be null.Mono
emitting operation response.reactor.core.publisher.Mono<ClientResponse> execute(ReactiveElasticsearchClient.ReactiveElasticsearchClientCallback callback)
connection
.
Execute
selects an active server from the available ones and
retries operations that fail with a ConnectException
on another node if the previously selected one becomes
unavailable.callback
- the callback
wielding the actual command to run.Mono
emitting the ClientResponse
once subscribed.reactor.core.publisher.Mono<ReactiveElasticsearchClient.Status> status()
ReactiveElasticsearchClient.Status
. ReactiveElasticsearchClient.Status
information.Copyright © 2011–2020 Pivotal Software, Inc.. All rights reserved.