Interface KeyspacesStreamsClient
- All Superinterfaces:
- AutoCloseable,- AwsClient,- SdkAutoCloseable,- SdkClient
builder()
 method.
 Amazon Keyspaces (for Apache Cassandra) change data capture (CDC) records change events for Amazon Keyspaces tables. The change events captured in a stream are time-ordered and de-duplicated write operations. Using stream data you can build event driven applications that incorporate near-real time change events from Amazon Keyspaces tables.
Amazon Keyspaces CDC is serverless and scales the infrastructure for change events automatically based on the volume of changes on your table.
This API reference describes the Amazon Keyspaces CDC stream API in detail.
For more information about Amazon Keyspaces CDC, see Working with change data capture (CDC) streams in Amazon Keyspaces in the Amazon Keyspaces Developer Guide.
To learn how Amazon Keyspaces CDC API actions are recorded with CloudTrail, see Amazon Keyspaces information in CloudTrail in the Amazon Keyspaces Developer Guide.
To see the metrics Amazon Keyspaces CDC sends to Amazon CloudWatch, see Amazon Keyspaces change data capture (CDC) CloudWatch metrics in the Amazon Keyspaces Developer Guide.
- 
Field SummaryFieldsModifier and TypeFieldDescriptionstatic final StringValue for looking up the service's metadata from theServiceMetadataProvider.static final String
- 
Method SummaryModifier and TypeMethodDescriptionbuilder()Create a builder that can be used to configure and create aKeyspacesStreamsClient.static KeyspacesStreamsClientcreate()Create aKeyspacesStreamsClientwith the region loaded from theDefaultAwsRegionProviderChainand credentials loaded from theDefaultCredentialsProvider.default GetRecordsResponsegetRecords(Consumer<GetRecordsRequest.Builder> getRecordsRequest) Retrieves data records from a specified shard in an Amazon Keyspaces data stream.default GetRecordsResponsegetRecords(GetRecordsRequest getRecordsRequest) Retrieves data records from a specified shard in an Amazon Keyspaces data stream.default GetShardIteratorResponsegetShardIterator(Consumer<GetShardIteratorRequest.Builder> getShardIteratorRequest) Returns a shard iterator that serves as a bookmark for reading data from a specific position in an Amazon Keyspaces data stream's shard.default GetShardIteratorResponsegetShardIterator(GetShardIteratorRequest getShardIteratorRequest) Returns a shard iterator that serves as a bookmark for reading data from a specific position in an Amazon Keyspaces data stream's shard.default GetStreamResponsegetStream(Consumer<GetStreamRequest.Builder> getStreamRequest) Returns detailed information about a specific data capture stream for an Amazon Keyspaces table.default GetStreamResponsegetStream(GetStreamRequest getStreamRequest) Returns detailed information about a specific data capture stream for an Amazon Keyspaces table.default GetStreamIterablegetStreamPaginator(Consumer<GetStreamRequest.Builder> getStreamRequest) This is a variant ofgetStream(software.amazon.awssdk.services.keyspacesstreams.model.GetStreamRequest)operation.default GetStreamIterablegetStreamPaginator(GetStreamRequest getStreamRequest) This is a variant ofgetStream(software.amazon.awssdk.services.keyspacesstreams.model.GetStreamRequest)operation.default ListStreamsResponselistStreams(Consumer<ListStreamsRequest.Builder> listStreamsRequest) Returns a list of all data capture streams associated with your Amazon Keyspaces account or for a specific keyspace or table.default ListStreamsResponselistStreams(ListStreamsRequest listStreamsRequest) Returns a list of all data capture streams associated with your Amazon Keyspaces account or for a specific keyspace or table.default ListStreamsIterablelistStreamsPaginator(Consumer<ListStreamsRequest.Builder> listStreamsRequest) This is a variant oflistStreams(software.amazon.awssdk.services.keyspacesstreams.model.ListStreamsRequest)operation.default ListStreamsIterablelistStreamsPaginator(ListStreamsRequest listStreamsRequest) This is a variant oflistStreams(software.amazon.awssdk.services.keyspacesstreams.model.ListStreamsRequest)operation.The SDK service client configuration exposes client settings to the user, e.g., ClientOverrideConfigurationstatic ServiceMetadataMethods inherited from interface software.amazon.awssdk.utils.SdkAutoCloseablecloseMethods inherited from interface software.amazon.awssdk.core.SdkClientserviceName
- 
Field Details- 
SERVICE_NAME- See Also:
 
