public class MetricTransformation
extends java.lang.Object
implements java.io.Serializable
Indicates how to transform ingested log events in to metric data in a CloudWatch metric.
| Constructor and Description |
|---|
MetricTransformation() |
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(java.lang.Object obj) |
java.lang.Double |
getDefaultValue()
(Optional) The value to emit when a filter pattern does not match a log
event.
|
java.lang.String |
getMetricName()
The name of the CloudWatch metric.
|
java.lang.String |
getMetricNamespace()
The namespace of the CloudWatch metric.
|
java.lang.String |
getMetricValue()
The value to publish to the CloudWatch metric when a filter pattern
matches a log event.
|
int |
hashCode() |
void |
setDefaultValue(java.lang.Double defaultValue)
(Optional) The value to emit when a filter pattern does not match a log
event.
|
void |
setMetricName(java.lang.String metricName)
The name of the CloudWatch metric.
|
void |
setMetricNamespace(java.lang.String metricNamespace)
The namespace of the CloudWatch metric.
|
void |
setMetricValue(java.lang.String metricValue)
The value to publish to the CloudWatch metric when a filter pattern
matches a log event.
|
java.lang.String |
toString()
Returns a string representation of this object; useful for testing and
debugging.
|
MetricTransformation |
withDefaultValue(java.lang.Double defaultValue)
(Optional) The value to emit when a filter pattern does not match a log
event.
|
MetricTransformation |
withMetricName(java.lang.String metricName)
The name of the CloudWatch metric.
|
MetricTransformation |
withMetricNamespace(java.lang.String metricNamespace)
The namespace of the CloudWatch metric.
|
MetricTransformation |
withMetricValue(java.lang.String metricValue)
The value to publish to the CloudWatch metric when a filter pattern
matches a log event.
|
public java.lang.String getMetricName()
The name of the CloudWatch metric.
Constraints:
Length: - 255
Pattern: [^:*$]*
The name of the CloudWatch metric.
public void setMetricName(java.lang.String metricName)
The name of the CloudWatch metric.
Constraints:
Length: - 255
Pattern: [^:*$]*
metricName - The name of the CloudWatch metric.
public MetricTransformation withMetricName(java.lang.String metricName)
The name of the CloudWatch metric.
Returns a reference to this object so that method calls can be chained together.
Constraints:
Length: - 255
Pattern: [^:*$]*
metricName - The name of the CloudWatch metric.
public java.lang.String getMetricNamespace()
The namespace of the CloudWatch metric.
Constraints:
Length: - 255
Pattern: [^:*$]*
The namespace of the CloudWatch metric.
public void setMetricNamespace(java.lang.String metricNamespace)
The namespace of the CloudWatch metric.
Constraints:
Length: - 255
Pattern: [^:*$]*
metricNamespace - The namespace of the CloudWatch metric.
public MetricTransformation withMetricNamespace(java.lang.String metricNamespace)
The namespace of the CloudWatch metric.
Returns a reference to this object so that method calls can be chained together.
Constraints:
Length: - 255
Pattern: [^:*$]*
metricNamespace - The namespace of the CloudWatch metric.
public java.lang.String getMetricValue()
The value to publish to the CloudWatch metric when a filter pattern matches a log event.
Constraints:
Length: - 100
The value to publish to the CloudWatch metric when a filter pattern matches a log event.
public void setMetricValue(java.lang.String metricValue)
The value to publish to the CloudWatch metric when a filter pattern matches a log event.
Constraints:
Length: - 100
metricValue - The value to publish to the CloudWatch metric when a filter pattern matches a log event.
public MetricTransformation withMetricValue(java.lang.String metricValue)
The value to publish to the CloudWatch metric when a filter pattern matches a log event.
Returns a reference to this object so that method calls can be chained together.
Constraints:
Length: - 100
metricValue - The value to publish to the CloudWatch metric when a filter pattern matches a log event.
public java.lang.Double getDefaultValue()
(Optional) The value to emit when a filter pattern does not match a log event. This value can be null.
(Optional) The value to emit when a filter pattern does not match a log event. This value can be null.
public void setDefaultValue(java.lang.Double defaultValue)
(Optional) The value to emit when a filter pattern does not match a log event. This value can be null.
defaultValue - (Optional) The value to emit when a filter pattern does not match a log event. This value can be null.
public MetricTransformation withDefaultValue(java.lang.Double defaultValue)
(Optional) The value to emit when a filter pattern does not match a log event. This value can be null.
Returns a reference to this object so that method calls can be chained together.
defaultValue - (Optional) The value to emit when a filter pattern does not match a log event. This value can be null.
public java.lang.String toString()
toString in class java.lang.ObjectObject.toString()public int hashCode()
hashCode in class java.lang.Objectpublic boolean equals(java.lang.Object obj)
equals in class java.lang.ObjectCopyright © 2018 Amazon Web Services, Inc. All Rights Reserved.