@Generated(value="jsii-pacmak/1.74.0 (build 6d08790)",
date="2023-03-14T16:25:27.629Z")
public interface MetricFilterOptions
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.*; IFilterPattern filterPattern; MetricFilterOptions metricFilterOptions = MetricFilterOptions.builder() .filterPattern(filterPattern) .metricName("metricName") .metricNamespace("metricNamespace") // the properties below are optional .defaultValue(123) .metricValue("metricValue") .build();
Modifier and Type | Interface and Description |
---|---|
static class |
MetricFilterOptions.Builder
A builder for
MetricFilterOptions |
static class |
MetricFilterOptions.Jsii$Proxy
An implementation for
MetricFilterOptions |
Modifier and Type | Method and Description |
---|---|
static MetricFilterOptions.Builder |
builder() |
default java.lang.Number |
getDefaultValue()
The value to emit if the pattern does not match a particular event.
|
IFilterPattern |
getFilterPattern()
Pattern to search for log events.
|
java.lang.String |
getMetricName()
The name of the metric to emit.
|
java.lang.String |
getMetricNamespace()
The namespace of the metric to emit.
|
default java.lang.String |
getMetricValue()
The value to emit for the metric.
|
IFilterPattern getFilterPattern()
java.lang.String getMetricName()
java.lang.String getMetricNamespace()
default java.lang.Number getDefaultValue()
Default: No metric emitted.
default java.lang.String getMetricValue()
Can either be a literal number (typically "1"), or the name of a field in the structure to take the value from the matched event. If you are using a field value, the field value must have been matched using the pattern.
If you want to specify a field from a matched JSON structure, use '$.fieldName', and make sure the field is in the pattern (if only as '$.fieldName = *').
If you want to specify a field from a matched space-delimited structure, use '$fieldName'.
Default: "1"
static MetricFilterOptions.Builder builder()
MetricFilterOptions.Builder
of MetricFilterOptions