Interface CfnMetricFilterProps

All Superinterfaces:
software.amazon.jsii.JsiiSerializable
All Known Implementing Classes:
CfnMetricFilterProps.Jsii$Proxy

@Generated(value="jsii-pacmak/1.84.0 (build 5404dcf)", date="2023-06-19T16:30:38.085Z") @Stability(Stable) public interface CfnMetricFilterProps extends software.amazon.jsii.JsiiSerializable
Properties for defining a CfnMetricFilter.

Example:

 // The code below shows an example of how to instantiate this type.
 // The values are placeholders you should change.
 import software.amazon.awscdk.services.logs.*;
 CfnMetricFilterProps cfnMetricFilterProps = CfnMetricFilterProps.builder()
         .filterPattern("filterPattern")
         .logGroupName("logGroupName")
         .metricTransformations(List.of(MetricTransformationProperty.builder()
                 .metricName("metricName")
                 .metricNamespace("metricNamespace")
                 .metricValue("metricValue")
                 // the properties below are optional
                 .defaultValue(123)
                 .dimensions(List.of(DimensionProperty.builder()
                         .key("key")
                         .value("value")
                         .build()))
                 .unit("unit")
                 .build()))
         // the properties below are optional
         .filterName("filterName")
         .build();
 
  • Method Details

    • getFilterPattern

      @Stability(Stable) @NotNull String getFilterPattern()
      A filter pattern for extracting metric data out of ingested log events.

      For more information, see Filter and Pattern Syntax .

    • getLogGroupName

      @Stability(Stable) @NotNull String getLogGroupName()
      The name of an existing log group that you want to associate with this metric filter.
    • getMetricTransformations

      @Stability(Stable) @NotNull Object getMetricTransformations()
      The metric transformations.
    • getFilterName

      @Stability(Stable) @Nullable default String getFilterName()
      The name of the metric filter.
    • builder

      @Stability(Stable) static CfnMetricFilterProps.Builder builder()
      Returns:
      a CfnMetricFilterProps.Builder of CfnMetricFilterProps