Class CfnMetricFilterProps.Builder
java.lang.Object
software.amazon.awscdk.services.logs.CfnMetricFilterProps.Builder
- All Implemented Interfaces:
software.amazon.jsii.Builder<CfnMetricFilterProps>
- Enclosing interface:
CfnMetricFilterProps
@Stability(Stable)
public static final class CfnMetricFilterProps.Builder
extends Object
implements software.amazon.jsii.Builder<CfnMetricFilterProps>
A builder for
CfnMetricFilterProps-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionapplyOnTransformedLogs(Boolean applyOnTransformedLogs) Sets the value ofCfnMetricFilterProps.getApplyOnTransformedLogs()applyOnTransformedLogs(IResolvable applyOnTransformedLogs) Sets the value ofCfnMetricFilterProps.getApplyOnTransformedLogs()build()Builds the configured instance.filterName(String filterName) Sets the value ofCfnMetricFilterProps.getFilterName()filterPattern(String filterPattern) Sets the value ofCfnMetricFilterProps.getFilterPattern()logGroupName(String logGroupName) Sets the value ofCfnMetricFilterProps.getLogGroupName()metricTransformations(List<? extends Object> metricTransformations) Sets the value ofCfnMetricFilterProps.getMetricTransformations()metricTransformations(IResolvable metricTransformations) Sets the value ofCfnMetricFilterProps.getMetricTransformations()
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
filterPattern
Sets the value ofCfnMetricFilterProps.getFilterPattern()- Parameters:
filterPattern- A filter pattern for extracting metric data out of ingested log events. This parameter is required. For more information, see Filter and Pattern Syntax .- Returns:
this
-
logGroupName
Sets the value ofCfnMetricFilterProps.getLogGroupName()- Parameters:
logGroupName- The name of an existing log group that you want to associate with this metric filter. This parameter is required.- Returns:
this
-
metricTransformations
@Stability(Stable) public CfnMetricFilterProps.Builder metricTransformations(IResolvable metricTransformations) Sets the value ofCfnMetricFilterProps.getMetricTransformations()- Parameters:
metricTransformations- The metric transformations. This parameter is required.- Returns:
this
-
metricTransformations
@Stability(Stable) public CfnMetricFilterProps.Builder metricTransformations(List<? extends Object> metricTransformations) Sets the value ofCfnMetricFilterProps.getMetricTransformations()- Parameters:
metricTransformations- The metric transformations. This parameter is required.- Returns:
this
-
applyOnTransformedLogs
@Stability(Stable) public CfnMetricFilterProps.Builder applyOnTransformedLogs(Boolean applyOnTransformedLogs) Sets the value ofCfnMetricFilterProps.getApplyOnTransformedLogs()- Parameters:
applyOnTransformedLogs- This parameter is valid only for log groups that have an active log transformer. For more information about log transformers, see PutTransformer .If this value is
true, the metric filter is applied on the transformed version of the log events instead of the original ingested log events.- Returns:
this
-
applyOnTransformedLogs
@Stability(Stable) public CfnMetricFilterProps.Builder applyOnTransformedLogs(IResolvable applyOnTransformedLogs) Sets the value ofCfnMetricFilterProps.getApplyOnTransformedLogs()- Parameters:
applyOnTransformedLogs- This parameter is valid only for log groups that have an active log transformer. For more information about log transformers, see PutTransformer .If this value is
true, the metric filter is applied on the transformed version of the log events instead of the original ingested log events.- Returns:
this
-
filterName
Sets the value ofCfnMetricFilterProps.getFilterName()- Parameters:
filterName- The name of the metric filter.- Returns:
this
-
build
Builds the configured instance.- Specified by:
buildin interfacesoftware.amazon.jsii.Builder<CfnMetricFilterProps>- Returns:
- a new instance of
CfnMetricFilterProps - Throws:
NullPointerException- if any required attribute was not provided
-