
software.amazon.awssdk.services.keyspaces.KeyspacesAsyncClient Maven / Gradle / Ivy
/*
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License"). You may not use this file except in compliance with
* the License. A copy of the License is located at
*
* http://aws.amazon.com/apache2.0
*
* or in the "license" file accompanying this file. This file is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
* CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions
* and limitations under the License.
*/
package software.amazon.awssdk.services.keyspaces;
import java.util.concurrent.CompletableFuture;
import java.util.function.Consumer;
import software.amazon.awssdk.annotations.Generated;
import software.amazon.awssdk.annotations.SdkPublicApi;
import software.amazon.awssdk.annotations.ThreadSafe;
import software.amazon.awssdk.core.SdkClient;
import software.amazon.awssdk.services.keyspaces.model.CreateKeyspaceRequest;
import software.amazon.awssdk.services.keyspaces.model.CreateKeyspaceResponse;
import software.amazon.awssdk.services.keyspaces.model.CreateTableRequest;
import software.amazon.awssdk.services.keyspaces.model.CreateTableResponse;
import software.amazon.awssdk.services.keyspaces.model.DeleteKeyspaceRequest;
import software.amazon.awssdk.services.keyspaces.model.DeleteKeyspaceResponse;
import software.amazon.awssdk.services.keyspaces.model.DeleteTableRequest;
import software.amazon.awssdk.services.keyspaces.model.DeleteTableResponse;
import software.amazon.awssdk.services.keyspaces.model.GetKeyspaceRequest;
import software.amazon.awssdk.services.keyspaces.model.GetKeyspaceResponse;
import software.amazon.awssdk.services.keyspaces.model.GetTableRequest;
import software.amazon.awssdk.services.keyspaces.model.GetTableResponse;
import software.amazon.awssdk.services.keyspaces.model.ListKeyspacesRequest;
import software.amazon.awssdk.services.keyspaces.model.ListKeyspacesResponse;
import software.amazon.awssdk.services.keyspaces.model.ListTablesRequest;
import software.amazon.awssdk.services.keyspaces.model.ListTablesResponse;
import software.amazon.awssdk.services.keyspaces.model.ListTagsForResourceRequest;
import software.amazon.awssdk.services.keyspaces.model.ListTagsForResourceResponse;
import software.amazon.awssdk.services.keyspaces.model.RestoreTableRequest;
import software.amazon.awssdk.services.keyspaces.model.RestoreTableResponse;
import software.amazon.awssdk.services.keyspaces.model.TagResourceRequest;
import software.amazon.awssdk.services.keyspaces.model.TagResourceResponse;
import software.amazon.awssdk.services.keyspaces.model.UntagResourceRequest;
import software.amazon.awssdk.services.keyspaces.model.UntagResourceResponse;
import software.amazon.awssdk.services.keyspaces.model.UpdateTableRequest;
import software.amazon.awssdk.services.keyspaces.model.UpdateTableResponse;
import software.amazon.awssdk.services.keyspaces.paginators.ListKeyspacesPublisher;
import software.amazon.awssdk.services.keyspaces.paginators.ListTablesPublisher;
import software.amazon.awssdk.services.keyspaces.paginators.ListTagsForResourcePublisher;
/**
* Service client for accessing Amazon Keyspaces asynchronously. This can be created using the static {@link #builder()}
* method.
*
*
* Amazon Keyspaces (for Apache Cassandra) is a scalable, highly available, and managed Apache Cassandra-compatible
* database service. Amazon Keyspaces makes it easy to migrate, run, and scale Cassandra workloads in the Amazon Web
* Services Cloud. With just a few clicks on the Amazon Web Services Management Console or a few lines of code, you can
* create keyspaces and tables in Amazon Keyspaces, without deploying any infrastructure or installing software.
*
*
* In addition to supporting Cassandra Query Language (CQL) requests via open-source Cassandra drivers, Amazon Keyspaces
* supports data definition language (DDL) operations to manage keyspaces and tables using the Amazon Web Services SDK
* and CLI. This API reference describes the supported DDL operations in detail.
*
*
* For the list of all supported CQL APIs, see Supported Cassandra APIs,
* operations, and data types in Amazon Keyspaces in the Amazon Keyspaces Developer Guide.
*
*
* To learn how Amazon Keyspaces API actions are recorded with CloudTrail, see Amazon Keyspaces information in CloudTrail in the Amazon Keyspaces Developer Guide.
*
*
* For more information about Amazon Web Services APIs, for example how to implement retry logic or how to sign Amazon
* Web Services API requests, see Amazon Web
* Services APIs in the General Reference.
*
*/
@Generated("software.amazon.awssdk:codegen")
@SdkPublicApi
@ThreadSafe
public interface KeyspacesAsyncClient extends SdkClient {
String SERVICE_NAME = "cassandra";
/**
* Value for looking up the service's metadata from the
* {@link software.amazon.awssdk.regions.ServiceMetadataProvider}.
*/
String SERVICE_METADATA_ID = "cassandra";
/**
* Create a {@link KeyspacesAsyncClient} with the region loaded from the
* {@link software.amazon.awssdk.regions.providers.DefaultAwsRegionProviderChain} and credentials loaded from the
* {@link software.amazon.awssdk.auth.credentials.DefaultCredentialsProvider}.
*/
static KeyspacesAsyncClient create() {
return builder().build();
}
/**
* Create a builder that can be used to configure and create a {@link KeyspacesAsyncClient}.
*/
static KeyspacesAsyncClientBuilder builder() {
return new DefaultKeyspacesAsyncClientBuilder();
}
/**
*
* The CreateKeyspace
operation adds a new keyspace to your account. In an Amazon Web Services account,
* keyspace names must be unique within each Region.
*
*
* CreateKeyspace
is an asynchronous operation. You can monitor the creation status of the new keyspace
* by using the GetKeyspace
operation.
*
*
* For more information, see Creating keyspaces in the Amazon Keyspaces Developer Guide.
*
*
* @param createKeyspaceRequest
* @return A Java Future containing the result of the CreateKeyspace operation returned by the service.
* The CompletableFuture returned by this method can be completed exceptionally with the following
* exceptions.
*
* - ValidationException The operation failed due to an invalid or malformed request.
* - ServiceQuotaExceededException The operation exceeded the service quota for this resource. For more
* information on service quotas, see Quotas in the Amazon
* Keyspaces Developer Guide.
* - InternalServerException Amazon Keyspaces was unable to fully process this request because of an
* internal server error.
* - ConflictException Amazon Keyspaces could not complete the requested action. This error may occur if
* you try to perform an action and the same or a different action is already in progress, or if you try to
* create a resource that already exists.
* - AccessDeniedException You do not have sufficient access to perform this action.
* - SdkException Base class for all exceptions that can be thrown by the SDK (both service and client).
* Can be used for catch all scenarios.
* - SdkClientException If any client side error occurs such as an IO related failure, failure to get
* credentials, etc.
* - KeyspacesException Base class for all service exceptions. Unknown exceptions will be thrown as an
* instance of this type.
*
* @sample KeyspacesAsyncClient.CreateKeyspace
* @see AWS API
* Documentation
*/
default CompletableFuture createKeyspace(CreateKeyspaceRequest createKeyspaceRequest) {
throw new UnsupportedOperationException();
}
/**
*
* The CreateKeyspace
operation adds a new keyspace to your account. In an Amazon Web Services account,
* keyspace names must be unique within each Region.
*
*
* CreateKeyspace
is an asynchronous operation. You can monitor the creation status of the new keyspace
* by using the GetKeyspace
operation.
*
*
* For more information, see Creating keyspaces in the Amazon Keyspaces Developer Guide.
*
*
*
* This is a convenience which creates an instance of the {@link CreateKeyspaceRequest.Builder} avoiding the need to
* create one manually via {@link CreateKeyspaceRequest#builder()}
*
*
* @param createKeyspaceRequest
* A {@link Consumer} that will call methods on {@link CreateKeyspaceRequest.Builder} to create a request.
* @return A Java Future containing the result of the CreateKeyspace operation returned by the service.
* The CompletableFuture returned by this method can be completed exceptionally with the following
* exceptions.
*
* - ValidationException The operation failed due to an invalid or malformed request.
* - ServiceQuotaExceededException The operation exceeded the service quota for this resource. For more
* information on service quotas, see Quotas in the Amazon
* Keyspaces Developer Guide.
* - InternalServerException Amazon Keyspaces was unable to fully process this request because of an
* internal server error.
* - ConflictException Amazon Keyspaces could not complete the requested action. This error may occur if
* you try to perform an action and the same or a different action is already in progress, or if you try to
* create a resource that already exists.
* - AccessDeniedException You do not have sufficient access to perform this action.
* - SdkException Base class for all exceptions that can be thrown by the SDK (both service and client).
* Can be used for catch all scenarios.
* - SdkClientException If any client side error occurs such as an IO related failure, failure to get
* credentials, etc.
* - KeyspacesException Base class for all service exceptions. Unknown exceptions will be thrown as an
* instance of this type.
*
* @sample KeyspacesAsyncClient.CreateKeyspace
* @see AWS API
* Documentation
*/
default CompletableFuture createKeyspace(Consumer createKeyspaceRequest) {
return createKeyspace(CreateKeyspaceRequest.builder().applyMutation(createKeyspaceRequest).build());
}
/**
*
* The CreateTable
operation adds a new table to the specified keyspace. Within a keyspace, table names
* must be unique.
*
*
* CreateTable
is an asynchronous operation. When the request is received, the status of the table is
* set to CREATING
. You can monitor the creation status of the new table by using the
* GetTable
operation, which returns the current status
of the table. You can start using
* a table when the status is ACTIVE
.
*
*
* For more information, see Creating
* tables in the Amazon Keyspaces Developer Guide.
*
*
* @param createTableRequest
* @return A Java Future containing the result of the CreateTable operation returned by the service.
* The CompletableFuture returned by this method can be completed exceptionally with the following
* exceptions.
*
* - ValidationException The operation failed due to an invalid or malformed request.
* - ServiceQuotaExceededException The operation exceeded the service quota for this resource. For more
* information on service quotas, see Quotas in the Amazon
* Keyspaces Developer Guide.
* - InternalServerException Amazon Keyspaces was unable to fully process this request because of an
* internal server error.
* - ConflictException Amazon Keyspaces could not complete the requested action. This error may occur if
* you try to perform an action and the same or a different action is already in progress, or if you try to
* create a resource that already exists.
* - AccessDeniedException You do not have sufficient access to perform this action.
* - ResourceNotFoundException The operation tried to access a keyspace or table that doesn't exist. The
* resource might not be specified correctly, or its status might not be
ACTIVE
.
* - SdkException Base class for all exceptions that can be thrown by the SDK (both service and client).
* Can be used for catch all scenarios.
* - SdkClientException If any client side error occurs such as an IO related failure, failure to get
* credentials, etc.
* - KeyspacesException Base class for all service exceptions. Unknown exceptions will be thrown as an
* instance of this type.
*
* @sample KeyspacesAsyncClient.CreateTable
* @see AWS API
* Documentation
*/
default CompletableFuture createTable(CreateTableRequest createTableRequest) {
throw new UnsupportedOperationException();
}
/**
*
* The CreateTable
operation adds a new table to the specified keyspace. Within a keyspace, table names
* must be unique.
*
*
* CreateTable
is an asynchronous operation. When the request is received, the status of the table is
* set to CREATING
. You can monitor the creation status of the new table by using the
* GetTable
operation, which returns the current status
of the table. You can start using
* a table when the status is ACTIVE
.
*
*
* For more information, see Creating
* tables in the Amazon Keyspaces Developer Guide.
*
*
*
* This is a convenience which creates an instance of the {@link CreateTableRequest.Builder} avoiding the need to
* create one manually via {@link CreateTableRequest#builder()}
*
*
* @param createTableRequest
* A {@link Consumer} that will call methods on {@link CreateTableRequest.Builder} to create a request.
* @return A Java Future containing the result of the CreateTable operation returned by the service.
* The CompletableFuture returned by this method can be completed exceptionally with the following
* exceptions.
*
* - ValidationException The operation failed due to an invalid or malformed request.
* - ServiceQuotaExceededException The operation exceeded the service quota for this resource. For more
* information on service quotas, see Quotas in the Amazon
* Keyspaces Developer Guide.
* - InternalServerException Amazon Keyspaces was unable to fully process this request because of an
* internal server error.
* - ConflictException Amazon Keyspaces could not complete the requested action. This error may occur if
* you try to perform an action and the same or a different action is already in progress, or if you try to
* create a resource that already exists.
* - AccessDeniedException You do not have sufficient access to perform this action.
* - ResourceNotFoundException The operation tried to access a keyspace or table that doesn't exist. The
* resource might not be specified correctly, or its status might not be
ACTIVE
.
* - SdkException Base class for all exceptions that can be thrown by the SDK (both service and client).
* Can be used for catch all scenarios.
* - SdkClientException If any client side error occurs such as an IO related failure, failure to get
* credentials, etc.
* - KeyspacesException Base class for all service exceptions. Unknown exceptions will be thrown as an
* instance of this type.
*
* @sample KeyspacesAsyncClient.CreateTable
* @see AWS API
* Documentation
*/
default CompletableFuture createTable(Consumer createTableRequest) {
return createTable(CreateTableRequest.builder().applyMutation(createTableRequest).build());
}
/**
*
* The DeleteKeyspace
operation deletes a keyspace and all of its tables.
*
*
* @param deleteKeyspaceRequest
* @return A Java Future containing the result of the DeleteKeyspace operation returned by the service.
* The CompletableFuture returned by this method can be completed exceptionally with the following
* exceptions.
*
* - ValidationException The operation failed due to an invalid or malformed request.
* - ServiceQuotaExceededException The operation exceeded the service quota for this resource. For more
* information on service quotas, see Quotas in the Amazon
* Keyspaces Developer Guide.
* - InternalServerException Amazon Keyspaces was unable to fully process this request because of an
* internal server error.
* - ConflictException Amazon Keyspaces could not complete the requested action. This error may occur if
* you try to perform an action and the same or a different action is already in progress, or if you try to
* create a resource that already exists.
* - AccessDeniedException You do not have sufficient access to perform this action.
* - ResourceNotFoundException The operation tried to access a keyspace or table that doesn't exist. The
* resource might not be specified correctly, or its status might not be
ACTIVE
.
* - SdkException Base class for all exceptions that can be thrown by the SDK (both service and client).
* Can be used for catch all scenarios.
* - SdkClientException If any client side error occurs such as an IO related failure, failure to get
* credentials, etc.
* - KeyspacesException Base class for all service exceptions. Unknown exceptions will be thrown as an
* instance of this type.
*
* @sample KeyspacesAsyncClient.DeleteKeyspace
* @see AWS API
* Documentation
*/
default CompletableFuture deleteKeyspace(DeleteKeyspaceRequest deleteKeyspaceRequest) {
throw new UnsupportedOperationException();
}
/**
*
* The DeleteKeyspace
operation deletes a keyspace and all of its tables.
*
*
*
* This is a convenience which creates an instance of the {@link DeleteKeyspaceRequest.Builder} avoiding the need to
* create one manually via {@link DeleteKeyspaceRequest#builder()}
*
*
* @param deleteKeyspaceRequest
* A {@link Consumer} that will call methods on {@link DeleteKeyspaceRequest.Builder} to create a request.
* @return A Java Future containing the result of the DeleteKeyspace operation returned by the service.
* The CompletableFuture returned by this method can be completed exceptionally with the following
* exceptions.
*
* - ValidationException The operation failed due to an invalid or malformed request.
* - ServiceQuotaExceededException The operation exceeded the service quota for this resource. For more
* information on service quotas, see Quotas in the Amazon
* Keyspaces Developer Guide.
* - InternalServerException Amazon Keyspaces was unable to fully process this request because of an
* internal server error.
* - ConflictException Amazon Keyspaces could not complete the requested action. This error may occur if
* you try to perform an action and the same or a different action is already in progress, or if you try to
* create a resource that already exists.
* - AccessDeniedException You do not have sufficient access to perform this action.
* - ResourceNotFoundException The operation tried to access a keyspace or table that doesn't exist. The
* resource might not be specified correctly, or its status might not be
ACTIVE
.
* - SdkException Base class for all exceptions that can be thrown by the SDK (both service and client).
* Can be used for catch all scenarios.
* - SdkClientException If any client side error occurs such as an IO related failure, failure to get
* credentials, etc.
* - KeyspacesException Base class for all service exceptions. Unknown exceptions will be thrown as an
* instance of this type.
*
* @sample KeyspacesAsyncClient.DeleteKeyspace
* @see AWS API
* Documentation
*/
default CompletableFuture deleteKeyspace(Consumer deleteKeyspaceRequest) {
return deleteKeyspace(DeleteKeyspaceRequest.builder().applyMutation(deleteKeyspaceRequest).build());
}
/**
*
* The DeleteTable
operation deletes a table and all of its data. After a DeleteTable
* request is received, the specified table is in the DELETING
state until Amazon Keyspaces completes
* the deletion. If the table is in the ACTIVE
state, you can delete it. If a table is either in the
* CREATING
or UPDATING
states, then Amazon Keyspaces returns a
* ResourceInUseException
. If the specified table does not exist, Amazon Keyspaces returns a
* ResourceNotFoundException
. If the table is already in the DELETING
state, no error is
* returned.
*
*
* @param deleteTableRequest
* @return A Java Future containing the result of the DeleteTable operation returned by the service.
* The CompletableFuture returned by this method can be completed exceptionally with the following
* exceptions.
*
* - ValidationException The operation failed due to an invalid or malformed request.
* - ServiceQuotaExceededException The operation exceeded the service quota for this resource. For more
* information on service quotas, see Quotas in the Amazon
* Keyspaces Developer Guide.
* - InternalServerException Amazon Keyspaces was unable to fully process this request because of an
* internal server error.
* - ConflictException Amazon Keyspaces could not complete the requested action. This error may occur if
* you try to perform an action and the same or a different action is already in progress, or if you try to
* create a resource that already exists.
* - AccessDeniedException You do not have sufficient access to perform this action.
* - ResourceNotFoundException The operation tried to access a keyspace or table that doesn't exist. The
* resource might not be specified correctly, or its status might not be
ACTIVE
.
* - SdkException Base class for all exceptions that can be thrown by the SDK (both service and client).
* Can be used for catch all scenarios.
* - SdkClientException If any client side error occurs such as an IO related failure, failure to get
* credentials, etc.
* - KeyspacesException Base class for all service exceptions. Unknown exceptions will be thrown as an
* instance of this type.
*
* @sample KeyspacesAsyncClient.DeleteTable
* @see AWS API
* Documentation
*/
default CompletableFuture deleteTable(DeleteTableRequest deleteTableRequest) {
throw new UnsupportedOperationException();
}
/**
*
* The DeleteTable
operation deletes a table and all of its data. After a DeleteTable
* request is received, the specified table is in the DELETING
state until Amazon Keyspaces completes
* the deletion. If the table is in the ACTIVE
state, you can delete it. If a table is either in the
* CREATING
or UPDATING
states, then Amazon Keyspaces returns a
* ResourceInUseException
. If the specified table does not exist, Amazon Keyspaces returns a
* ResourceNotFoundException
. If the table is already in the DELETING
state, no error is
* returned.
*
*
*
* This is a convenience which creates an instance of the {@link DeleteTableRequest.Builder} avoiding the need to
* create one manually via {@link DeleteTableRequest#builder()}
*
*
* @param deleteTableRequest
* A {@link Consumer} that will call methods on {@link DeleteTableRequest.Builder} to create a request.
* @return A Java Future containing the result of the DeleteTable operation returned by the service.
* The CompletableFuture returned by this method can be completed exceptionally with the following
* exceptions.
*
* - ValidationException The operation failed due to an invalid or malformed request.
* - ServiceQuotaExceededException The operation exceeded the service quota for this resource. For more
* information on service quotas, see Quotas in the Amazon
* Keyspaces Developer Guide.
* - InternalServerException Amazon Keyspaces was unable to fully process this request because of an
* internal server error.
* - ConflictException Amazon Keyspaces could not complete the requested action. This error may occur if
* you try to perform an action and the same or a different action is already in progress, or if you try to
* create a resource that already exists.
* - AccessDeniedException You do not have sufficient access to perform this action.
* - ResourceNotFoundException The operation tried to access a keyspace or table that doesn't exist. The
* resource might not be specified correctly, or its status might not be
ACTIVE
.
* - SdkException Base class for all exceptions that can be thrown by the SDK (both service and client).
* Can be used for catch all scenarios.
* - SdkClientException If any client side error occurs such as an IO related failure, failure to get
* credentials, etc.
* - KeyspacesException Base class for all service exceptions. Unknown exceptions will be thrown as an
* instance of this type.
*
* @sample KeyspacesAsyncClient.DeleteTable
* @see AWS API
* Documentation
*/
default CompletableFuture deleteTable(Consumer deleteTableRequest) {
return deleteTable(DeleteTableRequest.builder().applyMutation(deleteTableRequest).build());
}
/**
*
* Returns the name and the Amazon Resource Name (ARN) of the specified table.
*
*
* @param getKeyspaceRequest
* @return A Java Future containing the result of the GetKeyspace operation returned by the service.
* The CompletableFuture returned by this method can be completed exceptionally with the following
* exceptions.
*
* - ValidationException The operation failed due to an invalid or malformed request.
* - ServiceQuotaExceededException The operation exceeded the service quota for this resource. For more
* information on service quotas, see Quotas in the Amazon
* Keyspaces Developer Guide.
* - InternalServerException Amazon Keyspaces was unable to fully process this request because of an
* internal server error.
* - AccessDeniedException You do not have sufficient access to perform this action.
* - ResourceNotFoundException The operation tried to access a keyspace or table that doesn't exist. The
* resource might not be specified correctly, or its status might not be
ACTIVE
.
* - SdkException Base class for all exceptions that can be thrown by the SDK (both service and client).
* Can be used for catch all scenarios.
* - SdkClientException If any client side error occurs such as an IO related failure, failure to get
* credentials, etc.
* - KeyspacesException Base class for all service exceptions. Unknown exceptions will be thrown as an
* instance of this type.
*
* @sample KeyspacesAsyncClient.GetKeyspace
* @see AWS API
* Documentation
*/
default CompletableFuture getKeyspace(GetKeyspaceRequest getKeyspaceRequest) {
throw new UnsupportedOperationException();
}
/**
*
* Returns the name and the Amazon Resource Name (ARN) of the specified table.
*
*
*
* This is a convenience which creates an instance of the {@link GetKeyspaceRequest.Builder} avoiding the need to
* create one manually via {@link GetKeyspaceRequest#builder()}
*
*
* @param getKeyspaceRequest
* A {@link Consumer} that will call methods on {@link GetKeyspaceRequest.Builder} to create a request.
* @return A Java Future containing the result of the GetKeyspace operation returned by the service.
* The CompletableFuture returned by this method can be completed exceptionally with the following
* exceptions.
*
* - ValidationException The operation failed due to an invalid or malformed request.
* - ServiceQuotaExceededException The operation exceeded the service quota for this resource. For more
* information on service quotas, see Quotas in the Amazon
* Keyspaces Developer Guide.
* - InternalServerException Amazon Keyspaces was unable to fully process this request because of an
* internal server error.
* - AccessDeniedException You do not have sufficient access to perform this action.
* - ResourceNotFoundException The operation tried to access a keyspace or table that doesn't exist. The
* resource might not be specified correctly, or its status might not be
ACTIVE
.
* - SdkException Base class for all exceptions that can be thrown by the SDK (both service and client).
* Can be used for catch all scenarios.
* - SdkClientException If any client side error occurs such as an IO related failure, failure to get
* credentials, etc.
* - KeyspacesException Base class for all service exceptions. Unknown exceptions will be thrown as an
* instance of this type.
*
* @sample KeyspacesAsyncClient.GetKeyspace
* @see AWS API
* Documentation
*/
default CompletableFuture getKeyspace(Consumer getKeyspaceRequest) {
return getKeyspace(GetKeyspaceRequest.builder().applyMutation(getKeyspaceRequest).build());
}
/**
*
* Returns information about the table, including the table's name and current status, the keyspace name,
* configuration settings, and metadata.
*
*
* To read table metadata using GetTable
, Select
action permissions for the table and
* system tables are required to complete the operation.
*
*
* @param getTableRequest
* @return A Java Future containing the result of the GetTable operation returned by the service.
* The CompletableFuture returned by this method can be completed exceptionally with the following
* exceptions.
*
* - ValidationException The operation failed due to an invalid or malformed request.
* - ServiceQuotaExceededException The operation exceeded the service quota for this resource. For more
* information on service quotas, see Quotas in the Amazon
* Keyspaces Developer Guide.
* - InternalServerException Amazon Keyspaces was unable to fully process this request because of an
* internal server error.
* - AccessDeniedException You do not have sufficient access to perform this action.
* - ResourceNotFoundException The operation tried to access a keyspace or table that doesn't exist. The
* resource might not be specified correctly, or its status might not be
ACTIVE
.
* - SdkException Base class for all exceptions that can be thrown by the SDK (both service and client).
* Can be used for catch all scenarios.
* - SdkClientException If any client side error occurs such as an IO related failure, failure to get
* credentials, etc.
* - KeyspacesException Base class for all service exceptions. Unknown exceptions will be thrown as an
* instance of this type.
*
* @sample KeyspacesAsyncClient.GetTable
* @see AWS API
* Documentation
*/
default CompletableFuture getTable(GetTableRequest getTableRequest) {
throw new UnsupportedOperationException();
}
/**
*
* Returns information about the table, including the table's name and current status, the keyspace name,
* configuration settings, and metadata.
*
*
* To read table metadata using GetTable
, Select
action permissions for the table and
* system tables are required to complete the operation.
*
*
*
* This is a convenience which creates an instance of the {@link GetTableRequest.Builder} avoiding the need to
* create one manually via {@link GetTableRequest#builder()}
*
*
* @param getTableRequest
* A {@link Consumer} that will call methods on {@link GetTableRequest.Builder} to create a request.
* @return A Java Future containing the result of the GetTable operation returned by the service.
* The CompletableFuture returned by this method can be completed exceptionally with the following
* exceptions.
*
* - ValidationException The operation failed due to an invalid or malformed request.
* - ServiceQuotaExceededException The operation exceeded the service quota for this resource. For more
* information on service quotas, see Quotas in the Amazon
* Keyspaces Developer Guide.
* - InternalServerException Amazon Keyspaces was unable to fully process this request because of an
* internal server error.
* - AccessDeniedException You do not have sufficient access to perform this action.
* - ResourceNotFoundException The operation tried to access a keyspace or table that doesn't exist. The
* resource might not be specified correctly, or its status might not be
ACTIVE
.
* - SdkException Base class for all exceptions that can be thrown by the SDK (both service and client).
* Can be used for catch all scenarios.
* - SdkClientException If any client side error occurs such as an IO related failure, failure to get
* credentials, etc.
* - KeyspacesException Base class for all service exceptions. Unknown exceptions will be thrown as an
* instance of this type.
*
* @sample KeyspacesAsyncClient.GetTable
* @see AWS API
* Documentation
*/
default CompletableFuture getTable(Consumer getTableRequest) {
return getTable(GetTableRequest.builder().applyMutation(getTableRequest).build());
}
/**
*
* Returns a list of keyspaces.
*
*
* @param listKeyspacesRequest
* @return A Java Future containing the result of the ListKeyspaces operation returned by the service.
* The CompletableFuture returned by this method can be completed exceptionally with the following
* exceptions.
*
* - ValidationException The operation failed due to an invalid or malformed request.
* - ServiceQuotaExceededException The operation exceeded the service quota for this resource. For more
* information on service quotas, see Quotas in the Amazon
* Keyspaces Developer Guide.
* - InternalServerException Amazon Keyspaces was unable to fully process this request because of an
* internal server error.
* - AccessDeniedException You do not have sufficient access to perform this action.
* - ResourceNotFoundException The operation tried to access a keyspace or table that doesn't exist. The
* resource might not be specified correctly, or its status might not be
ACTIVE
.
* - SdkException Base class for all exceptions that can be thrown by the SDK (both service and client).
* Can be used for catch all scenarios.
* - SdkClientException If any client side error occurs such as an IO related failure, failure to get
* credentials, etc.
* - KeyspacesException Base class for all service exceptions. Unknown exceptions will be thrown as an
* instance of this type.
*
* @sample KeyspacesAsyncClient.ListKeyspaces
* @see AWS API
* Documentation
*/
default CompletableFuture listKeyspaces(ListKeyspacesRequest listKeyspacesRequest) {
throw new UnsupportedOperationException();
}
/**
*
* Returns a list of keyspaces.
*
*
*
* This is a convenience which creates an instance of the {@link ListKeyspacesRequest.Builder} avoiding the need to
* create one manually via {@link ListKeyspacesRequest#builder()}
*
*
* @param listKeyspacesRequest
* A {@link Consumer} that will call methods on {@link ListKeyspacesRequest.Builder} to create a request.
* @return A Java Future containing the result of the ListKeyspaces operation returned by the service.
* The CompletableFuture returned by this method can be completed exceptionally with the following
* exceptions.
*
* - ValidationException The operation failed due to an invalid or malformed request.
* - ServiceQuotaExceededException The operation exceeded the service quota for this resource. For more
* information on service quotas, see Quotas in the Amazon
* Keyspaces Developer Guide.
* - InternalServerException Amazon Keyspaces was unable to fully process this request because of an
* internal server error.
* - AccessDeniedException You do not have sufficient access to perform this action.
* - ResourceNotFoundException The operation tried to access a keyspace or table that doesn't exist. The
* resource might not be specified correctly, or its status might not be
ACTIVE
.
* - SdkException Base class for all exceptions that can be thrown by the SDK (both service and client).
* Can be used for catch all scenarios.
* - SdkClientException If any client side error occurs such as an IO related failure, failure to get
* credentials, etc.
* - KeyspacesException Base class for all service exceptions. Unknown exceptions will be thrown as an
* instance of this type.
*
* @sample KeyspacesAsyncClient.ListKeyspaces
* @see AWS API
* Documentation
*/
default CompletableFuture listKeyspaces(Consumer listKeyspacesRequest) {
return listKeyspaces(ListKeyspacesRequest.builder().applyMutation(listKeyspacesRequest).build());
}
/**
*
* Returns a list of keyspaces.
*
*
*
* This is a variant of {@link #listKeyspaces(software.amazon.awssdk.services.keyspaces.model.ListKeyspacesRequest)}
* operation. The return type is a custom publisher that can be subscribed to request a stream of response pages.
* SDK will internally handle making service calls for you.
*
*
* When the operation is called, an instance of this class is returned. At this point, no service calls are made yet
* and so there is no guarantee that the request is valid. If there are errors in your request, you will see the
* failures only after you start streaming the data. The subscribe method should be called as a request to start
* streaming data. For more info, see
* {@link org.reactivestreams.Publisher#subscribe(org.reactivestreams.Subscriber)}. Each call to the subscribe
* method will result in a new {@link org.reactivestreams.Subscription} i.e., a new contract to stream data from the
* starting request.
*
*
*
* The following are few ways to use the response class:
*
* 1) Using the subscribe helper method
*
*
* {@code
* software.amazon.awssdk.services.keyspaces.paginators.ListKeyspacesPublisher publisher = client.listKeyspacesPaginator(request);
* CompletableFuture future = publisher.subscribe(res -> { // Do something with the response });
* future.get();
* }
*
*
* 2) Using a custom subscriber
*
*
* {@code
* software.amazon.awssdk.services.keyspaces.paginators.ListKeyspacesPublisher publisher = client.listKeyspacesPaginator(request);
* publisher.subscribe(new Subscriber() {
*
* public void onSubscribe(org.reactivestreams.Subscriber subscription) { //... };
*
*
* public void onNext(software.amazon.awssdk.services.keyspaces.model.ListKeyspacesResponse response) { //... };
* });}
*
*
* As the response is a publisher, it can work well with third party reactive streams implementations like RxJava2.
*
* Please notice that the configuration of maxResults won't limit the number of results you get with the
* paginator. It only limits the number of results in each page.
*
*
* Note: If you prefer to have control on service calls, use the
* {@link #listKeyspaces(software.amazon.awssdk.services.keyspaces.model.ListKeyspacesRequest)} operation.
*
*
* @param listKeyspacesRequest
* @return A custom publisher that can be subscribed to request a stream of response pages.
* The CompletableFuture returned by this method can be completed exceptionally with the following
* exceptions.
*
* - ValidationException The operation failed due to an invalid or malformed request.
* - ServiceQuotaExceededException The operation exceeded the service quota for this resource. For more
* information on service quotas, see Quotas in the Amazon
* Keyspaces Developer Guide.
* - InternalServerException Amazon Keyspaces was unable to fully process this request because of an
* internal server error.
* - AccessDeniedException You do not have sufficient access to perform this action.
* - ResourceNotFoundException The operation tried to access a keyspace or table that doesn't exist. The
* resource might not be specified correctly, or its status might not be
ACTIVE
.
* - SdkException Base class for all exceptions that can be thrown by the SDK (both service and client).
* Can be used for catch all scenarios.
* - SdkClientException If any client side error occurs such as an IO related failure, failure to get
* credentials, etc.
* - KeyspacesException Base class for all service exceptions. Unknown exceptions will be thrown as an
* instance of this type.
*
* @sample KeyspacesAsyncClient.ListKeyspaces
* @see AWS API
* Documentation
*/
default ListKeyspacesPublisher listKeyspacesPaginator(ListKeyspacesRequest listKeyspacesRequest) {
throw new UnsupportedOperationException();
}
/**
*
* Returns a list of keyspaces.
*
*
*
* This is a variant of {@link #listKeyspaces(software.amazon.awssdk.services.keyspaces.model.ListKeyspacesRequest)}
* operation. The return type is a custom publisher that can be subscribed to request a stream of response pages.
* SDK will internally handle making service calls for you.
*
*
* When the operation is called, an instance of this class is returned. At this point, no service calls are made yet
* and so there is no guarantee that the request is valid. If there are errors in your request, you will see the
* failures only after you start streaming the data. The subscribe method should be called as a request to start
* streaming data. For more info, see
* {@link org.reactivestreams.Publisher#subscribe(org.reactivestreams.Subscriber)}. Each call to the subscribe
* method will result in a new {@link org.reactivestreams.Subscription} i.e., a new contract to stream data from the
* starting request.
*
*
*
* The following are few ways to use the response class:
*
* 1) Using the subscribe helper method
*
*
* {@code
* software.amazon.awssdk.services.keyspaces.paginators.ListKeyspacesPublisher publisher = client.listKeyspacesPaginator(request);
* CompletableFuture future = publisher.subscribe(res -> { // Do something with the response });
* future.get();
* }
*
*
* 2) Using a custom subscriber
*
*
* {@code
* software.amazon.awssdk.services.keyspaces.paginators.ListKeyspacesPublisher publisher = client.listKeyspacesPaginator(request);
* publisher.subscribe(new Subscriber() {
*
* public void onSubscribe(org.reactivestreams.Subscriber subscription) { //... };
*
*
* public void onNext(software.amazon.awssdk.services.keyspaces.model.ListKeyspacesResponse response) { //... };
* });}
*
*
* As the response is a publisher, it can work well with third party reactive streams implementations like RxJava2.
*
* Please notice that the configuration of maxResults won't limit the number of results you get with the
* paginator. It only limits the number of results in each page.
*
*
* Note: If you prefer to have control on service calls, use the
* {@link #listKeyspaces(software.amazon.awssdk.services.keyspaces.model.ListKeyspacesRequest)} operation.
*
*
* This is a convenience which creates an instance of the {@link ListKeyspacesRequest.Builder} avoiding the need to
* create one manually via {@link ListKeyspacesRequest#builder()}
*
*
* @param listKeyspacesRequest
* A {@link Consumer} that will call methods on {@link ListKeyspacesRequest.Builder} to create a request.
* @return A custom publisher that can be subscribed to request a stream of response pages.
* The CompletableFuture returned by this method can be completed exceptionally with the following
* exceptions.
*
* - ValidationException The operation failed due to an invalid or malformed request.
* - ServiceQuotaExceededException The operation exceeded the service quota for this resource. For more
* information on service quotas, see Quotas in the Amazon
* Keyspaces Developer Guide.
* - InternalServerException Amazon Keyspaces was unable to fully process this request because of an
* internal server error.
* - AccessDeniedException You do not have sufficient access to perform this action.
* - ResourceNotFoundException The operation tried to access a keyspace or table that doesn't exist. The
* resource might not be specified correctly, or its status might not be
ACTIVE
.
* - SdkException Base class for all exceptions that can be thrown by the SDK (both service and client).
* Can be used for catch all scenarios.
* - SdkClientException If any client side error occurs such as an IO related failure, failure to get
* credentials, etc.
* - KeyspacesException Base class for all service exceptions. Unknown exceptions will be thrown as an
* instance of this type.
*
* @sample KeyspacesAsyncClient.ListKeyspaces
* @see AWS API
* Documentation
*/
default ListKeyspacesPublisher listKeyspacesPaginator(Consumer listKeyspacesRequest) {
return listKeyspacesPaginator(ListKeyspacesRequest.builder().applyMutation(listKeyspacesRequest).build());
}
/**
*
* Returns a list of tables for a specified keyspace.
*
*
* @param listTablesRequest
* @return A Java Future containing the result of the ListTables operation returned by the service.
* The CompletableFuture returned by this method can be completed exceptionally with the following
* exceptions.
*
* - ValidationException The operation failed due to an invalid or malformed request.
* - ServiceQuotaExceededException The operation exceeded the service quota for this resource. For more
* information on service quotas, see Quotas in the Amazon
* Keyspaces Developer Guide.
* - InternalServerException Amazon Keyspaces was unable to fully process this request because of an
* internal server error.
* - AccessDeniedException You do not have sufficient access to perform this action.
* - ResourceNotFoundException The operation tried to access a keyspace or table that doesn't exist. The
* resource might not be specified correctly, or its status might not be
ACTIVE
.
* - SdkException Base class for all exceptions that can be thrown by the SDK (both service and client).
* Can be used for catch all scenarios.
* - SdkClientException If any client side error occurs such as an IO related failure, failure to get
* credentials, etc.
* - KeyspacesException Base class for all service exceptions. Unknown exceptions will be thrown as an
* instance of this type.
*
* @sample KeyspacesAsyncClient.ListTables
* @see AWS API
* Documentation
*/
default CompletableFuture listTables(ListTablesRequest listTablesRequest) {
throw new UnsupportedOperationException();
}
/**
*
* Returns a list of tables for a specified keyspace.
*
*
*
* This is a convenience which creates an instance of the {@link ListTablesRequest.Builder} avoiding the need to
* create one manually via {@link ListTablesRequest#builder()}
*
*
* @param listTablesRequest
* A {@link Consumer} that will call methods on {@link ListTablesRequest.Builder} to create a request.
* @return A Java Future containing the result of the ListTables operation returned by the service.
* The CompletableFuture returned by this method can be completed exceptionally with the following
* exceptions.
*
* - ValidationException The operation failed due to an invalid or malformed request.
* - ServiceQuotaExceededException The operation exceeded the service quota for this resource. For more
* information on service quotas, see Quotas in the Amazon
* Keyspaces Developer Guide.
* - InternalServerException Amazon Keyspaces was unable to fully process this request because of an
* internal server error.
* - AccessDeniedException You do not have sufficient access to perform this action.
* - ResourceNotFoundException The operation tried to access a keyspace or table that doesn't exist. The
* resource might not be specified correctly, or its status might not be
ACTIVE
.
* - SdkException Base class for all exceptions that can be thrown by the SDK (both service and client).
* Can be used for catch all scenarios.
* - SdkClientException If any client side error occurs such as an IO related failure, failure to get
* credentials, etc.
* - KeyspacesException Base class for all service exceptions. Unknown exceptions will be thrown as an
* instance of this type.
*
* @sample KeyspacesAsyncClient.ListTables
* @see AWS API
* Documentation
*/
default CompletableFuture listTables(Consumer listTablesRequest) {
return listTables(ListTablesRequest.builder().applyMutation(listTablesRequest).build());
}
/**
*
* Returns a list of tables for a specified keyspace.
*
*
*
* This is a variant of {@link #listTables(software.amazon.awssdk.services.keyspaces.model.ListTablesRequest)}
* operation. The return type is a custom publisher that can be subscribed to request a stream of response pages.
* SDK will internally handle making service calls for you.
*
*
* When the operation is called, an instance of this class is returned. At this point, no service calls are made yet
* and so there is no guarantee that the request is valid. If there are errors in your request, you will see the
* failures only after you start streaming the data. The subscribe method should be called as a request to start
* streaming data. For more info, see
* {@link org.reactivestreams.Publisher#subscribe(org.reactivestreams.Subscriber)}. Each call to the subscribe
* method will result in a new {@link org.reactivestreams.Subscription} i.e., a new contract to stream data from the
* starting request.
*
*
*
* The following are few ways to use the response class:
*
* 1) Using the subscribe helper method
*
*
* {@code
* software.amazon.awssdk.services.keyspaces.paginators.ListTablesPublisher publisher = client.listTablesPaginator(request);
* CompletableFuture future = publisher.subscribe(res -> { // Do something with the response });
* future.get();
* }
*
*
* 2) Using a custom subscriber
*
*
* {@code
* software.amazon.awssdk.services.keyspaces.paginators.ListTablesPublisher publisher = client.listTablesPaginator(request);
* publisher.subscribe(new Subscriber() {
*
* public void onSubscribe(org.reactivestreams.Subscriber subscription) { //... };
*
*
* public void onNext(software.amazon.awssdk.services.keyspaces.model.ListTablesResponse response) { //... };
* });}
*
*
* As the response is a publisher, it can work well with third party reactive streams implementations like RxJava2.
*
* Please notice that the configuration of maxResults won't limit the number of results you get with the
* paginator. It only limits the number of results in each page.
*
*
* Note: If you prefer to have control on service calls, use the
* {@link #listTables(software.amazon.awssdk.services.keyspaces.model.ListTablesRequest)} operation.
*
*
* @param listTablesRequest
* @return A custom publisher that can be subscribed to request a stream of response pages.
* The CompletableFuture returned by this method can be completed exceptionally with the following
* exceptions.
*
* - ValidationException The operation failed due to an invalid or malformed request.
* - ServiceQuotaExceededException The operation exceeded the service quota for this resource. For more
* information on service quotas, see Quotas in the Amazon
* Keyspaces Developer Guide.
* - InternalServerException Amazon Keyspaces was unable to fully process this request because of an
* internal server error.
* - AccessDeniedException You do not have sufficient access to perform this action.
* - ResourceNotFoundException The operation tried to access a keyspace or table that doesn't exist. The
* resource might not be specified correctly, or its status might not be
ACTIVE
.
* - SdkException Base class for all exceptions that can be thrown by the SDK (both service and client).
* Can be used for catch all scenarios.
* - SdkClientException If any client side error occurs such as an IO related failure, failure to get
* credentials, etc.
* - KeyspacesException Base class for all service exceptions. Unknown exceptions will be thrown as an
* instance of this type.
*
* @sample KeyspacesAsyncClient.ListTables
* @see AWS API
* Documentation
*/
default ListTablesPublisher listTablesPaginator(ListTablesRequest listTablesRequest) {
throw new UnsupportedOperationException();
}
/**
*
* Returns a list of tables for a specified keyspace.
*
*
*
* This is a variant of {@link #listTables(software.amazon.awssdk.services.keyspaces.model.ListTablesRequest)}
* operation. The return type is a custom publisher that can be subscribed to request a stream of response pages.
* SDK will internally handle making service calls for you.
*
*
* When the operation is called, an instance of this class is returned. At this point, no service calls are made yet
* and so there is no guarantee that the request is valid. If there are errors in your request, you will see the
* failures only after you start streaming the data. The subscribe method should be called as a request to start
* streaming data. For more info, see
* {@link org.reactivestreams.Publisher#subscribe(org.reactivestreams.Subscriber)}. Each call to the subscribe
* method will result in a new {@link org.reactivestreams.Subscription} i.e., a new contract to stream data from the
* starting request.
*
*
*
* The following are few ways to use the response class:
*
* 1) Using the subscribe helper method
*
*
* {@code
* software.amazon.awssdk.services.keyspaces.paginators.ListTablesPublisher publisher = client.listTablesPaginator(request);
* CompletableFuture future = publisher.subscribe(res -> { // Do something with the response });
* future.get();
* }
*
*
* 2) Using a custom subscriber
*
*
* {@code
* software.amazon.awssdk.services.keyspaces.paginators.ListTablesPublisher publisher = client.listTablesPaginator(request);
* publisher.subscribe(new Subscriber() {
*
* public void onSubscribe(org.reactivestreams.Subscriber subscription) { //... };
*
*
* public void onNext(software.amazon.awssdk.services.keyspaces.model.ListTablesResponse response) { //... };
* });}
*
*
* As the response is a publisher, it can work well with third party reactive streams implementations like RxJava2.
*
* Please notice that the configuration of maxResults won't limit the number of results you get with the
* paginator. It only limits the number of results in each page.
*
*
* Note: If you prefer to have control on service calls, use the
* {@link #listTables(software.amazon.awssdk.services.keyspaces.model.ListTablesRequest)} operation.
*
*
* This is a convenience which creates an instance of the {@link ListTablesRequest.Builder} avoiding the need to
* create one manually via {@link ListTablesRequest#builder()}
*
*
* @param listTablesRequest
* A {@link Consumer} that will call methods on {@link ListTablesRequest.Builder} to create a request.
* @return A custom publisher that can be subscribed to request a stream of response pages.
* The CompletableFuture returned by this method can be completed exceptionally with the following
* exceptions.
*
* - ValidationException The operation failed due to an invalid or malformed request.
* - ServiceQuotaExceededException The operation exceeded the service quota for this resource. For more
* information on service quotas, see Quotas in the Amazon
* Keyspaces Developer Guide.
* - InternalServerException Amazon Keyspaces was unable to fully process this request because of an
* internal server error.
* - AccessDeniedException You do not have sufficient access to perform this action.
* - ResourceNotFoundException The operation tried to access a keyspace or table that doesn't exist. The
* resource might not be specified correctly, or its status might not be
ACTIVE
.
* - SdkException Base class for all exceptions that can be thrown by the SDK (both service and client).
* Can be used for catch all scenarios.
* - SdkClientException If any client side error occurs such as an IO related failure, failure to get
* credentials, etc.
* - KeyspacesException Base class for all service exceptions. Unknown exceptions will be thrown as an
* instance of this type.
*
* @sample KeyspacesAsyncClient.ListTables
* @see AWS API
* Documentation
*/
default ListTablesPublisher listTablesPaginator(Consumer listTablesRequest) {
return listTablesPaginator(ListTablesRequest.builder().applyMutation(listTablesRequest).build());
}
/**
*
* Returns a list of all tags associated with the specified Amazon Keyspaces resource.
*
*
* @param listTagsForResourceRequest
* @return A Java Future containing the result of the ListTagsForResource operation returned by the service.
* The CompletableFuture returned by this method can be completed exceptionally with the following
* exceptions.
*
* - ValidationException The operation failed due to an invalid or malformed request.
* - ServiceQuotaExceededException The operation exceeded the service quota for this resource. For more
* information on service quotas, see Quotas in the Amazon
* Keyspaces Developer Guide.
* - InternalServerException Amazon Keyspaces was unable to fully process this request because of an
* internal server error.
* - AccessDeniedException You do not have sufficient access to perform this action.
* - ResourceNotFoundException The operation tried to access a keyspace or table that doesn't exist. The
* resource might not be specified correctly, or its status might not be
ACTIVE
.
* - SdkException Base class for all exceptions that can be thrown by the SDK (both service and client).
* Can be used for catch all scenarios.
* - SdkClientException If any client side error occurs such as an IO related failure, failure to get
* credentials, etc.
* - KeyspacesException Base class for all service exceptions. Unknown exceptions will be thrown as an
* instance of this type.
*
* @sample KeyspacesAsyncClient.ListTagsForResource
* @see AWS
* API Documentation
*/
default CompletableFuture listTagsForResource(
ListTagsForResourceRequest listTagsForResourceRequest) {
throw new UnsupportedOperationException();
}
/**
*
* Returns a list of all tags associated with the specified Amazon Keyspaces resource.
*
*
*
* This is a convenience which creates an instance of the {@link ListTagsForResourceRequest.Builder} avoiding the
* need to create one manually via {@link ListTagsForResourceRequest#builder()}
*
*
* @param listTagsForResourceRequest
* A {@link Consumer} that will call methods on {@link ListTagsForResourceRequest.Builder} to create a
* request.
* @return A Java Future containing the result of the ListTagsForResource operation returned by the service.
* The CompletableFuture returned by this method can be completed exceptionally with the following
* exceptions.
*
* - ValidationException The operation failed due to an invalid or malformed request.
* - ServiceQuotaExceededException The operation exceeded the service quota for this resource. For more
* information on service quotas, see Quotas in the Amazon
* Keyspaces Developer Guide.
* - InternalServerException Amazon Keyspaces was unable to fully process this request because of an
* internal server error.
* - AccessDeniedException You do not have sufficient access to perform this action.
* - ResourceNotFoundException The operation tried to access a keyspace or table that doesn't exist. The
* resource might not be specified correctly, or its status might not be
ACTIVE
.
* - SdkException Base class for all exceptions that can be thrown by the SDK (both service and client).
* Can be used for catch all scenarios.
* - SdkClientException If any client side error occurs such as an IO related failure, failure to get
* credentials, etc.
* - KeyspacesException Base class for all service exceptions. Unknown exceptions will be thrown as an
* instance of this type.
*
* @sample KeyspacesAsyncClient.ListTagsForResource
* @see AWS
* API Documentation
*/
default CompletableFuture listTagsForResource(
Consumer listTagsForResourceRequest) {
return listTagsForResource(ListTagsForResourceRequest.builder().applyMutation(listTagsForResourceRequest).build());
}
/**
*
* Returns a list of all tags associated with the specified Amazon Keyspaces resource.
*
*
*
* This is a variant of
* {@link #listTagsForResource(software.amazon.awssdk.services.keyspaces.model.ListTagsForResourceRequest)}
* operation. The return type is a custom publisher that can be subscribed to request a stream of response pages.
* SDK will internally handle making service calls for you.
*
*
* When the operation is called, an instance of this class is returned. At this point, no service calls are made yet
* and so there is no guarantee that the request is valid. If there are errors in your request, you will see the
* failures only after you start streaming the data. The subscribe method should be called as a request to start
* streaming data. For more info, see
* {@link org.reactivestreams.Publisher#subscribe(org.reactivestreams.Subscriber)}. Each call to the subscribe
* method will result in a new {@link org.reactivestreams.Subscription} i.e., a new contract to stream data from the
* starting request.
*
*
*
* The following are few ways to use the response class:
*
* 1) Using the subscribe helper method
*
*
* {@code
* software.amazon.awssdk.services.keyspaces.paginators.ListTagsForResourcePublisher publisher = client.listTagsForResourcePaginator(request);
* CompletableFuture future = publisher.subscribe(res -> { // Do something with the response });
* future.get();
* }
*
*
* 2) Using a custom subscriber
*
*
* {@code
* software.amazon.awssdk.services.keyspaces.paginators.ListTagsForResourcePublisher publisher = client.listTagsForResourcePaginator(request);
* publisher.subscribe(new Subscriber() {
*
* public void onSubscribe(org.reactivestreams.Subscriber subscription) { //... };
*
*
* public void onNext(software.amazon.awssdk.services.keyspaces.model.ListTagsForResourceResponse response) { //... };
* });}
*
*
* As the response is a publisher, it can work well with third party reactive streams implementations like RxJava2.
*
* Please notice that the configuration of maxResults won't limit the number of results you get with the
* paginator. It only limits the number of results in each page.
*
*
* Note: If you prefer to have control on service calls, use the
* {@link #listTagsForResource(software.amazon.awssdk.services.keyspaces.model.ListTagsForResourceRequest)}
* operation.
*
*
* @param listTagsForResourceRequest
* @return A custom publisher that can be subscribed to request a stream of response pages.
* The CompletableFuture returned by this method can be completed exceptionally with the following
* exceptions.
*
* - ValidationException The operation failed due to an invalid or malformed request.
* - ServiceQuotaExceededException The operation exceeded the service quota for this resource. For more
* information on service quotas, see Quotas in the Amazon
* Keyspaces Developer Guide.
* - InternalServerException Amazon Keyspaces was unable to fully process this request because of an
* internal server error.
* - AccessDeniedException You do not have sufficient access to perform this action.
* - ResourceNotFoundException The operation tried to access a keyspace or table that doesn't exist. The
* resource might not be specified correctly, or its status might not be
ACTIVE
.
* - SdkException Base class for all exceptions that can be thrown by the SDK (both service and client).
* Can be used for catch all scenarios.
* - SdkClientException If any client side error occurs such as an IO related failure, failure to get
* credentials, etc.
* - KeyspacesException Base class for all service exceptions. Unknown exceptions will be thrown as an
* instance of this type.
*
* @sample KeyspacesAsyncClient.ListTagsForResource
* @see AWS
* API Documentation
*/
default ListTagsForResourcePublisher listTagsForResourcePaginator(ListTagsForResourceRequest listTagsForResourceRequest) {
throw new UnsupportedOperationException();
}
/**
*
* Returns a list of all tags associated with the specified Amazon Keyspaces resource.
*
*
*
* This is a variant of
* {@link #listTagsForResource(software.amazon.awssdk.services.keyspaces.model.ListTagsForResourceRequest)}
* operation. The return type is a custom publisher that can be subscribed to request a stream of response pages.
* SDK will internally handle making service calls for you.
*
*
* When the operation is called, an instance of this class is returned. At this point, no service calls are made yet
* and so there is no guarantee that the request is valid. If there are errors in your request, you will see the
* failures only after you start streaming the data. The subscribe method should be called as a request to start
* streaming data. For more info, see
* {@link org.reactivestreams.Publisher#subscribe(org.reactivestreams.Subscriber)}. Each call to the subscribe
* method will result in a new {@link org.reactivestreams.Subscription} i.e., a new contract to stream data from the
* starting request.
*
*
*
* The following are few ways to use the response class:
*
* 1) Using the subscribe helper method
*
*
* {@code
* software.amazon.awssdk.services.keyspaces.paginators.ListTagsForResourcePublisher publisher = client.listTagsForResourcePaginator(request);
* CompletableFuture future = publisher.subscribe(res -> { // Do something with the response });
* future.get();
* }
*
*
* 2) Using a custom subscriber
*
*
* {@code
* software.amazon.awssdk.services.keyspaces.paginators.ListTagsForResourcePublisher publisher = client.listTagsForResourcePaginator(request);
* publisher.subscribe(new Subscriber() {
*
* public void onSubscribe(org.reactivestreams.Subscriber subscription) { //... };
*
*
* public void onNext(software.amazon.awssdk.services.keyspaces.model.ListTagsForResourceResponse response) { //... };
* });}
*
*
* As the response is a publisher, it can work well with third party reactive streams implementations like RxJava2.
*
* Please notice that the configuration of maxResults won't limit the number of results you get with the
* paginator. It only limits the number of results in each page.
*
*
* Note: If you prefer to have control on service calls, use the
* {@link #listTagsForResource(software.amazon.awssdk.services.keyspaces.model.ListTagsForResourceRequest)}
* operation.
*
*
* This is a convenience which creates an instance of the {@link ListTagsForResourceRequest.Builder} avoiding the
* need to create one manually via {@link ListTagsForResourceRequest#builder()}
*
*
* @param listTagsForResourceRequest
* A {@link Consumer} that will call methods on {@link ListTagsForResourceRequest.Builder} to create a
* request.
* @return A custom publisher that can be subscribed to request a stream of response pages.
* The CompletableFuture returned by this method can be completed exceptionally with the following
* exceptions.
*
* - ValidationException The operation failed due to an invalid or malformed request.
* - ServiceQuotaExceededException The operation exceeded the service quota for this resource. For more
* information on service quotas, see Quotas in the Amazon
* Keyspaces Developer Guide.
* - InternalServerException Amazon Keyspaces was unable to fully process this request because of an
* internal server error.
* - AccessDeniedException You do not have sufficient access to perform this action.
* - ResourceNotFoundException The operation tried to access a keyspace or table that doesn't exist. The
* resource might not be specified correctly, or its status might not be
ACTIVE
.
* - SdkException Base class for all exceptions that can be thrown by the SDK (both service and client).
* Can be used for catch all scenarios.
* - SdkClientException If any client side error occurs such as an IO related failure, failure to get
* credentials, etc.
* - KeyspacesException Base class for all service exceptions. Unknown exceptions will be thrown as an
* instance of this type.
*
* @sample KeyspacesAsyncClient.ListTagsForResource
* @see AWS
* API Documentation
*/
default ListTagsForResourcePublisher listTagsForResourcePaginator(
Consumer listTagsForResourceRequest) {
return listTagsForResourcePaginator(ListTagsForResourceRequest.builder().applyMutation(listTagsForResourceRequest)
.build());
}
/**
*
* Restores the specified table to the specified point in time within the earliest_restorable_timestamp
* and the current time. For more information about restore points, see Time window for PITR continuous backups in the Amazon Keyspaces Developer Guide.
*
*
* Any number of users can execute up to 4 concurrent restores (any type of restore) in a given account.
*
*
* When you restore using point in time recovery, Amazon Keyspaces restores your source table's schema and data to
* the state based on the selected timestamp (day:hour:minute:second)
to a new table. The Time to Live
* (TTL) settings are also restored to the state based on the selected timestamp.
*
*
* In addition to the table's schema, data, and TTL settings, RestoreTable
restores the capacity mode,
* encryption, and point-in-time recovery settings from the source table. Unlike the table's schema data and TTL
* settings, which are restored based on the selected timestamp, these settings are always restored based on the
* table's settings as of the current time or when the table was deleted.
*
*
* You can also overwrite these settings during restore:
*
*
* • Read/write capacity mode
*
*
* • Provisioned throughput capacity settings
*
*
* • Point-in-time (PITR) settings
*
*
* • Tags
*
*
* For more information, see PITR restore settings in the Amazon Keyspaces Developer Guide.
*
*
* Note that the following settings are not restored, and you must configure them manually for the new table:
*
*
* • Automatic scaling policies (for tables that use provisioned capacity mode)
*
*
* • Identity and Access Management (IAM) policies
*
*
* • Amazon CloudWatch metrics and alarms
*
*
* @param restoreTableRequest
* @return A Java Future containing the result of the RestoreTable operation returned by the service.
* The CompletableFuture returned by this method can be completed exceptionally with the following
* exceptions.
*
* - ValidationException The operation failed due to an invalid or malformed request.
* - ServiceQuotaExceededException The operation exceeded the service quota for this resource. For more
* information on service quotas, see Quotas in the Amazon
* Keyspaces Developer Guide.
* - InternalServerException Amazon Keyspaces was unable to fully process this request because of an
* internal server error.
* - ConflictException Amazon Keyspaces could not complete the requested action. This error may occur if
* you try to perform an action and the same or a different action is already in progress, or if you try to
* create a resource that already exists.
* - AccessDeniedException You do not have sufficient access to perform this action.
* - ResourceNotFoundException The operation tried to access a keyspace or table that doesn't exist. The
* resource might not be specified correctly, or its status might not be
ACTIVE
.
* - SdkException Base class for all exceptions that can be thrown by the SDK (both service and client).
* Can be used for catch all scenarios.
* - SdkClientException If any client side error occurs such as an IO related failure, failure to get
* credentials, etc.
* - KeyspacesException Base class for all service exceptions. Unknown exceptions will be thrown as an
* instance of this type.
*
* @sample KeyspacesAsyncClient.RestoreTable
* @see AWS API
* Documentation
*/
default CompletableFuture restoreTable(RestoreTableRequest restoreTableRequest) {
throw new UnsupportedOperationException();
}
/**
*
* Restores the specified table to the specified point in time within the earliest_restorable_timestamp
* and the current time. For more information about restore points, see Time window for PITR continuous backups in the Amazon Keyspaces Developer Guide.
*
*
* Any number of users can execute up to 4 concurrent restores (any type of restore) in a given account.
*
*
* When you restore using point in time recovery, Amazon Keyspaces restores your source table's schema and data to
* the state based on the selected timestamp (day:hour:minute:second)
to a new table. The Time to Live
* (TTL) settings are also restored to the state based on the selected timestamp.
*
*
* In addition to the table's schema, data, and TTL settings, RestoreTable
restores the capacity mode,
* encryption, and point-in-time recovery settings from the source table. Unlike the table's schema data and TTL
* settings, which are restored based on the selected timestamp, these settings are always restored based on the
* table's settings as of the current time or when the table was deleted.
*
*
* You can also overwrite these settings during restore:
*
*
* • Read/write capacity mode
*
*
* • Provisioned throughput capacity settings
*
*
* • Point-in-time (PITR) settings
*
*
* • Tags
*
*
* For more information, see PITR restore settings in the Amazon Keyspaces Developer Guide.
*
*
* Note that the following settings are not restored, and you must configure them manually for the new table:
*
*
* • Automatic scaling policies (for tables that use provisioned capacity mode)
*
*
* • Identity and Access Management (IAM) policies
*
*
* • Amazon CloudWatch metrics and alarms
*
*
*
* This is a convenience which creates an instance of the {@link RestoreTableRequest.Builder} avoiding the need to
* create one manually via {@link RestoreTableRequest#builder()}
*
*
* @param restoreTableRequest
* A {@link Consumer} that will call methods on {@link RestoreTableRequest.Builder} to create a request.
* @return A Java Future containing the result of the RestoreTable operation returned by the service.
* The CompletableFuture returned by this method can be completed exceptionally with the following
* exceptions.
*
* - ValidationException The operation failed due to an invalid or malformed request.
* - ServiceQuotaExceededException The operation exceeded the service quota for this resource. For more
* information on service quotas, see Quotas in the Amazon
* Keyspaces Developer Guide.
* - InternalServerException Amazon Keyspaces was unable to fully process this request because of an
* internal server error.
* - ConflictException Amazon Keyspaces could not complete the requested action. This error may occur if
* you try to perform an action and the same or a different action is already in progress, or if you try to
* create a resource that already exists.
* - AccessDeniedException You do not have sufficient access to perform this action.
* - ResourceNotFoundException The operation tried to access a keyspace or table that doesn't exist. The
* resource might not be specified correctly, or its status might not be
ACTIVE
.
* - SdkException Base class for all exceptions that can be thrown by the SDK (both service and client).
* Can be used for catch all scenarios.
* - SdkClientException If any client side error occurs such as an IO related failure, failure to get
* credentials, etc.
* - KeyspacesException Base class for all service exceptions. Unknown exceptions will be thrown as an
* instance of this type.
*
* @sample KeyspacesAsyncClient.RestoreTable
* @see AWS API
* Documentation
*/
default CompletableFuture restoreTable(Consumer restoreTableRequest) {
return restoreTable(RestoreTableRequest.builder().applyMutation(restoreTableRequest).build());
}
/**
*
* Associates a set of tags with a Amazon Keyspaces resource. You can then activate these user-defined tags so that
* they appear on the Cost Management Console for cost allocation tracking. For more information, see Adding tags and labels to
* Amazon Keyspaces resources in the Amazon Keyspaces Developer Guide.
*
*
* For IAM policy examples that show how to control access to Amazon Keyspaces resources based on tags, see Amazon
* Keyspaces resource access based on tags in the Amazon Keyspaces Developer Guide.
*
*
* @param tagResourceRequest
* @return A Java Future containing the result of the TagResource operation returned by the service.
* The CompletableFuture returned by this method can be completed exceptionally with the following
* exceptions.
*
* - ValidationException The operation failed due to an invalid or malformed request.
* - ServiceQuotaExceededException The operation exceeded the service quota for this resource. For more
* information on service quotas, see Quotas in the Amazon
* Keyspaces Developer Guide.
* - InternalServerException Amazon Keyspaces was unable to fully process this request because of an
* internal server error.
* - AccessDeniedException You do not have sufficient access to perform this action.
* - ResourceNotFoundException The operation tried to access a keyspace or table that doesn't exist. The
* resource might not be specified correctly, or its status might not be
ACTIVE
.
* - SdkException Base class for all exceptions that can be thrown by the SDK (both service and client).
* Can be used for catch all scenarios.
* - SdkClientException If any client side error occurs such as an IO related failure, failure to get
* credentials, etc.
* - KeyspacesException Base class for all service exceptions. Unknown exceptions will be thrown as an
* instance of this type.
*
* @sample KeyspacesAsyncClient.TagResource
* @see AWS API
* Documentation
*/
default CompletableFuture tagResource(TagResourceRequest tagResourceRequest) {
throw new UnsupportedOperationException();
}
/**
*
* Associates a set of tags with a Amazon Keyspaces resource. You can then activate these user-defined tags so that
* they appear on the Cost Management Console for cost allocation tracking. For more information, see Adding tags and labels to
* Amazon Keyspaces resources in the Amazon Keyspaces Developer Guide.
*
*
* For IAM policy examples that show how to control access to Amazon Keyspaces resources based on tags, see Amazon
* Keyspaces resource access based on tags in the Amazon Keyspaces Developer Guide.
*
*
*
* This is a convenience which creates an instance of the {@link TagResourceRequest.Builder} avoiding the need to
* create one manually via {@link TagResourceRequest#builder()}
*
*
* @param tagResourceRequest
* A {@link Consumer} that will call methods on {@link TagResourceRequest.Builder} to create a request.
* @return A Java Future containing the result of the TagResource operation returned by the service.
* The CompletableFuture returned by this method can be completed exceptionally with the following
* exceptions.
*
* - ValidationException The operation failed due to an invalid or malformed request.
* - ServiceQuotaExceededException The operation exceeded the service quota for this resource. For more
* information on service quotas, see Quotas in the Amazon
* Keyspaces Developer Guide.
* - InternalServerException Amazon Keyspaces was unable to fully process this request because of an
* internal server error.
* - AccessDeniedException You do not have sufficient access to perform this action.
* - ResourceNotFoundException The operation tried to access a keyspace or table that doesn't exist. The
* resource might not be specified correctly, or its status might not be
ACTIVE
.
* - SdkException Base class for all exceptions that can be thrown by the SDK (both service and client).
* Can be used for catch all scenarios.
* - SdkClientException If any client side error occurs such as an IO related failure, failure to get
* credentials, etc.
* - KeyspacesException Base class for all service exceptions. Unknown exceptions will be thrown as an
* instance of this type.
*
* @sample KeyspacesAsyncClient.TagResource
* @see AWS API
* Documentation
*/
default CompletableFuture tagResource(Consumer tagResourceRequest) {
return tagResource(TagResourceRequest.builder().applyMutation(tagResourceRequest).build());
}
/**
*
* Removes the association of tags from a Amazon Keyspaces resource.
*
*
* @param untagResourceRequest
* @return A Java Future containing the result of the UntagResource operation returned by the service.
* The CompletableFuture returned by this method can be completed exceptionally with the following
* exceptions.
*
* - ValidationException The operation failed due to an invalid or malformed request.
* - ServiceQuotaExceededException The operation exceeded the service quota for this resource. For more
* information on service quotas, see Quotas in the Amazon
* Keyspaces Developer Guide.
* - InternalServerException Amazon Keyspaces was unable to fully process this request because of an
* internal server error.
* - ConflictException Amazon Keyspaces could not complete the requested action. This error may occur if
* you try to perform an action and the same or a different action is already in progress, or if you try to
* create a resource that already exists.
* - AccessDeniedException You do not have sufficient access to perform this action.
* - ResourceNotFoundException The operation tried to access a keyspace or table that doesn't exist. The
* resource might not be specified correctly, or its status might not be
ACTIVE
.
* - SdkException Base class for all exceptions that can be thrown by the SDK (both service and client).
* Can be used for catch all scenarios.
* - SdkClientException If any client side error occurs such as an IO related failure, failure to get
* credentials, etc.
* - KeyspacesException Base class for all service exceptions. Unknown exceptions will be thrown as an
* instance of this type.
*
* @sample KeyspacesAsyncClient.UntagResource
* @see AWS API
* Documentation
*/
default CompletableFuture untagResource(UntagResourceRequest untagResourceRequest) {
throw new UnsupportedOperationException();
}
/**
*
* Removes the association of tags from a Amazon Keyspaces resource.
*
*
*
* This is a convenience which creates an instance of the {@link UntagResourceRequest.Builder} avoiding the need to
* create one manually via {@link UntagResourceRequest#builder()}
*
*
* @param untagResourceRequest
* A {@link Consumer} that will call methods on {@link UntagResourceRequest.Builder} to create a request.
* @return A Java Future containing the result of the UntagResource operation returned by the service.
* The CompletableFuture returned by this method can be completed exceptionally with the following
* exceptions.
*
* - ValidationException The operation failed due to an invalid or malformed request.
* - ServiceQuotaExceededException The operation exceeded the service quota for this resource. For more
* information on service quotas, see Quotas in the Amazon
* Keyspaces Developer Guide.
* - InternalServerException Amazon Keyspaces was unable to fully process this request because of an
* internal server error.
* - ConflictException Amazon Keyspaces could not complete the requested action. This error may occur if
* you try to perform an action and the same or a different action is already in progress, or if you try to
* create a resource that already exists.
* - AccessDeniedException You do not have sufficient access to perform this action.
* - ResourceNotFoundException The operation tried to access a keyspace or table that doesn't exist. The
* resource might not be specified correctly, or its status might not be
ACTIVE
.
* - SdkException Base class for all exceptions that can be thrown by the SDK (both service and client).
* Can be used for catch all scenarios.
* - SdkClientException If any client side error occurs such as an IO related failure, failure to get
* credentials, etc.
* - KeyspacesException Base class for all service exceptions. Unknown exceptions will be thrown as an
* instance of this type.
*
* @sample KeyspacesAsyncClient.UntagResource
* @see AWS API
* Documentation
*/
default CompletableFuture untagResource(Consumer untagResourceRequest) {
return untagResource(UntagResourceRequest.builder().applyMutation(untagResourceRequest).build());
}
/**
*
* Adds new columns to the table or updates one of the table's settings, for example capacity mode, encryption,
* point-in-time recovery, or ttl settings. Note that you can only update one specific table setting per update
* operation.
*
*
* @param updateTableRequest
* @return A Java Future containing the result of the UpdateTable operation returned by the service.
* The CompletableFuture returned by this method can be completed exceptionally with the following
* exceptions.
*
* - ValidationException The operation failed due to an invalid or malformed request.
* - ServiceQuotaExceededException The operation exceeded the service quota for this resource. For more
* information on service quotas, see Quotas in the Amazon
* Keyspaces Developer Guide.
* - InternalServerException Amazon Keyspaces was unable to fully process this request because of an
* internal server error.
* - ConflictException Amazon Keyspaces could not complete the requested action. This error may occur if
* you try to perform an action and the same or a different action is already in progress, or if you try to
* create a resource that already exists.
* - AccessDeniedException You do not have sufficient access to perform this action.
* - ResourceNotFoundException The operation tried to access a keyspace or table that doesn't exist. The
* resource might not be specified correctly, or its status might not be
ACTIVE
.
* - SdkException Base class for all exceptions that can be thrown by the SDK (both service and client).
* Can be used for catch all scenarios.
* - SdkClientException If any client side error occurs such as an IO related failure, failure to get
* credentials, etc.
* - KeyspacesException Base class for all service exceptions. Unknown exceptions will be thrown as an
* instance of this type.
*
* @sample KeyspacesAsyncClient.UpdateTable
* @see AWS API
* Documentation
*/
default CompletableFuture updateTable(UpdateTableRequest updateTableRequest) {
throw new UnsupportedOperationException();
}
/**
*
* Adds new columns to the table or updates one of the table's settings, for example capacity mode, encryption,
* point-in-time recovery, or ttl settings. Note that you can only update one specific table setting per update
* operation.
*
*
*
* This is a convenience which creates an instance of the {@link UpdateTableRequest.Builder} avoiding the need to
* create one manually via {@link UpdateTableRequest#builder()}
*
*
* @param updateTableRequest
* A {@link Consumer} that will call methods on {@link UpdateTableRequest.Builder} to create a request.
* @return A Java Future containing the result of the UpdateTable operation returned by the service.
* The CompletableFuture returned by this method can be completed exceptionally with the following
* exceptions.
*
* - ValidationException The operation failed due to an invalid or malformed request.
* - ServiceQuotaExceededException The operation exceeded the service quota for this resource. For more
* information on service quotas, see Quotas in the Amazon
* Keyspaces Developer Guide.
* - InternalServerException Amazon Keyspaces was unable to fully process this request because of an
* internal server error.
* - ConflictException Amazon Keyspaces could not complete the requested action. This error may occur if
* you try to perform an action and the same or a different action is already in progress, or if you try to
* create a resource that already exists.
* - AccessDeniedException You do not have sufficient access to perform this action.
* - ResourceNotFoundException The operation tried to access a keyspace or table that doesn't exist. The
* resource might not be specified correctly, or its status might not be
ACTIVE
.
* - SdkException Base class for all exceptions that can be thrown by the SDK (both service and client).
* Can be used for catch all scenarios.
* - SdkClientException If any client side error occurs such as an IO related failure, failure to get
* credentials, etc.
* - KeyspacesException Base class for all service exceptions. Unknown exceptions will be thrown as an
* instance of this type.
*
* @sample KeyspacesAsyncClient.UpdateTable
* @see AWS API
* Documentation
*/
default CompletableFuture updateTable(Consumer updateTableRequest) {
return updateTable(UpdateTableRequest.builder().applyMutation(updateTableRequest).build());
}
}