Distribution Enum
The method used to distribute log data to the destination.
Example
ts
import * as destinations from 'aws-cdk-lib/aws-logs-destinations';
import * as kinesis from 'aws-cdk-lib/aws-kinesis';
declare const stream: kinesis.Stream;
declare const logGroup: logs.LogGroup;
new logs.SubscriptionFilter(this, 'Subscription', {
logGroup,
destination: new destinations.KinesisDestination(stream),
filterPattern: logs.FilterPattern.allTerms("ERROR", "MainThread"),
filterName: 'ErrorInMainThread',
distribution: logs.Distribution.RANDOM,
});
Members
| Member | Description |
|---|---|
BY_LOG_STREAM | Log events from the same log stream are kept together and sent to the same destination. |
RANDOM | Log events are distributed across the log destinations randomly. |
Referenced by
SubscriptionFilterOptions.distributiondistributiondistributionDistributionDistribution