Class CfnSubscriptionFilterProps.Builder
java.lang.Object
software.amazon.awscdk.services.logs.CfnSubscriptionFilterProps.Builder
- All Implemented Interfaces:
software.amazon.jsii.Builder<CfnSubscriptionFilterProps>
- Enclosing interface:
CfnSubscriptionFilterProps
@Stability(Stable)
public static final class CfnSubscriptionFilterProps.Builder
extends Object
implements software.amazon.jsii.Builder<CfnSubscriptionFilterProps>
A builder for
CfnSubscriptionFilterProps-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbuild()Builds the configured instance.destinationArn(String destinationArn) Sets the value ofCfnSubscriptionFilterProps.getDestinationArn()distribution(String distribution) Sets the value ofCfnSubscriptionFilterProps.getDistribution()filterName(String filterName) Sets the value ofCfnSubscriptionFilterProps.getFilterName()filterPattern(String filterPattern) Sets the value ofCfnSubscriptionFilterProps.getFilterPattern()logGroupName(String logGroupName) Sets the value ofCfnSubscriptionFilterProps.getLogGroupName()Sets the value ofCfnSubscriptionFilterProps.getRoleArn()
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
destinationArn
Sets the value ofCfnSubscriptionFilterProps.getDestinationArn()- Parameters:
destinationArn- The Amazon Resource Name (ARN) of the destination. This parameter is required.- Returns:
this
-
filterPattern
Sets the value ofCfnSubscriptionFilterProps.getFilterPattern()- Parameters:
filterPattern- The filtering expressions that restrict what gets delivered to the destination AWS resource. This parameter is required. For more information about the filter pattern syntax, see Filter and Pattern Syntax .- Returns:
this
-
logGroupName
Sets the value ofCfnSubscriptionFilterProps.getLogGroupName()- Parameters:
logGroupName- The log group to associate with the subscription filter. This parameter is required. All log events that are uploaded to this log group are filtered and delivered to the specified AWS resource if the filter pattern matches the log events.- Returns:
this
-
distribution
Sets the value ofCfnSubscriptionFilterProps.getDistribution()- Parameters:
distribution- The method used to distribute log data to the destination, which can be either random or grouped by log stream.- Returns:
this
-
filterName
Sets the value ofCfnSubscriptionFilterProps.getFilterName()- Parameters:
filterName- The name of the subscription filter.- Returns:
this
-
roleArn
Sets the value ofCfnSubscriptionFilterProps.getRoleArn()- Parameters:
roleArn- The ARN of an IAM role that grants CloudWatch Logs permissions to deliver ingested log events to the destination stream. You don't need to provide the ARN when you are working with a logical destination for cross-account delivery.- Returns:
this
-
build
Builds the configured instance.- Specified by:
buildin interfacesoftware.amazon.jsii.Builder<CfnSubscriptionFilterProps>- Returns:
- a new instance of
CfnSubscriptionFilterProps - Throws:
NullPointerException- if any required attribute was not provided
-