public static final class AlertPolicy.Condition extends GeneratedMessageV3 implements AlertPolicy.ConditionOrBuilder
A condition is a true/false test that determines when an alerting policy should open an incident. If a condition evaluates to true, it signifies that something is wrong.Protobuf type
google.monitoring.v3.AlertPolicy.Condition
Modifier and Type | Class and Description |
---|---|
static class |
AlertPolicy.Condition.Builder
A condition is a true/false test that determines when an alerting policy
should open an incident.
|
static class |
AlertPolicy.Condition.ConditionCase |
static class |
AlertPolicy.Condition.MetricAbsence
A condition type that checks that monitored resources
are reporting data.
|
static interface |
AlertPolicy.Condition.MetricAbsenceOrBuilder |
static class |
AlertPolicy.Condition.MetricThreshold
A condition type that compares a collection of time series
against a threshold.
|
static interface |
AlertPolicy.Condition.MetricThresholdOrBuilder |
static class |
AlertPolicy.Condition.Trigger
Specifies how many time series must fail a predicate to trigger a
condition.
|
static interface |
AlertPolicy.Condition.TriggerOrBuilder |
GeneratedMessageV3.BuilderParent, GeneratedMessageV3.ExtendableBuilder<MessageType extends GeneratedMessageV3.ExtendableMessage,BuilderType extends GeneratedMessageV3.ExtendableBuilder<MessageType,BuilderType>>, GeneratedMessageV3.ExtendableMessage<MessageType extends GeneratedMessageV3.ExtendableMessage>, GeneratedMessageV3.ExtendableMessageOrBuilder<MessageType extends GeneratedMessageV3.ExtendableMessage>, GeneratedMessageV3.FieldAccessorTable
Modifier and Type | Field and Description |
---|---|
static int |
CONDITION_ABSENT_FIELD_NUMBER |
static int |
CONDITION_THRESHOLD_FIELD_NUMBER |
static int |
DISPLAY_NAME_FIELD_NUMBER |
static int |
NAME_FIELD_NUMBER |
alwaysUseFieldBuilders, unknownFields
memoizedSize
memoizedHashCode
canUseUnsafe, computeStringSize, computeStringSizeNoTag, getAllFields, getDescriptorForType, getField, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, hasField, hasOneof, internalGetMapField, makeExtensionsImmutable, newBuilderForType, parseDelimitedWithIOException, parseDelimitedWithIOException, parseUnknownField, parseUnknownFieldProto3, parseWithIOException, parseWithIOException, parseWithIOException, parseWithIOException, serializeBooleanMapTo, serializeIntegerMapTo, serializeLongMapTo, serializeStringMapTo, writeReplace, writeString, writeStringNoTag
findInitializationErrors, getInitializationErrorString, hashBoolean, hashEnum, hashEnumList, hashFields, hashLong, toString
addAll, addAll, checkByteStringIsUtf8, toByteArray, toByteString, writeDelimitedTo, writeTo
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
findInitializationErrors, getAllFields, getDescriptorForType, getField, getInitializationErrorString, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, hasField, hasOneof
toByteArray, toByteString, writeDelimitedTo, writeTo
public static final int NAME_FIELD_NUMBER
public static final int DISPLAY_NAME_FIELD_NUMBER
public static final int CONDITION_THRESHOLD_FIELD_NUMBER
public static final int CONDITION_ABSENT_FIELD_NUMBER
public final UnknownFieldSet getUnknownFields()
getUnknownFields
in interface MessageOrBuilder
getUnknownFields
in class GeneratedMessageV3
public static final Descriptors.Descriptor getDescriptor()
protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
internalGetFieldAccessorTable
in class GeneratedMessageV3
public AlertPolicy.Condition.ConditionCase getConditionCase()
getConditionCase
in interface AlertPolicy.ConditionOrBuilder
public java.lang.String getName()
Required if the condition exists. The unique resource name for this condition. Its syntax is: projects/[PROJECT_ID]/alertPolicies/[POLICY_ID]/conditions/[CONDITION_ID] `[CONDITION_ID]` is assigned by Stackdriver Monitoring when the condition is created as part of a new or updated alerting policy. When calling the [alertPolicies.create][google.monitoring.v3.AlertPolicyService.CreateAlertPolicy] method, do not include the `name` field in the conditions of the requested alerting policy. Stackdriver Monitoring creates the condition identifiers and includes them in the new policy. When calling the [alertPolicies.update][google.monitoring.v3.AlertPolicyService.UpdateAlertPolicy] method to update a policy, including a condition `name` causes the existing condition to be updated. Conditions without names are added to the updated policy. Existing conditions are deleted if they are not updated. Best practice is to preserve `[CONDITION_ID]` if you make only small changes, such as those to condition thresholds, durations, or trigger values. Otherwise, treat the change as a new condition and let the existing condition be deleted.
string name = 12;
getName
in interface AlertPolicy.ConditionOrBuilder
public ByteString getNameBytes()
Required if the condition exists. The unique resource name for this condition. Its syntax is: projects/[PROJECT_ID]/alertPolicies/[POLICY_ID]/conditions/[CONDITION_ID] `[CONDITION_ID]` is assigned by Stackdriver Monitoring when the condition is created as part of a new or updated alerting policy. When calling the [alertPolicies.create][google.monitoring.v3.AlertPolicyService.CreateAlertPolicy] method, do not include the `name` field in the conditions of the requested alerting policy. Stackdriver Monitoring creates the condition identifiers and includes them in the new policy. When calling the [alertPolicies.update][google.monitoring.v3.AlertPolicyService.UpdateAlertPolicy] method to update a policy, including a condition `name` causes the existing condition to be updated. Conditions without names are added to the updated policy. Existing conditions are deleted if they are not updated. Best practice is to preserve `[CONDITION_ID]` if you make only small changes, such as those to condition thresholds, durations, or trigger values. Otherwise, treat the change as a new condition and let the existing condition be deleted.
string name = 12;
getNameBytes
in interface AlertPolicy.ConditionOrBuilder
public java.lang.String getDisplayName()
A short name or phrase used to identify the condition in dashboards, notifications, and incidents. To avoid confusion, don't use the same display name for multiple conditions in the same policy.
string display_name = 6;
getDisplayName
in interface AlertPolicy.ConditionOrBuilder
public ByteString getDisplayNameBytes()
A short name or phrase used to identify the condition in dashboards, notifications, and incidents. To avoid confusion, don't use the same display name for multiple conditions in the same policy.
string display_name = 6;
getDisplayNameBytes
in interface AlertPolicy.ConditionOrBuilder
public boolean hasConditionThreshold()
A condition that compares a time series against a threshold.
.google.monitoring.v3.AlertPolicy.Condition.MetricThreshold condition_threshold = 1;
hasConditionThreshold
in interface AlertPolicy.ConditionOrBuilder
public AlertPolicy.Condition.MetricThreshold getConditionThreshold()
A condition that compares a time series against a threshold.
.google.monitoring.v3.AlertPolicy.Condition.MetricThreshold condition_threshold = 1;
getConditionThreshold
in interface AlertPolicy.ConditionOrBuilder
public AlertPolicy.Condition.MetricThresholdOrBuilder getConditionThresholdOrBuilder()
A condition that compares a time series against a threshold.
.google.monitoring.v3.AlertPolicy.Condition.MetricThreshold condition_threshold = 1;
getConditionThresholdOrBuilder
in interface AlertPolicy.ConditionOrBuilder
public boolean hasConditionAbsent()
A condition that checks that a time series continues to receive new data points.
.google.monitoring.v3.AlertPolicy.Condition.MetricAbsence condition_absent = 2;
hasConditionAbsent
in interface AlertPolicy.ConditionOrBuilder
public AlertPolicy.Condition.MetricAbsence getConditionAbsent()
A condition that checks that a time series continues to receive new data points.
.google.monitoring.v3.AlertPolicy.Condition.MetricAbsence condition_absent = 2;
getConditionAbsent
in interface AlertPolicy.ConditionOrBuilder
public AlertPolicy.Condition.MetricAbsenceOrBuilder getConditionAbsentOrBuilder()
A condition that checks that a time series continues to receive new data points.
.google.monitoring.v3.AlertPolicy.Condition.MetricAbsence condition_absent = 2;
getConditionAbsentOrBuilder
in interface AlertPolicy.ConditionOrBuilder
public final boolean isInitialized()
isInitialized
in interface MessageLiteOrBuilder
isInitialized
in class GeneratedMessageV3
public void writeTo(CodedOutputStream output) throws java.io.IOException
writeTo
in interface MessageLite
writeTo
in class GeneratedMessageV3
java.io.IOException
public int getSerializedSize()
getSerializedSize
in interface MessageLite
getSerializedSize
in class GeneratedMessageV3
public boolean equals(java.lang.Object obj)
equals
in interface Message
equals
in class AbstractMessage
public int hashCode()
hashCode
in interface Message
hashCode
in class AbstractMessage
public static AlertPolicy.Condition parseFrom(java.nio.ByteBuffer data) throws InvalidProtocolBufferException
InvalidProtocolBufferException
public static AlertPolicy.Condition parseFrom(java.nio.ByteBuffer data, ExtensionRegistryLite extensionRegistry) throws InvalidProtocolBufferException
InvalidProtocolBufferException
public static AlertPolicy.Condition parseFrom(ByteString data) throws InvalidProtocolBufferException
InvalidProtocolBufferException
public static AlertPolicy.Condition parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry) throws InvalidProtocolBufferException
InvalidProtocolBufferException
public static AlertPolicy.Condition parseFrom(byte[] data) throws InvalidProtocolBufferException
InvalidProtocolBufferException
public static AlertPolicy.Condition parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry) throws InvalidProtocolBufferException
InvalidProtocolBufferException
public static AlertPolicy.Condition parseFrom(java.io.InputStream input) throws java.io.IOException
java.io.IOException
public static AlertPolicy.Condition parseFrom(java.io.InputStream input, ExtensionRegistryLite extensionRegistry) throws java.io.IOException
java.io.IOException
public static AlertPolicy.Condition parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException
java.io.IOException
public static AlertPolicy.Condition parseDelimitedFrom(java.io.InputStream input, ExtensionRegistryLite extensionRegistry) throws java.io.IOException
java.io.IOException
public static AlertPolicy.Condition parseFrom(CodedInputStream input) throws java.io.IOException
java.io.IOException
public static AlertPolicy.Condition parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry) throws java.io.IOException
java.io.IOException
public AlertPolicy.Condition.Builder newBuilderForType()
newBuilderForType
in interface Message
newBuilderForType
in interface MessageLite
public static AlertPolicy.Condition.Builder newBuilder()
public static AlertPolicy.Condition.Builder newBuilder(AlertPolicy.Condition prototype)
public AlertPolicy.Condition.Builder toBuilder()
toBuilder
in interface Message
toBuilder
in interface MessageLite
protected AlertPolicy.Condition.Builder newBuilderForType(GeneratedMessageV3.BuilderParent parent)
newBuilderForType
in class GeneratedMessageV3
public static AlertPolicy.Condition getDefaultInstance()
public static Parser<AlertPolicy.Condition> parser()
public Parser<AlertPolicy.Condition> getParserForType()
getParserForType
in interface Message
getParserForType
in interface MessageLite
getParserForType
in class GeneratedMessageV3
public AlertPolicy.Condition getDefaultInstanceForType()
getDefaultInstanceForType
in interface MessageLiteOrBuilder
getDefaultInstanceForType
in interface MessageOrBuilder