Show / Hide Table of Contents

Interface ILogStreamProps

Properties for a LogStream.

Namespace: Amazon.CDK.AWS.Logs
Assembly: Amazon.CDK.Lib.dll
Syntax (csharp)
public interface ILogStreamProps
Syntax (vb)
Public Interface ILogStreamProps
Remarks

ExampleMetadata: fixture=_generated

Examples
// The code below shows an example of how to instantiate this type.
            // The values are placeholders you should change.
            using Amazon.CDK;
            using Amazon.CDK.AWS.Logs;

            LogGroup logGroup;

            var logStreamProps = new LogStreamProps {
                LogGroup = logGroup,

                // the properties below are optional
                LogStreamName = "logStreamName",
                RemovalPolicy = RemovalPolicy.DESTROY
            };

Synopsis

Properties

LogGroup

The log group to create a log stream for.

LogStreamName

The name of the log stream to create.

RemovalPolicy

Determine what happens when the log stream resource is removed from the app.

Properties

LogGroup

The log group to create a log stream for.

ILogGroup LogGroup { get; }
Property Value

ILogGroup

Remarks

ExampleMetadata: fixture=_generated

LogStreamName

The name of the log stream to create.

string? LogStreamName { get; }
Property Value

string

Remarks

The name must be unique within the log group.

Default: Automatically generated

RemovalPolicy

Determine what happens when the log stream resource is removed from the app.

RemovalPolicy? RemovalPolicy { get; }
Property Value

RemovalPolicy?

Remarks

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

Back to top Generated by DocFX