Class OpenSearchGeospatialAsyncClient
java.lang.Object
org.opensearch.client.ApiClient<OpenSearchTransport,OpenSearchGeospatialAsyncClient>
org.opensearch.client.opensearch.geospatial.OpenSearchGeospatialAsyncClient
@Generated("org.opensearch.client.codegen.CodeGenerator")
public class OpenSearchGeospatialAsyncClient
extends ApiClient<OpenSearchTransport,OpenSearchGeospatialAsyncClient>
Client for the geospatial namespace.
-
Field Summary
Fields inherited from class org.opensearch.client.ApiClient
transport, transportOptions -
Constructor Summary
ConstructorsConstructorDescriptionOpenSearchGeospatialAsyncClient(OpenSearchTransport transport, TransportOptions transportOptions) -
Method Summary
Modifier and TypeMethodDescriptiondeleteIp2geoDatasource(Function<DeleteIp2geoDatasourceRequest.Builder, ObjectBuilder<DeleteIp2geoDatasourceRequest>> fn) Delete a specific IP2Geo data source.Delete a specific IP2Geo data source.geojsonUploadPost(Function<GeojsonUploadPostRequest.Builder, ObjectBuilder<GeojsonUploadPostRequest>> fn) Use an OpenSearch query to uploadGeoJSON, operation will fail if index exists.Use an OpenSearch query to uploadGeoJSON, operation will fail if index exists.geojsonUploadPut(Function<GeojsonUploadPutRequest.Builder, ObjectBuilder<GeojsonUploadPutRequest>> fn) Use an OpenSearch query to uploadGeoJSONregardless if index exists.geojsonUploadPut(GeojsonUploadPutRequest request) Use an OpenSearch query to uploadGeoJSONregardless if index exists.Get one or more IP2Geo data sources, defaulting to returning all if no names specified.getIp2geoDatasource(Function<GetIp2geoDatasourceRequest.Builder, ObjectBuilder<GetIp2geoDatasourceRequest>> fn) Get one or more IP2Geo data sources, defaulting to returning all if no names specified.Get one or more IP2Geo data sources, defaulting to returning all if no names specified.Retrieves statistics for all geospatial uploads.Retrieves statistics for all geospatial uploads.getUploadStats(GetUploadStatsRequest request) Retrieves statistics for all geospatial uploads.putIp2geoDatasource(Function<PutIp2geoDatasourceRequest.Builder, ObjectBuilder<PutIp2geoDatasourceRequest>> fn) Create a specific IP2Geo data source.Create a specific IP2Geo data source.putIp2geoDatasourceSettings(Function<PutIp2geoDatasourceSettingsRequest.Builder, ObjectBuilder<PutIp2geoDatasourceSettingsRequest>> fn) Update a specific IP2Geo data source.Update a specific IP2Geo data source.withTransportOptions(TransportOptions transportOptions) Creates a new client with some request optionsMethods inherited from class org.opensearch.client.ApiClient
_transport, _transportOptions, getDeserializer
-
Constructor Details
-
OpenSearchGeospatialAsyncClient
-
OpenSearchGeospatialAsyncClient
public OpenSearchGeospatialAsyncClient(OpenSearchTransport transport, @Nullable TransportOptions transportOptions)
-
-
Method Details
-
withTransportOptions
public OpenSearchGeospatialAsyncClient withTransportOptions(@Nullable TransportOptions transportOptions) Description copied from class:ApiClientCreates a new client with some request options- Specified by:
withTransportOptionsin classApiClient<OpenSearchTransport,OpenSearchGeospatialAsyncClient>
-
deleteIp2geoDatasource
public CompletableFuture<DeleteIp2geoDatasourceResponse> deleteIp2geoDatasource(DeleteIp2geoDatasourceRequest request) throws IOException, OpenSearchException Delete a specific IP2Geo data source.- Throws:
IOExceptionOpenSearchException
-
deleteIp2geoDatasource
public final CompletableFuture<DeleteIp2geoDatasourceResponse> deleteIp2geoDatasource(Function<DeleteIp2geoDatasourceRequest.Builder, ObjectBuilder<DeleteIp2geoDatasourceRequest>> fn) throws IOException, OpenSearchExceptionDelete a specific IP2Geo data source.- Parameters:
fn- a function that initializes a builder to create theDeleteIp2geoDatasourceRequest- Throws:
IOExceptionOpenSearchException
-
geojsonUploadPost
public CompletableFuture<GeojsonUploadPostResponse> geojsonUploadPost(GeojsonUploadPostRequest request) throws IOException, OpenSearchException Use an OpenSearch query to upload
GeoJSON, operation will fail if index exists.- When type is
geo_point, only Point geometry is allowed - When type is
geo_shape, all geometry types are allowed (Point, MultiPoint, LineString, MultiLineString, Polygon, MultiPolygon, GeometryCollection, Envelope).
- Throws:
IOExceptionOpenSearchException
- When type is
-
geojsonUploadPost
public final CompletableFuture<GeojsonUploadPostResponse> geojsonUploadPost(Function<GeojsonUploadPostRequest.Builder, ObjectBuilder<GeojsonUploadPostRequest>> fn) throws IOException, OpenSearchExceptionUse an OpenSearch query to upload
GeoJSON, operation will fail if index exists.- When type is
geo_point, only Point geometry is allowed - When type is
geo_shape, all geometry types are allowed (Point, MultiPoint, LineString, MultiLineString, Polygon, MultiPolygon, GeometryCollection, Envelope).
- Parameters:
fn- a function that initializes a builder to create theGeojsonUploadPostRequest- Throws:
IOExceptionOpenSearchException
- When type is
-
geojsonUploadPut
public CompletableFuture<GeojsonUploadPutResponse> geojsonUploadPut(GeojsonUploadPutRequest request) throws IOException, OpenSearchException Use an OpenSearch query to upload
GeoJSONregardless if index exists.- When type is
geo_point, only Point geometry is allowed - When type is
geo_shape, all geometry types are allowed (Point, MultiPoint, LineString, MultiLineString, Polygon, MultiPolygon, GeometryCollection, Envelope).
- Throws:
IOExceptionOpenSearchException
- When type is
-
geojsonUploadPut
public final CompletableFuture<GeojsonUploadPutResponse> geojsonUploadPut(Function<GeojsonUploadPutRequest.Builder, ObjectBuilder<GeojsonUploadPutRequest>> fn) throws IOException, OpenSearchExceptionUse an OpenSearch query to upload
GeoJSONregardless if index exists.- When type is
geo_point, only Point geometry is allowed - When type is
geo_shape, all geometry types are allowed (Point, MultiPoint, LineString, MultiLineString, Polygon, MultiPolygon, GeometryCollection, Envelope).
- Parameters:
fn- a function that initializes a builder to create theGeojsonUploadPutRequest- Throws:
IOExceptionOpenSearchException
- When type is
-
getIp2geoDatasource
public CompletableFuture<GetIp2geoDatasourceResponse> getIp2geoDatasource(GetIp2geoDatasourceRequest request) throws IOException, OpenSearchException Get one or more IP2Geo data sources, defaulting to returning all if no names specified.- Throws:
IOExceptionOpenSearchException
-
getIp2geoDatasource
public final CompletableFuture<GetIp2geoDatasourceResponse> getIp2geoDatasource(Function<GetIp2geoDatasourceRequest.Builder, ObjectBuilder<GetIp2geoDatasourceRequest>> fn) throws IOException, OpenSearchExceptionGet one or more IP2Geo data sources, defaulting to returning all if no names specified.- Parameters:
fn- a function that initializes a builder to create theGetIp2geoDatasourceRequest- Throws:
IOExceptionOpenSearchException
-
getIp2geoDatasource
public final CompletableFuture<GetIp2geoDatasourceResponse> getIp2geoDatasource() throws IOException, OpenSearchExceptionGet one or more IP2Geo data sources, defaulting to returning all if no names specified.- Throws:
IOExceptionOpenSearchException
-
getUploadStats
public CompletableFuture<GetUploadStatsResponse> getUploadStats(GetUploadStatsRequest request) throws IOException, OpenSearchException Retrieves statistics for all geospatial uploads.- Throws:
IOExceptionOpenSearchException
-
getUploadStats
public final CompletableFuture<GetUploadStatsResponse> getUploadStats(Function<GetUploadStatsRequest.Builder, ObjectBuilder<GetUploadStatsRequest>> fn) throws IOException, OpenSearchExceptionRetrieves statistics for all geospatial uploads.- Parameters:
fn- a function that initializes a builder to create theGetUploadStatsRequest- Throws:
IOExceptionOpenSearchException
-
getUploadStats
public final CompletableFuture<GetUploadStatsResponse> getUploadStats() throws IOException, OpenSearchExceptionRetrieves statistics for all geospatial uploads.- Throws:
IOExceptionOpenSearchException
-
putIp2geoDatasource
public CompletableFuture<PutIp2geoDatasourceResponse> putIp2geoDatasource(PutIp2geoDatasourceRequest request) throws IOException, OpenSearchException Create a specific IP2Geo data source. Default values:
endpoint:"https://geoip.maps.opensearch.org/v1/geolite2-city/manifest.json"update_interval_in_days: 3.
- Throws:
IOExceptionOpenSearchException
-
putIp2geoDatasource
public final CompletableFuture<PutIp2geoDatasourceResponse> putIp2geoDatasource(Function<PutIp2geoDatasourceRequest.Builder, ObjectBuilder<PutIp2geoDatasourceRequest>> fn) throws IOException, OpenSearchExceptionCreate a specific IP2Geo data source. Default values:
endpoint:"https://geoip.maps.opensearch.org/v1/geolite2-city/manifest.json"update_interval_in_days: 3.
- Parameters:
fn- a function that initializes a builder to create thePutIp2geoDatasourceRequest- Throws:
IOExceptionOpenSearchException
-
putIp2geoDatasourceSettings
public CompletableFuture<PutIp2geoDatasourceSettingsResponse> putIp2geoDatasourceSettings(PutIp2geoDatasourceSettingsRequest request) throws IOException, OpenSearchException Update a specific IP2Geo data source.- Throws:
IOExceptionOpenSearchException
-
putIp2geoDatasourceSettings
public final CompletableFuture<PutIp2geoDatasourceSettingsResponse> putIp2geoDatasourceSettings(Function<PutIp2geoDatasourceSettingsRequest.Builder, ObjectBuilder<PutIp2geoDatasourceSettingsRequest>> fn) throws IOException, OpenSearchExceptionUpdate a specific IP2Geo data source.- Parameters:
fn- a function that initializes a builder to create thePutIp2geoDatasourceSettingsRequest- Throws:
IOExceptionOpenSearchException
-