public class MetricFilter
extends java.lang.Object
implements java.io.Serializable
Metric filters express how CloudWatch Logs would extract metric observations from ingested log events and transform them into metric data in a CloudWatch metric.
Constructor and Description |
---|
MetricFilter() |
Modifier and Type | Method and Description |
---|---|
boolean |
equals(java.lang.Object obj) |
java.lang.Long |
getCreationTime()
The creation time of the metric filter, expressed as the number of
milliseconds after Jan 1, 1970 00:00:00 UTC.
|
java.lang.String |
getFilterName()
The name of the metric filter.
|
java.lang.String |
getFilterPattern()
A symbolic description of how CloudWatch Logs should interpret the data
in each log event.
|
java.lang.String |
getLogGroupName()
The name of the log group.
|
java.util.List<MetricTransformation> |
getMetricTransformations()
The metric transformations.
|
int |
hashCode() |
void |
setCreationTime(java.lang.Long creationTime)
The creation time of the metric filter, expressed as the number of
milliseconds after Jan 1, 1970 00:00:00 UTC.
|
void |
setFilterName(java.lang.String filterName)
The name of the metric filter.
|
void |
setFilterPattern(java.lang.String filterPattern)
A symbolic description of how CloudWatch Logs should interpret the data
in each log event.
|
void |
setLogGroupName(java.lang.String logGroupName)
The name of the log group.
|
void |
setMetricTransformations(java.util.Collection<MetricTransformation> metricTransformations)
The metric transformations.
|
java.lang.String |
toString()
Returns a string representation of this object; useful for testing and
debugging.
|
MetricFilter |
withCreationTime(java.lang.Long creationTime)
The creation time of the metric filter, expressed as the number of
milliseconds after Jan 1, 1970 00:00:00 UTC.
|
MetricFilter |
withFilterName(java.lang.String filterName)
The name of the metric filter.
|
MetricFilter |
withFilterPattern(java.lang.String filterPattern)
A symbolic description of how CloudWatch Logs should interpret the data
in each log event.
|
MetricFilter |
withLogGroupName(java.lang.String logGroupName)
The name of the log group.
|
MetricFilter |
withMetricTransformations(java.util.Collection<MetricTransformation> metricTransformations)
The metric transformations.
|
MetricFilter |
withMetricTransformations(MetricTransformation... metricTransformations)
The metric transformations.
|
public java.lang.String getFilterName()
The name of the metric filter.
Constraints:
Length: 1 - 512
Pattern: [^:*]*
The name of the metric filter.
public void setFilterName(java.lang.String filterName)
The name of the metric filter.
Constraints:
Length: 1 - 512
Pattern: [^:*]*
filterName
- The name of the metric filter.
public MetricFilter withFilterName(java.lang.String filterName)
The name of the metric filter.
Returns a reference to this object so that method calls can be chained together.
Constraints:
Length: 1 - 512
Pattern: [^:*]*
filterName
- The name of the metric filter.
public java.lang.String getFilterPattern()
A symbolic description of how CloudWatch Logs should interpret the data in each log event. For example, a log event may contain time stamps, IP addresses, strings, and so on. You use the filter pattern to specify what to look for in the log event message.
Constraints:
Length: 0 - 1024
A symbolic description of how CloudWatch Logs should interpret the data in each log event. For example, a log event may contain time stamps, IP addresses, strings, and so on. You use the filter pattern to specify what to look for in the log event message.
public void setFilterPattern(java.lang.String filterPattern)
A symbolic description of how CloudWatch Logs should interpret the data in each log event. For example, a log event may contain time stamps, IP addresses, strings, and so on. You use the filter pattern to specify what to look for in the log event message.
Constraints:
Length: 0 - 1024
filterPattern
- A symbolic description of how CloudWatch Logs should interpret the data in each log event. For example, a log event may contain time stamps, IP addresses, strings, and so on. You use the filter pattern to specify what to look for in the log event message.
public MetricFilter withFilterPattern(java.lang.String filterPattern)
A symbolic description of how CloudWatch Logs should interpret the data in each log event. For example, a log event may contain time stamps, IP addresses, strings, and so on. You use the filter pattern to specify what to look for in the log event message.
Returns a reference to this object so that method calls can be chained together.
Constraints:
Length: 0 - 1024
filterPattern
- A symbolic description of how CloudWatch Logs should interpret the data in each log event. For example, a log event may contain time stamps, IP addresses, strings, and so on. You use the filter pattern to specify what to look for in the log event message.
public java.util.List<MetricTransformation> getMetricTransformations()
The metric transformations.
The metric transformations.
public void setMetricTransformations(java.util.Collection<MetricTransformation> metricTransformations)
The metric transformations.
metricTransformations
- The metric transformations.
public MetricFilter withMetricTransformations(MetricTransformation... metricTransformations)
The metric transformations.
Returns a reference to this object so that method calls can be chained together.
metricTransformations
- The metric transformations.
public MetricFilter withMetricTransformations(java.util.Collection<MetricTransformation> metricTransformations)
The metric transformations.
Returns a reference to this object so that method calls can be chained together.
metricTransformations
- The metric transformations.
public java.lang.Long getCreationTime()
The creation time of the metric filter, expressed as the number of milliseconds after Jan 1, 1970 00:00:00 UTC.
Constraints:
Range: 0 -
The creation time of the metric filter, expressed as the number of milliseconds after Jan 1, 1970 00:00:00 UTC.
public void setCreationTime(java.lang.Long creationTime)
The creation time of the metric filter, expressed as the number of milliseconds after Jan 1, 1970 00:00:00 UTC.
Constraints:
Range: 0 -
creationTime
- The creation time of the metric filter, expressed as the number of milliseconds after Jan 1, 1970 00:00:00 UTC.
public MetricFilter withCreationTime(java.lang.Long creationTime)
The creation time of the metric filter, expressed as the number of milliseconds after Jan 1, 1970 00:00:00 UTC.
Returns a reference to this object so that method calls can be chained together.
Constraints:
Range: 0 -
creationTime
- The creation time of the metric filter, expressed as the number of milliseconds after Jan 1, 1970 00:00:00 UTC.
public java.lang.String getLogGroupName()
The name of the log group.
Constraints:
Length: 1 - 512
Pattern: [\.\-_/#A-Za-z0-9]+
The name of the log group.
public void setLogGroupName(java.lang.String logGroupName)
The name of the log group.
Constraints:
Length: 1 - 512
Pattern: [\.\-_/#A-Za-z0-9]+
logGroupName
- The name of the log group.
public MetricFilter withLogGroupName(java.lang.String logGroupName)
The name of the log group.
Returns a reference to this object so that method calls can be chained together.
Constraints:
Length: 1 - 512
Pattern: [\.\-_/#A-Za-z0-9]+
logGroupName
- The name of the log group.
public java.lang.String toString()
toString
in class java.lang.Object
Object.toString()
public int hashCode()
hashCode
in class java.lang.Object
public boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
Copyright © 2018 Amazon Web Services, Inc. All Rights Reserved.