- 
SERVICE_METADATA_IDValue for looking up the service's metadata from theServiceMetadataProvider.- See Also:
 
 
- 
- 
Method Details- 
getRecordsdefault GetRecordsResponse getRecords(GetRecordsRequest getRecordsRequest) throws ThrottlingException, AccessDeniedException, InternalServerException, ValidationException, ResourceNotFoundException, AwsServiceException, SdkClientException, KeyspacesStreamsException Retrieves data records from a specified shard in an Amazon Keyspaces data stream. This operation returns a collection of data records from the shard, including the primary key columns and information about modifications made to the captured table data. Each record represents a single data modification in the Amazon Keyspaces table and includes metadata about when the change occurred. - Parameters:
- getRecordsRequest-
- Returns:
- Result of the GetRecords operation returned by the service.
- See Also:
 
- 
getRecordsdefault GetRecordsResponse getRecords(Consumer<GetRecordsRequest.Builder> getRecordsRequest) throws ThrottlingException, AccessDeniedException, InternalServerException, ValidationException, ResourceNotFoundException, AwsServiceException, SdkClientException, KeyspacesStreamsException Retrieves data records from a specified shard in an Amazon Keyspaces data stream. This operation returns a collection of data records from the shard, including the primary key columns and information about modifications made to the captured table data. Each record represents a single data modification in the Amazon Keyspaces table and includes metadata about when the change occurred. 
 This is a convenience which creates an instance of the GetRecordsRequest.Builderavoiding the need to create one manually viaGetRecordsRequest.builder()- Parameters:
- getRecordsRequest- A- Consumerthat will call methods on- GetRecordsRequest.Builderto create a request.
- Returns:
- Result of the GetRecords operation returned by the service.
- See Also:
 
- 
getShardIteratordefault GetShardIteratorResponse getShardIterator(GetShardIteratorRequest getShardIteratorRequest) throws ThrottlingException, AccessDeniedException, InternalServerException, ValidationException, ResourceNotFoundException, AwsServiceException, SdkClientException, KeyspacesStreamsException Returns a shard iterator that serves as a bookmark for reading data from a specific position in an Amazon Keyspaces data stream's shard. The shard iterator specifies the shard position from which to start reading data records sequentially. You can specify whether to begin reading at the latest record, the oldest record, or at a particular sequence number within the shard. - Parameters:
- getShardIteratorRequest-
- Returns:
- Result of the GetShardIterator operation returned by the service.
- See Also:
 
- 
getShardIteratordefault GetShardIteratorResponse getShardIterator(Consumer<GetShardIteratorRequest.Builder> getShardIteratorRequest) throws ThrottlingException, AccessDeniedException, InternalServerException, ValidationException, ResourceNotFoundException, AwsServiceException, SdkClientException, KeyspacesStreamsException Returns a shard iterator that serves as a bookmark for reading data from a specific position in an Amazon Keyspaces data stream's shard. The shard iterator specifies the shard position from which to start reading data records sequentially. You can specify whether to begin reading at the latest record, the oldest record, or at a particular sequence number within the shard. 
 This is a convenience which creates an instance of the GetShardIteratorRequest.Builderavoiding the need to create one manually viaGetShardIteratorRequest.builder()- Parameters:
- getShardIteratorRequest- A- Consumerthat will call methods on- GetShardIteratorRequest.Builderto create a request.
- Returns:
- Result of the GetShardIterator operation returned by the service.
- See Also:
 
- 
getStreamdefault GetStreamResponse getStream(GetStreamRequest getStreamRequest) throws ThrottlingException, AccessDeniedException, InternalServerException, ValidationException, ResourceNotFoundException, AwsServiceException, SdkClientException, KeyspacesStreamsException Returns detailed information about a specific data capture stream for an Amazon Keyspaces table. The information includes the stream's Amazon Resource Name (ARN), creation time, current status, retention period, shard composition, and associated table details. This operation helps you monitor and manage the configuration of your Amazon Keyspaces data streams. - Parameters:
- getStreamRequest-
- Returns:
- Result of the GetStream operation returned by the service.
- See Also:
 
- 
getStreamdefault GetStreamResponse getStream(Consumer<GetStreamRequest.Builder> getStreamRequest) throws ThrottlingException, AccessDeniedException, InternalServerException, ValidationException, ResourceNotFoundException, AwsServiceException, SdkClientException, KeyspacesStreamsException Returns detailed information about a specific data capture stream for an Amazon Keyspaces table. The information includes the stream's Amazon Resource Name (ARN), creation time, current status, retention period, shard composition, and associated table details. This operation helps you monitor and manage the configuration of your Amazon Keyspaces data streams. 
 This is a convenience which creates an instance of the GetStreamRequest.Builderavoiding the need to create one manually viaGetStreamRequest.builder()- Parameters:
- getStreamRequest- A- Consumerthat will call methods on- GetStreamRequest.Builderto create a request.
- Returns:
- Result of the GetStream operation returned by the service.
- See Also:
 
