@Generated(value="software.amazon.awssdk:codegen") public interface RedshiftDataAsyncClient extends SdkClient
builder() method.
You can use the Amazon Redshift Data API to run queries on Amazon Redshift tables. You can run individual SQL statements, which are committed if the statement succeeds.
For more information about the Amazon Redshift Data API, see Using the Amazon Redshift Data API in the Amazon Redshift Cluster Management Guide.
| Modifier and Type | Field and Description |
|---|---|
static String |
SERVICE_METADATA_ID
Value for looking up the service's metadata from the
ServiceMetadataProvider. |
static String |
SERVICE_NAME |
| Modifier and Type | Method and Description |
|---|---|
static RedshiftDataAsyncClientBuilder |
builder()
Create a builder that can be used to configure and create a
RedshiftDataAsyncClient. |
default CompletableFuture<CancelStatementResponse> |
cancelStatement(CancelStatementRequest cancelStatementRequest)
Cancels a running query.
|
default CompletableFuture<CancelStatementResponse> |
cancelStatement(Consumer<CancelStatementRequest.Builder> cancelStatementRequest)
Cancels a running query.
|
static RedshiftDataAsyncClient |
create()
Create a
RedshiftDataAsyncClient with the region loaded from the
DefaultAwsRegionProviderChain and credentials loaded from the
DefaultCredentialsProvider. |
default CompletableFuture<DescribeStatementResponse> |
describeStatement(Consumer<DescribeStatementRequest.Builder> describeStatementRequest)
Describes the details about a specific instance when a query was run by the Amazon Redshift Data API.
|
default CompletableFuture<DescribeStatementResponse> |
describeStatement(DescribeStatementRequest describeStatementRequest)
Describes the details about a specific instance when a query was run by the Amazon Redshift Data API.
|
default CompletableFuture<DescribeTableResponse> |
describeTable(Consumer<DescribeTableRequest.Builder> describeTableRequest)
Describes the detailed information about a table from metadata in the cluster.
|
default CompletableFuture<DescribeTableResponse> |
describeTable(DescribeTableRequest describeTableRequest)
Describes the detailed information about a table from metadata in the cluster.
|
default DescribeTablePublisher |
describeTablePaginator(Consumer<DescribeTableRequest.Builder> describeTableRequest)
Describes the detailed information about a table from metadata in the cluster.
|
default DescribeTablePublisher |
describeTablePaginator(DescribeTableRequest describeTableRequest)
Describes the detailed information about a table from metadata in the cluster.
|
default CompletableFuture<ExecuteStatementResponse> |
executeStatement(Consumer<ExecuteStatementRequest.Builder> executeStatementRequest)
Runs an SQL statement, which can be data manipulation language (DML) or data definition language (DDL).
|
default CompletableFuture<ExecuteStatementResponse> |
executeStatement(ExecuteStatementRequest executeStatementRequest)
Runs an SQL statement, which can be data manipulation language (DML) or data definition language (DDL).
|
default CompletableFuture<GetStatementResultResponse> |
getStatementResult(Consumer<GetStatementResultRequest.Builder> getStatementResultRequest)
Fetches the temporarily cached result of an SQL statement.
|
default CompletableFuture<GetStatementResultResponse> |
getStatementResult(GetStatementResultRequest getStatementResultRequest)
Fetches the temporarily cached result of an SQL statement.
|
default GetStatementResultPublisher |
getStatementResultPaginator(Consumer<GetStatementResultRequest.Builder> getStatementResultRequest)
Fetches the temporarily cached result of an SQL statement.
|
default GetStatementResultPublisher |
getStatementResultPaginator(GetStatementResultRequest getStatementResultRequest)
Fetches the temporarily cached result of an SQL statement.
|
default CompletableFuture<ListDatabasesResponse> |
listDatabases(Consumer<ListDatabasesRequest.Builder> listDatabasesRequest)
List the databases in a cluster.
|
default CompletableFuture<ListDatabasesResponse> |
listDatabases(ListDatabasesRequest listDatabasesRequest)
List the databases in a cluster.
|
default ListDatabasesPublisher |
listDatabasesPaginator(Consumer<ListDatabasesRequest.Builder> listDatabasesRequest)
List the databases in a cluster.
|
default ListDatabasesPublisher |
listDatabasesPaginator(ListDatabasesRequest listDatabasesRequest)
List the databases in a cluster.
|
default CompletableFuture<ListSchemasResponse> |
listSchemas(Consumer<ListSchemasRequest.Builder> listSchemasRequest)
Lists the schemas in a database.
|
default CompletableFuture<ListSchemasResponse> |
listSchemas(ListSchemasRequest listSchemasRequest)
Lists the schemas in a database.
|
default ListSchemasPublisher |
listSchemasPaginator(Consumer<ListSchemasRequest.Builder> listSchemasRequest)
Lists the schemas in a database.
|
default ListSchemasPublisher |
listSchemasPaginator(ListSchemasRequest listSchemasRequest)
Lists the schemas in a database.
|
default CompletableFuture<ListStatementsResponse> |
listStatements(Consumer<ListStatementsRequest.Builder> listStatementsRequest)
List of SQL statements.
|
default CompletableFuture<ListStatementsResponse> |
listStatements(ListStatementsRequest listStatementsRequest)
List of SQL statements.
|
default ListStatementsPublisher |
listStatementsPaginator(Consumer<ListStatementsRequest.Builder> listStatementsRequest)
List of SQL statements.
|
default ListStatementsPublisher |
listStatementsPaginator(ListStatementsRequest listStatementsRequest)
List of SQL statements.
|
default CompletableFuture<ListTablesResponse> |
listTables(Consumer<ListTablesRequest.Builder> listTablesRequest)
List the tables in a database.
|
default CompletableFuture<ListTablesResponse> |
listTables(ListTablesRequest listTablesRequest)
List the tables in a database.
|
default ListTablesPublisher |
listTablesPaginator(Consumer<ListTablesRequest.Builder> listTablesRequest)
List the tables in a database.
|
default ListTablesPublisher |
listTablesPaginator(ListTablesRequest listTablesRequest)
List the tables in a database.
|
serviceNameclosestatic final String SERVICE_NAME
static final String SERVICE_METADATA_ID
ServiceMetadataProvider.static RedshiftDataAsyncClient create()
RedshiftDataAsyncClient with the region loaded from the
DefaultAwsRegionProviderChain and credentials loaded from the
DefaultCredentialsProvider.static RedshiftDataAsyncClientBuilder builder()
RedshiftDataAsyncClient.default CompletableFuture<CancelStatementResponse> cancelStatement(CancelStatementRequest cancelStatementRequest)
Cancels a running query. To be canceled, a query must be running.
cancelStatementRequest - default CompletableFuture<CancelStatementResponse> cancelStatement(Consumer<CancelStatementRequest.Builder> cancelStatementRequest)
Cancels a running query. To be canceled, a query must be running.
This is a convenience which creates an instance of the CancelStatementRequest.Builder avoiding the need
to create one manually via CancelStatementRequest.builder()
cancelStatementRequest - A Consumer that will call methods on CancelStatementRequest.Builder to create a request.default CompletableFuture<DescribeStatementResponse> describeStatement(DescribeStatementRequest describeStatementRequest)
Describes the details about a specific instance when a query was run by the Amazon Redshift Data API. The information includes when the query started, when it finished, the query status, the number of rows returned, and the SQL statement.
describeStatementRequest - default CompletableFuture<DescribeStatementResponse> describeStatement(Consumer<DescribeStatementRequest.Builder> describeStatementRequest)
Describes the details about a specific instance when a query was run by the Amazon Redshift Data API. The information includes when the query started, when it finished, the query status, the number of rows returned, and the SQL statement.
This is a convenience which creates an instance of the DescribeStatementRequest.Builder avoiding the need
to create one manually via DescribeStatementRequest.builder()
describeStatementRequest - A Consumer that will call methods on DescribeStatementRequest.Builder to create a request.default CompletableFuture<DescribeTableResponse> describeTable(DescribeTableRequest describeTableRequest)
Describes the detailed information about a table from metadata in the cluster. The information includes its columns. A token is returned to page through the column list. Depending on the authorization method, use one of the following combinations of request parameters:
AWS Secrets Manager - specify the Amazon Resource Name (ARN) of the secret and the cluster identifier that matches the cluster in the secret.
Temporary credentials - specify the cluster identifier, the database name, and the database user name. Permission
to call the redshift:GetClusterCredentials operation is required to use this method.
describeTableRequest - default CompletableFuture<DescribeTableResponse> describeTable(Consumer<DescribeTableRequest.Builder> describeTableRequest)
Describes the detailed information about a table from metadata in the cluster. The information includes its columns. A token is returned to page through the column list. Depending on the authorization method, use one of the following combinations of request parameters:
AWS Secrets Manager - specify the Amazon Resource Name (ARN) of the secret and the cluster identifier that matches the cluster in the secret.
Temporary credentials - specify the cluster identifier, the database name, and the database user name. Permission
to call the redshift:GetClusterCredentials operation is required to use this method.
This is a convenience which creates an instance of the DescribeTableRequest.Builder avoiding the need to
create one manually via DescribeTableRequest.builder()
describeTableRequest - A Consumer that will call methods on DescribeTableRequest.Builder to create a request.default DescribeTablePublisher describeTablePaginator(DescribeTableRequest describeTableRequest)
Describes the detailed information about a table from metadata in the cluster. The information includes its columns. A token is returned to page through the column list. Depending on the authorization method, use one of the following combinations of request parameters:
AWS Secrets Manager - specify the Amazon Resource Name (ARN) of the secret and the cluster identifier that matches the cluster in the secret.
Temporary credentials - specify the cluster identifier, the database name, and the database user name. Permission
to call the redshift:GetClusterCredentials operation is required to use this method.
This is a variant of
describeTable(software.amazon.awssdk.services.redshiftdata.model.DescribeTableRequest) 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
Publisher.subscribe(org.reactivestreams.Subscriber). Each call to the subscribe
method will result in a new 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
software.amazon.awssdk.services.redshiftdata.paginators.DescribeTablePublisher publisher = client.describeTablePaginator(request);
CompletableFuture<Void> future = publisher.subscribe(res -> { // Do something with the response });
future.get();
2) Using a custom subscriber
software.amazon.awssdk.services.redshiftdata.paginators.DescribeTablePublisher publisher = client.describeTablePaginator(request);
publisher.subscribe(new Subscriber<software.amazon.awssdk.services.redshiftdata.model.DescribeTableResponse>() {
public void onSubscribe(org.reactivestreams.Subscriber subscription) { //... };
public void onNext(software.amazon.awssdk.services.redshiftdata.model.DescribeTableResponse 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
describeTable(software.amazon.awssdk.services.redshiftdata.model.DescribeTableRequest) operation.
describeTableRequest - default DescribeTablePublisher describeTablePaginator(Consumer<DescribeTableRequest.Builder> describeTableRequest)
Describes the detailed information about a table from metadata in the cluster. The information includes its columns. A token is returned to page through the column list. Depending on the authorization method, use one of the following combinations of request parameters:
AWS Secrets Manager - specify the Amazon Resource Name (ARN) of the secret and the cluster identifier that matches the cluster in the secret.
Temporary credentials - specify the cluster identifier, the database name, and the database user name. Permission
to call the redshift:GetClusterCredentials operation is required to use this method.
This is a variant of
describeTable(software.amazon.awssdk.services.redshiftdata.model.DescribeTableRequest) 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
Publisher.subscribe(org.reactivestreams.Subscriber). Each call to the subscribe
method will result in a new 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
software.amazon.awssdk.services.redshiftdata.paginators.DescribeTablePublisher publisher = client.describeTablePaginator(request);
CompletableFuture<Void> future = publisher.subscribe(res -> { // Do something with the response });
future.get();
2) Using a custom subscriber
software.amazon.awssdk.services.redshiftdata.paginators.DescribeTablePublisher publisher = client.describeTablePaginator(request);
publisher.subscribe(new Subscriber<software.amazon.awssdk.services.redshiftdata.model.DescribeTableResponse>() {
public void onSubscribe(org.reactivestreams.Subscriber subscription) { //... };
public void onNext(software.amazon.awssdk.services.redshiftdata.model.DescribeTableResponse 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
describeTable(software.amazon.awssdk.services.redshiftdata.model.DescribeTableRequest) operation.
This is a convenience which creates an instance of the DescribeTableRequest.Builder avoiding the need to
create one manually via DescribeTableRequest.builder()
describeTableRequest - A Consumer that will call methods on DescribeTableRequest.Builder to create a request.default CompletableFuture<ExecuteStatementResponse> executeStatement(ExecuteStatementRequest executeStatementRequest)
Runs an SQL statement, which can be data manipulation language (DML) or data definition language (DDL). This statement must be a single SQL statement. Depending on the authorization method, use one of the following combinations of request parameters:
AWS Secrets Manager - specify the Amazon Resource Name (ARN) of the secret and the cluster identifier that matches the cluster in the secret.
Temporary credentials - specify the cluster identifier, the database name, and the database user name. Permission
to call the redshift:GetClusterCredentials operation is required to use this method.
executeStatementRequest - default CompletableFuture<ExecuteStatementResponse> executeStatement(Consumer<ExecuteStatementRequest.Builder> executeStatementRequest)
Runs an SQL statement, which can be data manipulation language (DML) or data definition language (DDL). This statement must be a single SQL statement. Depending on the authorization method, use one of the following combinations of request parameters:
AWS Secrets Manager - specify the Amazon Resource Name (ARN) of the secret and the cluster identifier that matches the cluster in the secret.
Temporary credentials - specify the cluster identifier, the database name, and the database user name. Permission
to call the redshift:GetClusterCredentials operation is required to use this method.
This is a convenience which creates an instance of the ExecuteStatementRequest.Builder avoiding the need
to create one manually via ExecuteStatementRequest.builder()
executeStatementRequest - A Consumer that will call methods on ExecuteStatementInput.Builder to create a request.default CompletableFuture<GetStatementResultResponse> getStatementResult(GetStatementResultRequest getStatementResultRequest)
Fetches the temporarily cached result of an SQL statement. A token is returned to page through the statement results.
getStatementResultRequest - default CompletableFuture<GetStatementResultResponse> getStatementResult(Consumer<GetStatementResultRequest.Builder> getStatementResultRequest)
Fetches the temporarily cached result of an SQL statement. A token is returned to page through the statement results.
This is a convenience which creates an instance of the GetStatementResultRequest.Builder avoiding the
need to create one manually via GetStatementResultRequest.builder()
getStatementResultRequest - A Consumer that will call methods on GetStatementResultRequest.Builder to create a
request.default GetStatementResultPublisher getStatementResultPaginator(GetStatementResultRequest getStatementResultRequest)
Fetches the temporarily cached result of an SQL statement. A token is returned to page through the statement results.
This is a variant of
getStatementResult(software.amazon.awssdk.services.redshiftdata.model.GetStatementResultRequest)
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
Publisher.subscribe(org.reactivestreams.Subscriber). Each call to the subscribe
method will result in a new 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
software.amazon.awssdk.services.redshiftdata.paginators.GetStatementResultPublisher publisher = client.getStatementResultPaginator(request);
CompletableFuture<Void> future = publisher.subscribe(res -> { // Do something with the response });
future.get();
2) Using a custom subscriber
software.amazon.awssdk.services.redshiftdata.paginators.GetStatementResultPublisher publisher = client.getStatementResultPaginator(request);
publisher.subscribe(new Subscriber<software.amazon.awssdk.services.redshiftdata.model.GetStatementResultResponse>() {
public void onSubscribe(org.reactivestreams.Subscriber subscription) { //... };
public void onNext(software.amazon.awssdk.services.redshiftdata.model.GetStatementResultResponse 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 null 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
getStatementResult(software.amazon.awssdk.services.redshiftdata.model.GetStatementResultRequest)
operation.
getStatementResultRequest - default GetStatementResultPublisher getStatementResultPaginator(Consumer<GetStatementResultRequest.Builder> getStatementResultRequest)
Fetches the temporarily cached result of an SQL statement. A token is returned to page through the statement results.
This is a variant of
getStatementResult(software.amazon.awssdk.services.redshiftdata.model.GetStatementResultRequest)
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
Publisher.subscribe(org.reactivestreams.Subscriber). Each call to the subscribe
method will result in a new 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
software.amazon.awssdk.services.redshiftdata.paginators.GetStatementResultPublisher publisher = client.getStatementResultPaginator(request);
CompletableFuture<Void> future = publisher.subscribe(res -> { // Do something with the response });
future.get();
2) Using a custom subscriber
software.amazon.awssdk.services.redshiftdata.paginators.GetStatementResultPublisher publisher = client.getStatementResultPaginator(request);
publisher.subscribe(new Subscriber<software.amazon.awssdk.services.redshiftdata.model.GetStatementResultResponse>() {
public void onSubscribe(org.reactivestreams.Subscriber subscription) { //... };
public void onNext(software.amazon.awssdk.services.redshiftdata.model.GetStatementResultResponse 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 null 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
getStatementResult(software.amazon.awssdk.services.redshiftdata.model.GetStatementResultRequest)
operation.
This is a convenience which creates an instance of the GetStatementResultRequest.Builder avoiding the
need to create one manually via GetStatementResultRequest.builder()
getStatementResultRequest - A Consumer that will call methods on GetStatementResultRequest.Builder to create a
request.default CompletableFuture<ListDatabasesResponse> listDatabases(ListDatabasesRequest listDatabasesRequest)
List the databases in a cluster. A token is returned to page through the database list. Depending on the authorization method, use one of the following combinations of request parameters:
AWS Secrets Manager - specify the Amazon Resource Name (ARN) of the secret and the cluster identifier that matches the cluster in the secret.
Temporary credentials - specify the cluster identifier, the database name, and the database user name. Permission
to call the redshift:GetClusterCredentials operation is required to use this method.
listDatabasesRequest - default CompletableFuture<ListDatabasesResponse> listDatabases(Consumer<ListDatabasesRequest.Builder> listDatabasesRequest)
List the databases in a cluster. A token is returned to page through the database list. Depending on the authorization method, use one of the following combinations of request parameters:
AWS Secrets Manager - specify the Amazon Resource Name (ARN) of the secret and the cluster identifier that matches the cluster in the secret.
Temporary credentials - specify the cluster identifier, the database name, and the database user name. Permission
to call the redshift:GetClusterCredentials operation is required to use this method.
This is a convenience which creates an instance of the ListDatabasesRequest.Builder avoiding the need to
create one manually via ListDatabasesRequest.builder()
listDatabasesRequest - A Consumer that will call methods on ListDatabasesRequest.Builder to create a request.default ListDatabasesPublisher listDatabasesPaginator(ListDatabasesRequest listDatabasesRequest)
List the databases in a cluster. A token is returned to page through the database list. Depending on the authorization method, use one of the following combinations of request parameters:
AWS Secrets Manager - specify the Amazon Resource Name (ARN) of the secret and the cluster identifier that matches the cluster in the secret.
Temporary credentials - specify the cluster identifier, the database name, and the database user name. Permission
to call the redshift:GetClusterCredentials operation is required to use this method.
This is a variant of
listDatabases(software.amazon.awssdk.services.redshiftdata.model.ListDatabasesRequest) 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
Publisher.subscribe(org.reactivestreams.Subscriber). Each call to the subscribe
method will result in a new 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
software.amazon.awssdk.services.redshiftdata.paginators.ListDatabasesPublisher publisher = client.listDatabasesPaginator(request);
CompletableFuture<Void> future = publisher.subscribe(res -> { // Do something with the response });
future.get();
2) Using a custom subscriber
software.amazon.awssdk.services.redshiftdata.paginators.ListDatabasesPublisher publisher = client.listDatabasesPaginator(request);
publisher.subscribe(new Subscriber<software.amazon.awssdk.services.redshiftdata.model.ListDatabasesResponse>() {
public void onSubscribe(org.reactivestreams.Subscriber subscription) { //... };
public void onNext(software.amazon.awssdk.services.redshiftdata.model.ListDatabasesResponse 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
listDatabases(software.amazon.awssdk.services.redshiftdata.model.ListDatabasesRequest) operation.
listDatabasesRequest - default ListDatabasesPublisher listDatabasesPaginator(Consumer<ListDatabasesRequest.Builder> listDatabasesRequest)
List the databases in a cluster. A token is returned to page through the database list. Depending on the authorization method, use one of the following combinations of request parameters:
AWS Secrets Manager - specify the Amazon Resource Name (ARN) of the secret and the cluster identifier that matches the cluster in the secret.
Temporary credentials - specify the cluster identifier, the database name, and the database user name. Permission
to call the redshift:GetClusterCredentials operation is required to use this method.
This is a variant of
listDatabases(software.amazon.awssdk.services.redshiftdata.model.ListDatabasesRequest) 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
Publisher.subscribe(org.reactivestreams.Subscriber). Each call to the subscribe
method will result in a new 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
software.amazon.awssdk.services.redshiftdata.paginators.ListDatabasesPublisher publisher = client.listDatabasesPaginator(request);
CompletableFuture<Void> future = publisher.subscribe(res -> { // Do something with the response });
future.get();
2) Using a custom subscriber
software.amazon.awssdk.services.redshiftdata.paginators.ListDatabasesPublisher publisher = client.listDatabasesPaginator(request);
publisher.subscribe(new Subscriber<software.amazon.awssdk.services.redshiftdata.model.ListDatabasesResponse>() {
public void onSubscribe(org.reactivestreams.Subscriber subscription) { //... };
public void onNext(software.amazon.awssdk.services.redshiftdata.model.ListDatabasesResponse 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
listDatabases(software.amazon.awssdk.services.redshiftdata.model.ListDatabasesRequest) operation.
This is a convenience which creates an instance of the ListDatabasesRequest.Builder avoiding the need to
create one manually via ListDatabasesRequest.builder()
listDatabasesRequest - A Consumer that will call methods on ListDatabasesRequest.Builder to create a request.default CompletableFuture<ListSchemasResponse> listSchemas(ListSchemasRequest listSchemasRequest)
Lists the schemas in a database. A token is returned to page through the schema list. Depending on the authorization method, use one of the following combinations of request parameters:
AWS Secrets Manager - specify the Amazon Resource Name (ARN) of the secret and the cluster identifier that matches the cluster in the secret.
Temporary credentials - specify the cluster identifier, the database name, and the database user name. Permission
to call the redshift:GetClusterCredentials operation is required to use this method.
listSchemasRequest - default CompletableFuture<ListSchemasResponse> listSchemas(Consumer<ListSchemasRequest.Builder> listSchemasRequest)
Lists the schemas in a database. A token is returned to page through the schema list. Depending on the authorization method, use one of the following combinations of request parameters:
AWS Secrets Manager - specify the Amazon Resource Name (ARN) of the secret and the cluster identifier that matches the cluster in the secret.
Temporary credentials - specify the cluster identifier, the database name, and the database user name. Permission
to call the redshift:GetClusterCredentials operation is required to use this method.
This is a convenience which creates an instance of the ListSchemasRequest.Builder avoiding the need to
create one manually via ListSchemasRequest.builder()
listSchemasRequest - A Consumer that will call methods on ListSchemasRequest.Builder to create a request.default ListSchemasPublisher listSchemasPaginator(ListSchemasRequest listSchemasRequest)
Lists the schemas in a database. A token is returned to page through the schema list. Depending on the authorization method, use one of the following combinations of request parameters:
AWS Secrets Manager - specify the Amazon Resource Name (ARN) of the secret and the cluster identifier that matches the cluster in the secret.
Temporary credentials - specify the cluster identifier, the database name, and the database user name. Permission
to call the redshift:GetClusterCredentials operation is required to use this method.
This is a variant of listSchemas(software.amazon.awssdk.services.redshiftdata.model.ListSchemasRequest)
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
Publisher.subscribe(org.reactivestreams.Subscriber). Each call to the subscribe
method will result in a new 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
software.amazon.awssdk.services.redshiftdata.paginators.ListSchemasPublisher publisher = client.listSchemasPaginator(request);
CompletableFuture<Void> future = publisher.subscribe(res -> { // Do something with the response });
future.get();
2) Using a custom subscriber
software.amazon.awssdk.services.redshiftdata.paginators.ListSchemasPublisher publisher = client.listSchemasPaginator(request);
publisher.subscribe(new Subscriber<software.amazon.awssdk.services.redshiftdata.model.ListSchemasResponse>() {
public void onSubscribe(org.reactivestreams.Subscriber subscription) { //... };
public void onNext(software.amazon.awssdk.services.redshiftdata.model.ListSchemasResponse 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
listSchemas(software.amazon.awssdk.services.redshiftdata.model.ListSchemasRequest) operation.
listSchemasRequest - default ListSchemasPublisher listSchemasPaginator(Consumer<ListSchemasRequest.Builder> listSchemasRequest)
Lists the schemas in a database. A token is returned to page through the schema list. Depending on the authorization method, use one of the following combinations of request parameters:
AWS Secrets Manager - specify the Amazon Resource Name (ARN) of the secret and the cluster identifier that matches the cluster in the secret.
Temporary credentials - specify the cluster identifier, the database name, and the database user name. Permission
to call the redshift:GetClusterCredentials operation is required to use this method.
This is a variant of listSchemas(software.amazon.awssdk.services.redshiftdata.model.ListSchemasRequest)
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
Publisher.subscribe(org.reactivestreams.Subscriber). Each call to the subscribe
method will result in a new 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
software.amazon.awssdk.services.redshiftdata.paginators.ListSchemasPublisher publisher = client.listSchemasPaginator(request);
CompletableFuture<Void> future = publisher.subscribe(res -> { // Do something with the response });
future.get();
2) Using a custom subscriber
software.amazon.awssdk.services.redshiftdata.paginators.ListSchemasPublisher publisher = client.listSchemasPaginator(request);
publisher.subscribe(new Subscriber<software.amazon.awssdk.services.redshiftdata.model.ListSchemasResponse>() {
public void onSubscribe(org.reactivestreams.Subscriber subscription) { //... };
public void onNext(software.amazon.awssdk.services.redshiftdata.model.ListSchemasResponse 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
listSchemas(software.amazon.awssdk.services.redshiftdata.model.ListSchemasRequest) operation.
This is a convenience which creates an instance of the ListSchemasRequest.Builder avoiding the need to
create one manually via ListSchemasRequest.builder()
listSchemasRequest - A Consumer that will call methods on ListSchemasRequest.Builder to create a request.default CompletableFuture<ListStatementsResponse> listStatements(ListStatementsRequest listStatementsRequest)
List of SQL statements. By default, only finished statements are shown. A token is returned to page through the statement list.
listStatementsRequest - default CompletableFuture<ListStatementsResponse> listStatements(Consumer<ListStatementsRequest.Builder> listStatementsRequest)
List of SQL statements. By default, only finished statements are shown. A token is returned to page through the statement list.
This is a convenience which creates an instance of the ListStatementsRequest.Builder avoiding the need to
create one manually via ListStatementsRequest.builder()
listStatementsRequest - A Consumer that will call methods on ListStatementsRequest.Builder to create a request.default ListStatementsPublisher listStatementsPaginator(ListStatementsRequest listStatementsRequest)
List of SQL statements. By default, only finished statements are shown. A token is returned to page through the statement list.
This is a variant of
listStatements(software.amazon.awssdk.services.redshiftdata.model.ListStatementsRequest) 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
Publisher.subscribe(org.reactivestreams.Subscriber). Each call to the subscribe
method will result in a new 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
software.amazon.awssdk.services.redshiftdata.paginators.ListStatementsPublisher publisher = client.listStatementsPaginator(request);
CompletableFuture<Void> future = publisher.subscribe(res -> { // Do something with the response });
future.get();
2) Using a custom subscriber
software.amazon.awssdk.services.redshiftdata.paginators.ListStatementsPublisher publisher = client.listStatementsPaginator(request);
publisher.subscribe(new Subscriber<software.amazon.awssdk.services.redshiftdata.model.ListStatementsResponse>() {
public void onSubscribe(org.reactivestreams.Subscriber subscription) { //... };
public void onNext(software.amazon.awssdk.services.redshiftdata.model.ListStatementsResponse 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
listStatements(software.amazon.awssdk.services.redshiftdata.model.ListStatementsRequest) operation.
listStatementsRequest - default ListStatementsPublisher listStatementsPaginator(Consumer<ListStatementsRequest.Builder> listStatementsRequest)
List of SQL statements. By default, only finished statements are shown. A token is returned to page through the statement list.
This is a variant of
listStatements(software.amazon.awssdk.services.redshiftdata.model.ListStatementsRequest) 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
Publisher.subscribe(org.reactivestreams.Subscriber). Each call to the subscribe
method will result in a new 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
software.amazon.awssdk.services.redshiftdata.paginators.ListStatementsPublisher publisher = client.listStatementsPaginator(request);
CompletableFuture<Void> future = publisher.subscribe(res -> { // Do something with the response });
future.get();
2) Using a custom subscriber
software.amazon.awssdk.services.redshiftdata.paginators.ListStatementsPublisher publisher = client.listStatementsPaginator(request);
publisher.subscribe(new Subscriber<software.amazon.awssdk.services.redshiftdata.model.ListStatementsResponse>() {
public void onSubscribe(org.reactivestreams.Subscriber subscription) { //... };
public void onNext(software.amazon.awssdk.services.redshiftdata.model.ListStatementsResponse 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
listStatements(software.amazon.awssdk.services.redshiftdata.model.ListStatementsRequest) operation.
This is a convenience which creates an instance of the ListStatementsRequest.Builder avoiding the need to
create one manually via ListStatementsRequest.builder()
listStatementsRequest - A Consumer that will call methods on ListStatementsRequest.Builder to create a request.default CompletableFuture<ListTablesResponse> listTables(ListTablesRequest listTablesRequest)
List the tables in a database. If neither SchemaPattern nor TablePattern are specified,
then all tables in the database are returned. A token is returned to page through the table list. Depending on
the authorization method, use one of the following combinations of request parameters:
AWS Secrets Manager - specify the Amazon Resource Name (ARN) of the secret and the cluster identifier that matches the cluster in the secret.
Temporary credentials - specify the cluster identifier, the database name, and the database user name. Permission
to call the redshift:GetClusterCredentials operation is required to use this method.
listTablesRequest - default CompletableFuture<ListTablesResponse> listTables(Consumer<ListTablesRequest.Builder> listTablesRequest)
List the tables in a database. If neither SchemaPattern nor TablePattern are specified,
then all tables in the database are returned. A token is returned to page through the table list. Depending on
the authorization method, use one of the following combinations of request parameters:
AWS Secrets Manager - specify the Amazon Resource Name (ARN) of the secret and the cluster identifier that matches the cluster in the secret.
Temporary credentials - specify the cluster identifier, the database name, and the database user name. Permission
to call the redshift:GetClusterCredentials operation is required to use this method.
This is a convenience which creates an instance of the ListTablesRequest.Builder avoiding the need to
create one manually via ListTablesRequest.builder()
listTablesRequest - A Consumer that will call methods on ListTablesRequest.Builder to create a request.default ListTablesPublisher listTablesPaginator(ListTablesRequest listTablesRequest)
List the tables in a database. If neither SchemaPattern nor TablePattern are specified,
then all tables in the database are returned. A token is returned to page through the table list. Depending on
the authorization method, use one of the following combinations of request parameters:
AWS Secrets Manager - specify the Amazon Resource Name (ARN) of the secret and the cluster identifier that matches the cluster in the secret.
Temporary credentials - specify the cluster identifier, the database name, and the database user name. Permission
to call the redshift:GetClusterCredentials operation is required to use this method.
This is a variant of listTables(software.amazon.awssdk.services.redshiftdata.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
Publisher.subscribe(org.reactivestreams.Subscriber). Each call to the subscribe
method will result in a new 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
software.amazon.awssdk.services.redshiftdata.paginators.ListTablesPublisher publisher = client.listTablesPaginator(request);
CompletableFuture<Void> future = publisher.subscribe(res -> { // Do something with the response });
future.get();
2) Using a custom subscriber
software.amazon.awssdk.services.redshiftdata.paginators.ListTablesPublisher publisher = client.listTablesPaginator(request);
publisher.subscribe(new Subscriber<software.amazon.awssdk.services.redshiftdata.model.ListTablesResponse>() {
public void onSubscribe(org.reactivestreams.Subscriber subscription) { //... };
public void onNext(software.amazon.awssdk.services.redshiftdata.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
listTables(software.amazon.awssdk.services.redshiftdata.model.ListTablesRequest) operation.
listTablesRequest - default ListTablesPublisher listTablesPaginator(Consumer<ListTablesRequest.Builder> listTablesRequest)
List the tables in a database. If neither SchemaPattern nor TablePattern are specified,
then all tables in the database are returned. A token is returned to page through the table list. Depending on
the authorization method, use one of the following combinations of request parameters:
AWS Secrets Manager - specify the Amazon Resource Name (ARN) of the secret and the cluster identifier that matches the cluster in the secret.
Temporary credentials - specify the cluster identifier, the database name, and the database user name. Permission
to call the redshift:GetClusterCredentials operation is required to use this method.
This is a variant of listTables(software.amazon.awssdk.services.redshiftdata.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
Publisher.subscribe(org.reactivestreams.Subscriber). Each call to the subscribe
method will result in a new 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
software.amazon.awssdk.services.redshiftdata.paginators.ListTablesPublisher publisher = client.listTablesPaginator(request);
CompletableFuture<Void> future = publisher.subscribe(res -> { // Do something with the response });
future.get();
2) Using a custom subscriber
software.amazon.awssdk.services.redshiftdata.paginators.ListTablesPublisher publisher = client.listTablesPaginator(request);
publisher.subscribe(new Subscriber<software.amazon.awssdk.services.redshiftdata.model.ListTablesResponse>() {
public void onSubscribe(org.reactivestreams.Subscriber subscription) { //... };
public void onNext(software.amazon.awssdk.services.redshiftdata.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
listTables(software.amazon.awssdk.services.redshiftdata.model.ListTablesRequest) operation.
This is a convenience which creates an instance of the ListTablesRequest.Builder avoiding the need to
create one manually via ListTablesRequest.builder()
listTablesRequest - A Consumer that will call methods on ListTablesRequest.Builder to create a request.Copyright © 2021. All rights reserved.