Amazon Kinesis Construct Library
This is a developer preview (public beta) module. Releases might lack important features and might have
future breaking changes.
This API is still under active development and subject to non-backward
compatible changes or removal in any future version. Use of the API is not recommended in production
environments. Experimental APIs are not subject to the Semantic Versioning model.
Define an unencrypted Kinesis stream.
new Stream(this, 'MyFirstStream');
Encryption
Define a KMS-encrypted stream:
const stream = newStream(this, 'MyEncryptedStream', {
encryption: StreamEncryption.Kms
});
assert(stream.encryptionKey instanceof kms.Key);
You can also supply your own key:
const myKmsKey = new kms.Key(this, 'MyKey');
const stream = new Stream(this, 'MyEncryptedStream', {
encryption: StreamEncryption.Kms,
encryptionKey: myKmsKey
});
assert(stream.encryptionKey === myKmsKey);