Class StreamProps
Properties for a Kinesis Stream.
Inheritance
Implements
Namespace: Amazon.CDK.AWS.Kinesis
Assembly: Amazon.CDK.Lib.dll
Syntax (csharp)
public class StreamProps : Object, IStreamProps
Syntax (vb)
Public Class StreamProps
Inherits Object
Implements IStreamProps
Remarks
ExampleMetadata: infused
Examples
var key = new Key(this, "MyKey");
new Stream(this, "MyEncryptedStream", new StreamProps {
Encryption = StreamEncryption.KMS,
EncryptionKey = key
});
Synopsis
Constructors
StreamProps() |
Properties
Encryption | The kind of server-side encryption to apply to this stream. |
EncryptionKey | External KMS key to use for stream encryption. |
RemovalPolicy | Policy to apply when the stream is removed from the stack. |
RetentionPeriod | The number of hours for the data records that are stored in shards to remain accessible. |
ShardCount | The number of shards for the stream. |
StreamMode | The capacity mode of this stream. |
StreamName |
Constructors
StreamProps()
public StreamProps()
Properties
Encryption
The kind of server-side encryption to apply to this stream.
public Nullable<StreamEncryption> Encryption { get; set; }
Property Value
System.Nullable<StreamEncryption>
Remarks
If you choose KMS, you can specify a KMS key via encryptionKey
. If
encryption key is not specified, a key will automatically be created.
Default: - StreamEncryption.KMS if encrypted Streams are supported in the region or StreamEncryption.UNENCRYPTED otherwise. StreamEncryption.KMS if an encryption key is supplied through the encryptionKey property
EncryptionKey
External KMS key to use for stream encryption.
public IKey EncryptionKey { get; set; }
Property Value
Remarks
The 'encryption' property must be set to "Kms".
Default: - Kinesis Data Streams master key ('/alias/aws/kinesis'). If encryption is set to StreamEncryption.KMS and this property is undefined, a new KMS key will be created and associated with this stream.
RemovalPolicy
Policy to apply when the stream is removed from the stack.
public Nullable<RemovalPolicy> RemovalPolicy { get; set; }
Property Value
System.Nullable<RemovalPolicy>
Remarks
Default: RemovalPolicy.RETAIN
RetentionPeriod
The number of hours for the data records that are stored in shards to remain accessible.
public Duration RetentionPeriod { get; set; }
Property Value
Remarks
Default: Duration.hours(24)
ShardCount
The number of shards for the stream.
public Nullable<double> ShardCount { get; set; }
Property Value
System.Nullable<System.Double>
Remarks
Can only be provided if streamMode is Provisioned.
Default: 1
StreamMode
The capacity mode of this stream.
public Nullable<StreamMode> StreamMode { get; set; }
Property Value
System.Nullable<StreamMode>
Remarks
Default: StreamMode.PROVISIONED
StreamName
public string StreamName { get; set; }
Property Value
System.String