Package com.google.logging.v2
Class LogExclusion.Builder
java.lang.Object
com.google.protobuf.AbstractMessageLite.Builder
com.google.protobuf.AbstractMessage.Builder<BuilderT>
com.google.protobuf.GeneratedMessageV3.Builder<LogExclusion.Builder>
com.google.logging.v2.LogExclusion.Builder
- All Implemented Interfaces:
LogExclusionOrBuilder,com.google.protobuf.Message.Builder,com.google.protobuf.MessageLite.Builder,com.google.protobuf.MessageLiteOrBuilder,com.google.protobuf.MessageOrBuilder,Cloneable
- Enclosing class:
- LogExclusion
public static final class LogExclusion.Builder
extends com.google.protobuf.GeneratedMessageV3.Builder<LogExclusion.Builder>
implements LogExclusionOrBuilder
Specifies a set of log entries that are filtered out by a sink. If your Google Cloud resource receives a large volume of log entries, you can use exclusions to reduce your chargeable logs. Note that exclusions on organization-level and folder-level sinks don't apply to child resources. Note also that you cannot modify the _Required sink or exclude logs from it.Protobuf type
google.logging.v2.LogExclusion-
Method Summary
Modifier and TypeMethodDescriptionaddRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, Object value) build()clear()Output only.Optional.Optional.clearField(com.google.protobuf.Descriptors.FieldDescriptor field) Required.Required.clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) Output only.clone()com.google.protobuf.TimestampOutput only.com.google.protobuf.Timestamp.BuilderOutput only.com.google.protobuf.TimestampOrBuilderOutput only.Optional.com.google.protobuf.ByteStringOptional.static final com.google.protobuf.Descriptors.Descriptorcom.google.protobuf.Descriptors.DescriptorbooleanOptional.Required.com.google.protobuf.ByteStringRequired.getName()Required.com.google.protobuf.ByteStringRequired.com.google.protobuf.TimestampOutput only.com.google.protobuf.Timestamp.BuilderOutput only.com.google.protobuf.TimestampOrBuilderOutput only.booleanOutput only.booleanOutput only.protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTablefinal booleanmergeCreateTime(com.google.protobuf.Timestamp value) Output only.mergeFrom(LogExclusion other) mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) mergeFrom(com.google.protobuf.Message other) final LogExclusion.BuildermergeUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields) mergeUpdateTime(com.google.protobuf.Timestamp value) Output only.setCreateTime(com.google.protobuf.Timestamp value) Output only.setCreateTime(com.google.protobuf.Timestamp.Builder builderForValue) Output only.setDescription(String value) Optional.setDescriptionBytes(com.google.protobuf.ByteString value) Optional.setDisabled(boolean value) Optional.Required.setFilterBytes(com.google.protobuf.ByteString value) Required.Required.setNameBytes(com.google.protobuf.ByteString value) Required.setRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, int index, Object value) final LogExclusion.BuildersetUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields) setUpdateTime(com.google.protobuf.Timestamp value) Output only.setUpdateTime(com.google.protobuf.Timestamp.Builder builderForValue) Output only.Methods inherited from class com.google.protobuf.GeneratedMessageV3.Builder
getAllFields, getField, getFieldBuilder, getOneofFieldDescriptor, getParentForChildren, getRepeatedField, getRepeatedFieldBuilder, getRepeatedFieldCount, getUnknownFields, getUnknownFieldSetBuilder, hasField, hasOneof, internalGetMapField, internalGetMapFieldReflection, internalGetMutableMapField, internalGetMutableMapFieldReflection, isClean, markClean, mergeUnknownLengthDelimitedField, mergeUnknownVarintField, newBuilderForField, onBuilt, onChanged, parseUnknownField, setUnknownFieldSetBuilder, setUnknownFieldsProto3Methods inherited from class com.google.protobuf.AbstractMessage.Builder
findInitializationErrors, getInitializationErrorString, internalMergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, newUninitializedMessageException, toStringMethods inherited from class com.google.protobuf.AbstractMessageLite.Builder
addAll, addAll, mergeDelimitedFrom, mergeDelimitedFrom, mergeFrom, newUninitializedMessageExceptionMethods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface com.google.protobuf.Message.Builder
mergeDelimitedFrom, mergeDelimitedFromMethods inherited from interface com.google.protobuf.MessageLite.Builder
mergeFromMethods inherited from interface com.google.protobuf.MessageOrBuilder
findInitializationErrors, getAllFields, getField, getInitializationErrorString, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof
-
Method Details
-
getDescriptor
public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() -
internalGetFieldAccessorTable
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()- Specified by:
internalGetFieldAccessorTablein classcom.google.protobuf.GeneratedMessageV3.Builder<LogExclusion.Builder>
-
clear
- Specified by:
clearin interfacecom.google.protobuf.Message.Builder- Specified by:
clearin interfacecom.google.protobuf.MessageLite.Builder- Overrides:
clearin classcom.google.protobuf.GeneratedMessageV3.Builder<LogExclusion.Builder>
-
getDescriptorForType
public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()- Specified by:
getDescriptorForTypein interfacecom.google.protobuf.Message.Builder- Specified by:
getDescriptorForTypein interfacecom.google.protobuf.MessageOrBuilder- Overrides:
getDescriptorForTypein classcom.google.protobuf.GeneratedMessageV3.Builder<LogExclusion.Builder>
-
getDefaultInstanceForType
- Specified by:
getDefaultInstanceForTypein interfacecom.google.protobuf.MessageLiteOrBuilder- Specified by:
getDefaultInstanceForTypein interfacecom.google.protobuf.MessageOrBuilder
-
build
- Specified by:
buildin interfacecom.google.protobuf.Message.Builder- Specified by:
buildin interfacecom.google.protobuf.MessageLite.Builder
-
buildPartial
- Specified by:
buildPartialin interfacecom.google.protobuf.Message.Builder- Specified by:
buildPartialin interfacecom.google.protobuf.MessageLite.Builder
-
clone
- Specified by:
clonein interfacecom.google.protobuf.Message.Builder- Specified by:
clonein interfacecom.google.protobuf.MessageLite.Builder- Overrides:
clonein classcom.google.protobuf.GeneratedMessageV3.Builder<LogExclusion.Builder>
-
setField
public LogExclusion.Builder setField(com.google.protobuf.Descriptors.FieldDescriptor field, Object value) - Specified by:
setFieldin interfacecom.google.protobuf.Message.Builder- Overrides:
setFieldin classcom.google.protobuf.GeneratedMessageV3.Builder<LogExclusion.Builder>
-
clearField
- Specified by:
clearFieldin interfacecom.google.protobuf.Message.Builder- Overrides:
clearFieldin classcom.google.protobuf.GeneratedMessageV3.Builder<LogExclusion.Builder>
-
clearOneof
- Specified by:
clearOneofin interfacecom.google.protobuf.Message.Builder- Overrides:
clearOneofin classcom.google.protobuf.GeneratedMessageV3.Builder<LogExclusion.Builder>
-
setRepeatedField
public LogExclusion.Builder setRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, int index, Object value) - Specified by:
setRepeatedFieldin interfacecom.google.protobuf.Message.Builder- Overrides:
setRepeatedFieldin classcom.google.protobuf.GeneratedMessageV3.Builder<LogExclusion.Builder>
-
addRepeatedField
public LogExclusion.Builder addRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, Object value) - Specified by:
addRepeatedFieldin interfacecom.google.protobuf.Message.Builder- Overrides:
addRepeatedFieldin classcom.google.protobuf.GeneratedMessageV3.Builder<LogExclusion.Builder>
-
mergeFrom
- Specified by:
mergeFromin interfacecom.google.protobuf.Message.Builder- Overrides:
mergeFromin classcom.google.protobuf.AbstractMessage.Builder<LogExclusion.Builder>
-
mergeFrom
-
isInitialized
public final boolean isInitialized()- Specified by:
isInitializedin interfacecom.google.protobuf.MessageLiteOrBuilder- Overrides:
isInitializedin classcom.google.protobuf.GeneratedMessageV3.Builder<LogExclusion.Builder>
-
mergeFrom
public LogExclusion.Builder mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException - Specified by:
mergeFromin interfacecom.google.protobuf.Message.Builder- Specified by:
mergeFromin interfacecom.google.protobuf.MessageLite.Builder- Overrides:
mergeFromin classcom.google.protobuf.AbstractMessage.Builder<LogExclusion.Builder>- Throws:
IOException
-
getName
Required. A client-assigned identifier, such as `"load-balancer-exclusion"`. Identifiers are limited to 100 characters and can include only letters, digits, underscores, hyphens, and periods. First character has to be alphanumeric.
string name = 1 [(.google.api.field_behavior) = REQUIRED];- Specified by:
getNamein interfaceLogExclusionOrBuilder- Returns:
- The name.
-
getNameBytes
public com.google.protobuf.ByteString getNameBytes()Required. A client-assigned identifier, such as `"load-balancer-exclusion"`. Identifiers are limited to 100 characters and can include only letters, digits, underscores, hyphens, and periods. First character has to be alphanumeric.
string name = 1 [(.google.api.field_behavior) = REQUIRED];- Specified by:
getNameBytesin interfaceLogExclusionOrBuilder- Returns:
- The bytes for name.
-
setName
Required. A client-assigned identifier, such as `"load-balancer-exclusion"`. Identifiers are limited to 100 characters and can include only letters, digits, underscores, hyphens, and periods. First character has to be alphanumeric.
string name = 1 [(.google.api.field_behavior) = REQUIRED];- Parameters:
value- The name to set.- Returns:
- This builder for chaining.
-
clearName
Required. A client-assigned identifier, such as `"load-balancer-exclusion"`. Identifiers are limited to 100 characters and can include only letters, digits, underscores, hyphens, and periods. First character has to be alphanumeric.
string name = 1 [(.google.api.field_behavior) = REQUIRED];- Returns:
- This builder for chaining.
-
setNameBytes
Required. A client-assigned identifier, such as `"load-balancer-exclusion"`. Identifiers are limited to 100 characters and can include only letters, digits, underscores, hyphens, and periods. First character has to be alphanumeric.
string name = 1 [(.google.api.field_behavior) = REQUIRED];- Parameters:
value- The bytes for name to set.- Returns:
- This builder for chaining.
-
getDescription
Optional. A description of this exclusion.
string description = 2 [(.google.api.field_behavior) = OPTIONAL];- Specified by:
getDescriptionin interfaceLogExclusionOrBuilder- Returns:
- The description.
-
getDescriptionBytes
public com.google.protobuf.ByteString getDescriptionBytes()Optional. A description of this exclusion.
string description = 2 [(.google.api.field_behavior) = OPTIONAL];- Specified by:
getDescriptionBytesin interfaceLogExclusionOrBuilder- Returns:
- The bytes for description.
-
setDescription
Optional. A description of this exclusion.
string description = 2 [(.google.api.field_behavior) = OPTIONAL];- Parameters:
value- The description to set.- Returns:
- This builder for chaining.
-
clearDescription
Optional. A description of this exclusion.
string description = 2 [(.google.api.field_behavior) = OPTIONAL];- Returns:
- This builder for chaining.
-
setDescriptionBytes
Optional. A description of this exclusion.
string description = 2 [(.google.api.field_behavior) = OPTIONAL];- Parameters:
value- The bytes for description to set.- Returns:
- This builder for chaining.
-
getFilter
Required. An [advanced logs filter](https://cloud.google.com/logging/docs/view/advanced-queries) that matches the log entries to be excluded. By using the [sample function](https://cloud.google.com/logging/docs/view/advanced-queries#sample), you can exclude less than 100% of the matching log entries. For example, the following query matches 99% of low-severity log entries from Google Cloud Storage buckets: `resource.type=gcs_bucket severity<ERROR sample(insertId, 0.99)`
string filter = 3 [(.google.api.field_behavior) = REQUIRED];- Specified by:
getFilterin interfaceLogExclusionOrBuilder- Returns:
- The filter.
-
getFilterBytes
public com.google.protobuf.ByteString getFilterBytes()Required. An [advanced logs filter](https://cloud.google.com/logging/docs/view/advanced-queries) that matches the log entries to be excluded. By using the [sample function](https://cloud.google.com/logging/docs/view/advanced-queries#sample), you can exclude less than 100% of the matching log entries. For example, the following query matches 99% of low-severity log entries from Google Cloud Storage buckets: `resource.type=gcs_bucket severity<ERROR sample(insertId, 0.99)`
string filter = 3 [(.google.api.field_behavior) = REQUIRED];- Specified by:
getFilterBytesin interfaceLogExclusionOrBuilder- Returns:
- The bytes for filter.
-
setFilter
Required. An [advanced logs filter](https://cloud.google.com/logging/docs/view/advanced-queries) that matches the log entries to be excluded. By using the [sample function](https://cloud.google.com/logging/docs/view/advanced-queries#sample), you can exclude less than 100% of the matching log entries. For example, the following query matches 99% of low-severity log entries from Google Cloud Storage buckets: `resource.type=gcs_bucket severity<ERROR sample(insertId, 0.99)`
string filter = 3 [(.google.api.field_behavior) = REQUIRED];- Parameters:
value- The filter to set.- Returns:
- This builder for chaining.
-
clearFilter
Required. An [advanced logs filter](https://cloud.google.com/logging/docs/view/advanced-queries) that matches the log entries to be excluded. By using the [sample function](https://cloud.google.com/logging/docs/view/advanced-queries#sample), you can exclude less than 100% of the matching log entries. For example, the following query matches 99% of low-severity log entries from Google Cloud Storage buckets: `resource.type=gcs_bucket severity<ERROR sample(insertId, 0.99)`
string filter = 3 [(.google.api.field_behavior) = REQUIRED];- Returns:
- This builder for chaining.
-
setFilterBytes
Required. An [advanced logs filter](https://cloud.google.com/logging/docs/view/advanced-queries) that matches the log entries to be excluded. By using the [sample function](https://cloud.google.com/logging/docs/view/advanced-queries#sample), you can exclude less than 100% of the matching log entries. For example, the following query matches 99% of low-severity log entries from Google Cloud Storage buckets: `resource.type=gcs_bucket severity<ERROR sample(insertId, 0.99)`
string filter = 3 [(.google.api.field_behavior) = REQUIRED];- Parameters:
value- The bytes for filter to set.- Returns:
- This builder for chaining.
-
getDisabled
public boolean getDisabled()Optional. If set to True, then this exclusion is disabled and it does not exclude any log entries. You can [update an exclusion][google.logging.v2.ConfigServiceV2.UpdateExclusion] to change the value of this field.
bool disabled = 4 [(.google.api.field_behavior) = OPTIONAL];- Specified by:
getDisabledin interfaceLogExclusionOrBuilder- Returns:
- The disabled.
-
setDisabled
Optional. If set to True, then this exclusion is disabled and it does not exclude any log entries. You can [update an exclusion][google.logging.v2.ConfigServiceV2.UpdateExclusion] to change the value of this field.
bool disabled = 4 [(.google.api.field_behavior) = OPTIONAL];- Parameters:
value- The disabled to set.- Returns:
- This builder for chaining.
-
clearDisabled
Optional. If set to True, then this exclusion is disabled and it does not exclude any log entries. You can [update an exclusion][google.logging.v2.ConfigServiceV2.UpdateExclusion] to change the value of this field.
bool disabled = 4 [(.google.api.field_behavior) = OPTIONAL];- Returns:
- This builder for chaining.
-
hasCreateTime
public boolean hasCreateTime()Output only. The creation timestamp of the exclusion. This field may not be present for older exclusions.
.google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];- Specified by:
hasCreateTimein interfaceLogExclusionOrBuilder- Returns:
- Whether the createTime field is set.
-
getCreateTime
public com.google.protobuf.Timestamp getCreateTime()Output only. The creation timestamp of the exclusion. This field may not be present for older exclusions.
.google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];- Specified by:
getCreateTimein interfaceLogExclusionOrBuilder- Returns:
- The createTime.
-
setCreateTime
Output only. The creation timestamp of the exclusion. This field may not be present for older exclusions.
.google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; -
setCreateTime
Output only. The creation timestamp of the exclusion. This field may not be present for older exclusions.
.google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; -
mergeCreateTime
Output only. The creation timestamp of the exclusion. This field may not be present for older exclusions.
.google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; -
clearCreateTime
Output only. The creation timestamp of the exclusion. This field may not be present for older exclusions.
.google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; -
getCreateTimeBuilder
public com.google.protobuf.Timestamp.Builder getCreateTimeBuilder()Output only. The creation timestamp of the exclusion. This field may not be present for older exclusions.
.google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; -
getCreateTimeOrBuilder
public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder()Output only. The creation timestamp of the exclusion. This field may not be present for older exclusions.
.google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];- Specified by:
getCreateTimeOrBuilderin interfaceLogExclusionOrBuilder
-
hasUpdateTime
public boolean hasUpdateTime()Output only. The last update timestamp of the exclusion. This field may not be present for older exclusions.
.google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY];- Specified by:
hasUpdateTimein interfaceLogExclusionOrBuilder- Returns:
- Whether the updateTime field is set.
-
getUpdateTime
public com.google.protobuf.Timestamp getUpdateTime()Output only. The last update timestamp of the exclusion. This field may not be present for older exclusions.
.google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY];- Specified by:
getUpdateTimein interfaceLogExclusionOrBuilder- Returns:
- The updateTime.
-
setUpdateTime
Output only. The last update timestamp of the exclusion. This field may not be present for older exclusions.
.google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; -
setUpdateTime
Output only. The last update timestamp of the exclusion. This field may not be present for older exclusions.
.google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; -
mergeUpdateTime
Output only. The last update timestamp of the exclusion. This field may not be present for older exclusions.
.google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; -
clearUpdateTime
Output only. The last update timestamp of the exclusion. This field may not be present for older exclusions.
.google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; -
getUpdateTimeBuilder
public com.google.protobuf.Timestamp.Builder getUpdateTimeBuilder()Output only. The last update timestamp of the exclusion. This field may not be present for older exclusions.
.google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; -
getUpdateTimeOrBuilder
public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder()Output only. The last update timestamp of the exclusion. This field may not be present for older exclusions.
.google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY];- Specified by:
getUpdateTimeOrBuilderin interfaceLogExclusionOrBuilder
-
setUnknownFields
public final LogExclusion.Builder setUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields) - Specified by:
setUnknownFieldsin interfacecom.google.protobuf.Message.Builder- Overrides:
setUnknownFieldsin classcom.google.protobuf.GeneratedMessageV3.Builder<LogExclusion.Builder>
-
mergeUnknownFields
public final LogExclusion.Builder mergeUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields) - Specified by:
mergeUnknownFieldsin interfacecom.google.protobuf.Message.Builder- Overrides:
mergeUnknownFieldsin classcom.google.protobuf.GeneratedMessageV3.Builder<LogExclusion.Builder>
-