- 
getStreamPaginatordefault GetStreamIterable getStreamPaginator(GetStreamRequest getStreamRequest) throws ThrottlingException, AccessDeniedException, InternalServerException, ValidationException, ResourceNotFoundException, AwsServiceException, SdkClientException, KeyspacesStreamsException This is a variant of getStream(software.amazon.awssdk.services.keyspacesstreams.model.GetStreamRequest)operation. The return type is a custom iterable that can be used to iterate through all the pages. SDK will internally handle making service calls for you.When this operation is called, a custom iterable is returned but no service calls are made yet. So there is no guarantee that the request is valid. As you iterate through the iterable, SDK will start lazily loading response pages by making service calls until there are no pages left or your iteration stops. If there are errors in your request, you will see the failures only after you start iterating through the iterable. The following are few ways to iterate through the response pages: 1) Using a Stream
 2) Using For loopsoftware.amazon.awssdk.services.keyspacesstreams.paginators.GetStreamIterable responses = client.getStreamPaginator(request); responses.stream().forEach(....);{ @code software.amazon.awssdk.services.keyspacesstreams.paginators.GetStreamIterable responses = client.getStreamPaginator(request); for (software.amazon.awssdk.services.keyspacesstreams.model.GetStreamResponse response : responses) { // do something; } }3) Use iterator directlysoftware.amazon.awssdk.services.keyspacesstreams.paginators.GetStreamIterable responses = client.getStreamPaginator(request); responses.iterator().forEachRemaining(....);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 getStream(software.amazon.awssdk.services.keyspacesstreams.model.GetStreamRequest)operation.- Parameters:
- getStreamRequest-
- Returns:
- A custom iterable that can be used to iterate through all the response pages.
- See Also:
 
- 
getStreamPaginatordefault GetStreamIterable getStreamPaginator(Consumer<GetStreamRequest.Builder> getStreamRequest) throws ThrottlingException, AccessDeniedException, InternalServerException, ValidationException, ResourceNotFoundException, AwsServiceException, SdkClientException, KeyspacesStreamsException This is a variant of getStream(software.amazon.awssdk.services.keyspacesstreams.model.GetStreamRequest)operation. The return type is a custom iterable that can be used to iterate through all the pages. SDK will internally handle making service calls for you.When this operation is called, a custom iterable is returned but no service calls are made yet. So there is no guarantee that the request is valid. As you iterate through the iterable, SDK will start lazily loading response pages by making service calls until there are no pages left or your iteration stops. If there are errors in your request, you will see the failures only after you start iterating through the iterable. The following are few ways to iterate through the response pages: 1) Using a Stream
 2) Using For loopsoftware.amazon.awssdk.services.keyspacesstreams.paginators.GetStreamIterable responses = client.getStreamPaginator(request); responses.stream().forEach(....);{ @code software.amazon.awssdk.services.keyspacesstreams.paginators.GetStreamIterable responses = client.getStreamPaginator(request); for (software.amazon.awssdk.services.keyspacesstreams.model.GetStreamResponse response : responses) { // do something; } }3) Use iterator directlysoftware.amazon.awssdk.services.keyspacesstreams.paginators.GetStreamIterable responses = client.getStreamPaginator(request); responses.iterator().forEachRemaining(....);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 getStream(software.amazon.awssdk.services.keyspacesstreams.model.GetStreamRequest)operation.
 This is a convenience which creates an instance of the GetStreamRequest.Builderavoiding the need to create one manually viaGetStreamRequest.builder()- Parameters:
- getStreamRequest- A- Consumerthat will call methods on- GetStreamRequest.Builderto create a request.
- Returns:
- A custom iterable that can be used to iterate through all the response pages.
- See Also:
 
- 
listStreamsdefault ListStreamsResponse listStreams(ListStreamsRequest listStreamsRequest) throws ThrottlingException, AccessDeniedException, InternalServerException, ValidationException, ResourceNotFoundException, AwsServiceException, SdkClientException, KeyspacesStreamsException Returns a list of all data capture streams associated with your Amazon Keyspaces account or for a specific keyspace or table. The response includes information such as stream ARNs, table associations, creation timestamps, and current status. This operation helps you discover and manage all active data streams in your Amazon Keyspaces environment. - Parameters:
- listStreamsRequest-
- Returns:
- Result of the ListStreams operation returned by the service.
- See Also:
 
- 
listStreamsdefault ListStreamsResponse listStreams(Consumer<ListStreamsRequest.Builder> listStreamsRequest) throws ThrottlingException, AccessDeniedException, InternalServerException, ValidationException, ResourceNotFoundException, AwsServiceException, SdkClientException, KeyspacesStreamsException Returns a list of all data capture streams associated with your Amazon Keyspaces account or for a specific keyspace or table. The response includes information such as stream ARNs, table associations, creation timestamps, and current status. This operation helps you discover and manage all active data streams in your Amazon Keyspaces environment. 
 This is a convenience which creates an instance of the ListStreamsRequest.Builderavoiding the need to create one manually viaListStreamsRequest.builder()- Parameters:
- listStreamsRequest- A- Consumerthat will call methods on- ListStreamsRequest.Builderto create a request.
- Returns:
- Result of the ListStreams operation returned by the service.
- See Also:
 
- 
listStreamsPaginatordefault ListStreamsIterable listStreamsPaginator(ListStreamsRequest listStreamsRequest) throws ThrottlingException, AccessDeniedException, InternalServerException, ValidationException, ResourceNotFoundException, AwsServiceException, SdkClientException, KeyspacesStreamsException This is a variant of listStreams(software.amazon.awssdk.services.keyspacesstreams.model.ListStreamsRequest)operation. The return type is a custom iterable that can be used to iterate through all the pages. SDK will internally handle making service calls for you.When this operation is called, a custom iterable is returned but no service calls are made yet. So there is no guarantee that the request is valid. As you iterate through the iterable, SDK will start lazily loading response pages by making service calls until there are no pages left or your iteration stops. If there are errors in your request, you will see the failures only after you start iterating through the iterable. The following are few ways to iterate through the response pages: 1) Using a Stream
 2) Using For loopsoftware.amazon.awssdk.services.keyspacesstreams.paginators.ListStreamsIterable responses = client.listStreamsPaginator(request); responses.stream().forEach(....);{ @code software.amazon.awssdk.services.keyspacesstreams.paginators.ListStreamsIterable responses = client .listStreamsPaginator(request); for (software.amazon.awssdk.services.keyspacesstreams.model.ListStreamsResponse response : responses) { // do something; } }3) Use iterator directlysoftware.amazon.awssdk.services.keyspacesstreams.paginators.ListStreamsIterable responses = client.listStreamsPaginator(request); responses.iterator().forEachRemaining(....);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 listStreams(software.amazon.awssdk.services.keyspacesstreams.model.ListStreamsRequest)operation.- Parameters:
- listStreamsRequest-
- Returns:
- A custom iterable that can be used to iterate through all the response pages.
- See Also:
 
- 
listStreamsPaginatordefault ListStreamsIterable listStreamsPaginator(Consumer<ListStreamsRequest.Builder> listStreamsRequest) throws ThrottlingException, AccessDeniedException, InternalServerException, ValidationException, ResourceNotFoundException, AwsServiceException, SdkClientException, KeyspacesStreamsException This is a variant of listStreams(software.amazon.awssdk.services.keyspacesstreams.model.ListStreamsRequest)operation. The return type is a custom iterable that can be used to iterate through all the pages. SDK will internally handle making service calls for you.When this operation is called, a custom iterable is returned but no service calls are made yet. So there is no guarantee that the request is valid. As you iterate through the iterable, SDK will start lazily loading response pages by making service calls until there are no pages left or your iteration stops. If there are errors in your request, you will see the failures only after you start iterating through the iterable. The following are few ways to iterate through the response pages: 1) Using a Stream
 2) Using For loopsoftware.amazon.awssdk.services.keyspacesstreams.paginators.ListStreamsIterable responses = client.listStreamsPaginator(request); responses.stream().forEach(....);{ @code software.amazon.awssdk.services.keyspacesstreams.paginators.ListStreamsIterable responses = client .listStreamsPaginator(request); for (software.amazon.awssdk.services.keyspacesstreams.model.ListStreamsResponse response : responses) { // do something; } }3) Use iterator directlysoftware.amazon.awssdk.services.keyspacesstreams.paginators.ListStreamsIterable responses = client.listStreamsPaginator(request); responses.iterator().forEachRemaining(....);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 listStreams(software.amazon.awssdk.services.keyspacesstreams.model.ListStreamsRequest)operation.
 This is a convenience which creates an instance of the ListStreamsRequest.Builderavoiding the need to create one manually viaListStreamsRequest.builder()- Parameters:
- listStreamsRequest- A- Consumerthat will call methods on- ListStreamsRequest.Builderto create a request.
- Returns:
- A custom iterable that can be used to iterate through all the response pages.
- See Also:
 
- 
createCreate aKeyspacesStreamsClientwith the region loaded from theDefaultAwsRegionProviderChainand credentials loaded from theDefaultCredentialsProvider.
- 
builderCreate a builder that can be used to configure and create aKeyspacesStreamsClient.
- 
serviceMetadata
- 
serviceClientConfigurationDescription copied from interface:SdkClientThe SDK service client configuration exposes client settings to the user, e.g., ClientOverrideConfiguration- Specified by:
- serviceClientConfigurationin interface- AwsClient
- Specified by:
- serviceClientConfigurationin interface- SdkClient
- Returns:
- SdkServiceClientConfiguration
 
 
-