Interface LogStreamProps
- All Superinterfaces:
software.amazon.jsii.JsiiSerializable
- All Known Implementing Classes:
LogStreamProps.Jsii$Proxy
@Generated(value="jsii-pacmak/1.120.0 (build 192dc88)",
date="2025-12-05T10:47:24.079Z")
@Stability(Stable)
public interface LogStreamProps
extends software.amazon.jsii.JsiiSerializable
Properties for a LogStream.
Example:
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.*;
import software.amazon.awscdk.services.logs.*;
LogGroup logGroup;
LogStreamProps logStreamProps = LogStreamProps.builder()
.logGroup(logGroup)
// the properties below are optional
.logStreamName("logStreamName")
.removalPolicy(RemovalPolicy.DESTROY)
.build();
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic final classA builder forLogStreamPropsstatic final classAn implementation forLogStreamProps -
Method Summary
Modifier and TypeMethodDescriptionstatic LogStreamProps.Builderbuilder()The log group to create a log stream for.default StringThe name of the log stream to create.default RemovalPolicyDetermine what happens when the log stream resource is removed from the app.Methods inherited from interface software.amazon.jsii.JsiiSerializable
$jsii$toJson
-
Method Details
-
getLogGroup
The log group to create a log stream for. -
getLogStreamName
The name of the log stream to create.The name must be unique within the log group.
Default: Automatically generated
-
getRemovalPolicy
Determine what happens when the log stream resource is removed from the app.Normally you want to retain the log stream so you can diagnose issues from logs even after a deployment that no longer includes the log stream.
The date-based retention policy of your log group will age out the logs after a certain time.
Default: RemovalPolicy.Retain
-
builder
- Returns:
- a
LogStreamProps.BuilderofLogStreamProps
-