Class StreamDescription
- java.lang.Object
-
- software.amazon.awssdk.services.kinesis.model.StreamDescription
-
- All Implemented Interfaces:
Serializable,SdkPojo,ToCopyableBuilder<StreamDescription.Builder,StreamDescription>
@Generated("software.amazon.awssdk:codegen") public final class StreamDescription extends Object implements SdkPojo, Serializable, ToCopyableBuilder<StreamDescription.Builder,StreamDescription>
Represents the output for DescribeStream.
- See Also:
- Serialized Form
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static interfaceStreamDescription.Builder
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static StreamDescription.Builderbuilder()EncryptionTypeencryptionType()The server-side encryption type used on the stream.StringencryptionTypeAsString()The server-side encryption type used on the stream.List<EnhancedMetrics>enhancedMonitoring()Represents the current enhanced monitoring settings of the stream.booleanequals(Object obj)booleanequalsBySdkFields(Object obj)<T> Optional<T>getValueForField(String fieldName, Class<T> clazz)booleanhasEnhancedMonitoring()For responses, this returns true if the service returned a value for the EnhancedMonitoring property.inthashCode()BooleanhasMoreShards()If set totrue, more shards in the stream are available to describe.booleanhasShards()For responses, this returns true if the service returned a value for the Shards property.StringkeyId()The GUID for the customer-managed Amazon Web Services KMS key to use for encryption.IntegerretentionPeriodHours()The current retention period, in hours.Map<String,SdkField<?>>sdkFieldNameToField()List<SdkField<?>>sdkFields()static Class<? extends StreamDescription.Builder>serializableBuilderClass()List<Shard>shards()The shards that comprise the stream.StringstreamARN()The Amazon Resource Name (ARN) for the stream being described.InstantstreamCreationTimestamp()The approximate time that the stream was created.StreamModeDetailsstreamModeDetails()Specifies the capacity mode to which you want to set your data stream.StringstreamName()The name of the stream being described.StreamStatusstreamStatus()The current status of the stream being described.StringstreamStatusAsString()The current status of the stream being described.StreamDescription.BuildertoBuilder()StringtoString()Returns a string representation of this object.-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface software.amazon.awssdk.utils.builder.ToCopyableBuilder
copy
-
-
-
-
Method Detail
-
streamName
public final String streamName()
The name of the stream being described.
- Returns:
- The name of the stream being described.
-
streamARN
public final String streamARN()
The Amazon Resource Name (ARN) for the stream being described.
- Returns:
- The Amazon Resource Name (ARN) for the stream being described.
-
streamStatus
public final StreamStatus streamStatus()
The current status of the stream being described. The stream status is one of the following states:
-
CREATING- The stream is being created. Kinesis Data Streams immediately returns and setsStreamStatustoCREATING. -
DELETING- The stream is being deleted. The specified stream is in theDELETINGstate until Kinesis Data Streams completes the deletion. -
ACTIVE- The stream exists and is ready for read and write operations or deletion. You should perform read and write operations only on anACTIVEstream. -
UPDATING- Shards in the stream are being merged or split. Read and write operations continue to work while the stream is in theUPDATINGstate.
If the service returns an enum value that is not available in the current SDK version,
streamStatuswill returnStreamStatus.UNKNOWN_TO_SDK_VERSION. The raw value returned by the service is available fromstreamStatusAsString().- Returns:
- The current status of the stream being described. The stream status is one of the following states:
-
CREATING- The stream is being created. Kinesis Data Streams immediately returns and setsStreamStatustoCREATING. -
DELETING- The stream is being deleted. The specified stream is in theDELETINGstate until Kinesis Data Streams completes the deletion. -
ACTIVE- The stream exists and is ready for read and write operations or deletion. You should perform read and write operations only on anACTIVEstream. -
UPDATING- Shards in the stream are being merged or split. Read and write operations continue to work while the stream is in theUPDATINGstate.
-
- See Also:
StreamStatus
-
-
streamStatusAsString
public final String streamStatusAsString()
The current status of the stream being described. The stream status is one of the following states:
-
CREATING- The stream is being created. Kinesis Data Streams immediately returns and setsStreamStatustoCREATING. -
DELETING- The stream is being deleted. The specified stream is in theDELETINGstate until Kinesis Data Streams completes the deletion. -
ACTIVE- The stream exists and is ready for read and write operations or deletion. You should perform read and write operations only on anACTIVEstream. -
UPDATING- Shards in the stream are being merged or split. Read and write operations continue to work while the stream is in theUPDATINGstate.
If the service returns an enum value that is not available in the current SDK version,
streamStatuswill returnStreamStatus.UNKNOWN_TO_SDK_VERSION. The raw value returned by the service is available fromstreamStatusAsString().- Returns:
- The current status of the stream being described. The stream status is one of the following states:
-
CREATING- The stream is being created. Kinesis Data Streams immediately returns and setsStreamStatustoCREATING. -
DELETING- The stream is being deleted. The specified stream is in theDELETINGstate until Kinesis Data Streams completes the deletion. -
ACTIVE- The stream exists and is ready for read and write operations or deletion. You should perform read and write operations only on anACTIVEstream. -
UPDATING- Shards in the stream are being merged or split. Read and write operations continue to work while the stream is in theUPDATINGstate.
-
- See Also:
StreamStatus
-
-
streamModeDetails
public final StreamModeDetails streamModeDetails()
Specifies the capacity mode to which you want to set your data stream. Currently, in Kinesis Data Streams, you can choose between an on-demand capacity mode and a provisioned capacity mode for your data streams.
- Returns:
- Specifies the capacity mode to which you want to set your data stream. Currently, in Kinesis Data Streams, you can choose between an on-demand capacity mode and a provisioned capacity mode for your data streams.
-
hasShards
public final boolean hasShards()
For responses, this returns true if the service returned a value for the Shards property. This DOES NOT check that the value is non-empty (for which, you should check theisEmpty()method on the property). This is useful because the SDK will never return a null collection or map, but you may need to differentiate between the service returning nothing (or null) and the service returning an empty collection or map. For requests, this returns true if a value for the property was specified in the request builder, and false if a value was not specified.
-
shards
public final List<Shard> shards()
The shards that comprise the stream.
Attempts to modify the collection returned by this method will result in an UnsupportedOperationException.
This method will never return null. If you would like to know whether the service returned this field (so that you can differentiate between null and empty), you can use the
hasShards()method.- Returns:
- The shards that comprise the stream.
-
hasMoreShards
public final Boolean hasMoreShards()
If set to
true, more shards in the stream are available to describe.- Returns:
- If set to
true, more shards in the stream are available to describe.
-
retentionPeriodHours
public final Integer retentionPeriodHours()
The current retention period, in hours. Minimum value of 24. Maximum value of 168.
- Returns:
- The current retention period, in hours. Minimum value of 24. Maximum value of 168.
-
streamCreationTimestamp
public final Instant streamCreationTimestamp()
The approximate time that the stream was created.
- Returns:
- The approximate time that the stream was created.
-
hasEnhancedMonitoring
public final boolean hasEnhancedMonitoring()
For responses, this returns true if the service returned a value for the EnhancedMonitoring property. This DOES NOT check that the value is non-empty (for which, you should check theisEmpty()method on the property). This is useful because the SDK will never return a null collection or map, but you may need to differentiate between the service returning nothing (or null) and the service returning an empty collection or map. For requests, this returns true if a value for the property was specified in the request builder, and false if a value was not specified.
-
enhancedMonitoring
public final List<EnhancedMetrics> enhancedMonitoring()
Represents the current enhanced monitoring settings of the stream.
Attempts to modify the collection returned by this method will result in an UnsupportedOperationException.
This method will never return null. If you would like to know whether the service returned this field (so that you can differentiate between null and empty), you can use the
hasEnhancedMonitoring()method.- Returns:
- Represents the current enhanced monitoring settings of the stream.
-
encryptionType
public final EncryptionType encryptionType()
The server-side encryption type used on the stream. This parameter can be one of the following values:
-
NONE: Do not encrypt the records in the stream. -
KMS: Use server-side encryption on the records in the stream using a customer-managed Amazon Web Services KMS key.
If the service returns an enum value that is not available in the current SDK version,
encryptionTypewill returnEncryptionType.UNKNOWN_TO_SDK_VERSION. The raw value returned by the service is available fromencryptionTypeAsString().- Returns:
- The server-side encryption type used on the stream. This parameter can be one of the following
values:
-
NONE: Do not encrypt the records in the stream. -
KMS: Use server-side encryption on the records in the stream using a customer-managed Amazon Web Services KMS key.
-
- See Also:
EncryptionType
-
-
encryptionTypeAsString
public final String encryptionTypeAsString()
The server-side encryption type used on the stream. This parameter can be one of the following values:
-
NONE: Do not encrypt the records in the stream. -
KMS: Use server-side encryption on the records in the stream using a customer-managed Amazon Web Services KMS key.
If the service returns an enum value that is not available in the current SDK version,
encryptionTypewill returnEncryptionType.UNKNOWN_TO_SDK_VERSION. The raw value returned by the service is available fromencryptionTypeAsString().- Returns:
- The server-side encryption type used on the stream. This parameter can be one of the following
values:
-
NONE: Do not encrypt the records in the stream. -
KMS: Use server-side encryption on the records in the stream using a customer-managed Amazon Web Services KMS key.
-
- See Also:
EncryptionType
-
-
keyId
public final String keyId()
The GUID for the customer-managed Amazon Web Services KMS key to use for encryption. This value can be a globally unique identifier, a fully specified ARN to either an alias or a key, or an alias name prefixed by "alias/".You can also use a master key owned by Kinesis Data Streams by specifying the alias
aws/kinesis.-
Key ARN example:
arn:aws:kms:us-east-1:123456789012:key/12345678-1234-1234-1234-123456789012 -
Alias ARN example:
arn:aws:kms:us-east-1:123456789012:alias/MyAliasName -
Globally unique key ID example:
12345678-1234-1234-1234-123456789012 -
Alias name example:
alias/MyAliasName -
Master key owned by Kinesis Data Streams:
alias/aws/kinesis
- Returns:
- The GUID for the customer-managed Amazon Web Services KMS key to use for encryption. This value can be a
globally unique identifier, a fully specified ARN to either an alias or a key, or an alias name prefixed
by "alias/".You can also use a master key owned by Kinesis Data Streams by specifying the alias
aws/kinesis.-
Key ARN example:
arn:aws:kms:us-east-1:123456789012:key/12345678-1234-1234-1234-123456789012 -
Alias ARN example:
arn:aws:kms:us-east-1:123456789012:alias/MyAliasName -
Globally unique key ID example:
12345678-1234-1234-1234-123456789012 -
Alias name example:
alias/MyAliasName -
Master key owned by Kinesis Data Streams:
alias/aws/kinesis
-
-
-
toBuilder
public StreamDescription.Builder toBuilder()
- Specified by:
toBuilderin interfaceToCopyableBuilder<StreamDescription.Builder,StreamDescription>
-
builder
public static StreamDescription.Builder builder()
-
serializableBuilderClass
public static Class<? extends StreamDescription.Builder> serializableBuilderClass()
-
equalsBySdkFields
public final boolean equalsBySdkFields(Object obj)
- Specified by:
equalsBySdkFieldsin interfaceSdkPojo
-
toString
public final String toString()
Returns a string representation of this object. This is useful for testing and debugging. Sensitive data will be redacted from this string using a placeholder value.
-
sdkFieldNameToField
public final Map<String,SdkField<?>> sdkFieldNameToField()
- Specified by:
sdkFieldNameToFieldin interfaceSdkPojo
-
-