public static final class CustomErrorResponsePolicyCustomErrorResponseRule.Builder extends com.google.protobuf.GeneratedMessageV3.Builder<CustomErrorResponsePolicyCustomErrorResponseRule.Builder> implements CustomErrorResponsePolicyCustomErrorResponseRuleOrBuilder
Specifies the mapping between the response code that will be returned along with the custom error content and the response code returned by the backend service.Protobuf type
google.cloud.compute.v1.CustomErrorResponsePolicyCustomErrorResponseRule| Modifier and Type | Method and Description |
|---|---|
CustomErrorResponsePolicyCustomErrorResponseRule.Builder |
addAllMatchResponseCodes(Iterable<String> values)
Valid values include: - A number between 400 and 599: For example 401 or 503, in which case the load balancer applies the policy if the error code exactly matches this value. - 5xx: Load Balancer will apply the policy if the backend service responds with any response code in the range of 500 to 599. - 4xx: Load Balancer will apply the policy if the backend service responds with any response code in the range of 400 to 499.
|
CustomErrorResponsePolicyCustomErrorResponseRule.Builder |
addMatchResponseCodes(String value)
Valid values include: - A number between 400 and 599: For example 401 or 503, in which case the load balancer applies the policy if the error code exactly matches this value. - 5xx: Load Balancer will apply the policy if the backend service responds with any response code in the range of 500 to 599. - 4xx: Load Balancer will apply the policy if the backend service responds with any response code in the range of 400 to 499.
|
CustomErrorResponsePolicyCustomErrorResponseRule.Builder |
addMatchResponseCodesBytes(com.google.protobuf.ByteString value)
Valid values include: - A number between 400 and 599: For example 401 or 503, in which case the load balancer applies the policy if the error code exactly matches this value. - 5xx: Load Balancer will apply the policy if the backend service responds with any response code in the range of 500 to 599. - 4xx: Load Balancer will apply the policy if the backend service responds with any response code in the range of 400 to 499.
|
CustomErrorResponsePolicyCustomErrorResponseRule.Builder |
addRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field,
Object value) |
CustomErrorResponsePolicyCustomErrorResponseRule |
build() |
CustomErrorResponsePolicyCustomErrorResponseRule |
buildPartial() |
CustomErrorResponsePolicyCustomErrorResponseRule.Builder |
clear() |
CustomErrorResponsePolicyCustomErrorResponseRule.Builder |
clearField(com.google.protobuf.Descriptors.FieldDescriptor field) |
CustomErrorResponsePolicyCustomErrorResponseRule.Builder |
clearMatchResponseCodes()
Valid values include: - A number between 400 and 599: For example 401 or 503, in which case the load balancer applies the policy if the error code exactly matches this value. - 5xx: Load Balancer will apply the policy if the backend service responds with any response code in the range of 500 to 599. - 4xx: Load Balancer will apply the policy if the backend service responds with any response code in the range of 400 to 499.
|
CustomErrorResponsePolicyCustomErrorResponseRule.Builder |
clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) |
CustomErrorResponsePolicyCustomErrorResponseRule.Builder |
clearOverrideResponseCode()
The HTTP status code returned with the response containing the custom error content.
|
CustomErrorResponsePolicyCustomErrorResponseRule.Builder |
clearPath()
The full path to a file within backendBucket .
|
CustomErrorResponsePolicyCustomErrorResponseRule.Builder |
clone() |
CustomErrorResponsePolicyCustomErrorResponseRule |
getDefaultInstanceForType() |
static com.google.protobuf.Descriptors.Descriptor |
getDescriptor() |
com.google.protobuf.Descriptors.Descriptor |
getDescriptorForType() |
String |
getMatchResponseCodes(int index)
Valid values include: - A number between 400 and 599: For example 401 or 503, in which case the load balancer applies the policy if the error code exactly matches this value. - 5xx: Load Balancer will apply the policy if the backend service responds with any response code in the range of 500 to 599. - 4xx: Load Balancer will apply the policy if the backend service responds with any response code in the range of 400 to 499.
|
com.google.protobuf.ByteString |
getMatchResponseCodesBytes(int index)
Valid values include: - A number between 400 and 599: For example 401 or 503, in which case the load balancer applies the policy if the error code exactly matches this value. - 5xx: Load Balancer will apply the policy if the backend service responds with any response code in the range of 500 to 599. - 4xx: Load Balancer will apply the policy if the backend service responds with any response code in the range of 400 to 499.
|
int |
getMatchResponseCodesCount()
Valid values include: - A number between 400 and 599: For example 401 or 503, in which case the load balancer applies the policy if the error code exactly matches this value. - 5xx: Load Balancer will apply the policy if the backend service responds with any response code in the range of 500 to 599. - 4xx: Load Balancer will apply the policy if the backend service responds with any response code in the range of 400 to 499.
|
com.google.protobuf.ProtocolStringList |
getMatchResponseCodesList()
Valid values include: - A number between 400 and 599: For example 401 or 503, in which case the load balancer applies the policy if the error code exactly matches this value. - 5xx: Load Balancer will apply the policy if the backend service responds with any response code in the range of 500 to 599. - 4xx: Load Balancer will apply the policy if the backend service responds with any response code in the range of 400 to 499.
|
int |
getOverrideResponseCode()
The HTTP status code returned with the response containing the custom error content.
|
String |
getPath()
The full path to a file within backendBucket .
|
com.google.protobuf.ByteString |
getPathBytes()
The full path to a file within backendBucket .
|
boolean |
hasOverrideResponseCode()
The HTTP status code returned with the response containing the custom error content.
|
boolean |
hasPath()
The full path to a file within backendBucket .
|
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable |
internalGetFieldAccessorTable() |
boolean |
isInitialized() |
CustomErrorResponsePolicyCustomErrorResponseRule.Builder |
mergeFrom(com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
CustomErrorResponsePolicyCustomErrorResponseRule.Builder |
mergeFrom(CustomErrorResponsePolicyCustomErrorResponseRule other) |
CustomErrorResponsePolicyCustomErrorResponseRule.Builder |
mergeFrom(com.google.protobuf.Message other) |
CustomErrorResponsePolicyCustomErrorResponseRule.Builder |
mergeUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields) |
CustomErrorResponsePolicyCustomErrorResponseRule.Builder |
setField(com.google.protobuf.Descriptors.FieldDescriptor field,
Object value) |
CustomErrorResponsePolicyCustomErrorResponseRule.Builder |
setMatchResponseCodes(int index,
String value)
Valid values include: - A number between 400 and 599: For example 401 or 503, in which case the load balancer applies the policy if the error code exactly matches this value. - 5xx: Load Balancer will apply the policy if the backend service responds with any response code in the range of 500 to 599. - 4xx: Load Balancer will apply the policy if the backend service responds with any response code in the range of 400 to 499.
|
CustomErrorResponsePolicyCustomErrorResponseRule.Builder |
setOverrideResponseCode(int value)
The HTTP status code returned with the response containing the custom error content.
|
CustomErrorResponsePolicyCustomErrorResponseRule.Builder |
setPath(String value)
The full path to a file within backendBucket .
|
CustomErrorResponsePolicyCustomErrorResponseRule.Builder |
setPathBytes(com.google.protobuf.ByteString value)
The full path to a file within backendBucket .
|
CustomErrorResponsePolicyCustomErrorResponseRule.Builder |
setRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field,
int index,
Object value) |
CustomErrorResponsePolicyCustomErrorResponseRule.Builder |
setUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields) |
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, setUnknownFieldsProto3findInitializationErrors, getInitializationErrorString, internalMergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, newUninitializedMessageException, toStringaddAll, addAll, mergeDelimitedFrom, mergeDelimitedFrom, newUninitializedMessageExceptionequals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitpublic static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessageV3.Builder<CustomErrorResponsePolicyCustomErrorResponseRule.Builder>public CustomErrorResponsePolicyCustomErrorResponseRule.Builder clear()
clear in interface com.google.protobuf.Message.Builderclear in interface com.google.protobuf.MessageLite.Builderclear in class com.google.protobuf.GeneratedMessageV3.Builder<CustomErrorResponsePolicyCustomErrorResponseRule.Builder>public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()
getDescriptorForType in interface com.google.protobuf.Message.BuildergetDescriptorForType in interface com.google.protobuf.MessageOrBuildergetDescriptorForType in class com.google.protobuf.GeneratedMessageV3.Builder<CustomErrorResponsePolicyCustomErrorResponseRule.Builder>public CustomErrorResponsePolicyCustomErrorResponseRule getDefaultInstanceForType()
getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuildergetDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilderpublic CustomErrorResponsePolicyCustomErrorResponseRule build()
build in interface com.google.protobuf.Message.Builderbuild in interface com.google.protobuf.MessageLite.Builderpublic CustomErrorResponsePolicyCustomErrorResponseRule buildPartial()
buildPartial in interface com.google.protobuf.Message.BuilderbuildPartial in interface com.google.protobuf.MessageLite.Builderpublic CustomErrorResponsePolicyCustomErrorResponseRule.Builder clone()
clone in interface com.google.protobuf.Message.Builderclone in interface com.google.protobuf.MessageLite.Builderclone in class com.google.protobuf.GeneratedMessageV3.Builder<CustomErrorResponsePolicyCustomErrorResponseRule.Builder>public CustomErrorResponsePolicyCustomErrorResponseRule.Builder setField(com.google.protobuf.Descriptors.FieldDescriptor field, Object value)
setField in interface com.google.protobuf.Message.BuildersetField in class com.google.protobuf.GeneratedMessageV3.Builder<CustomErrorResponsePolicyCustomErrorResponseRule.Builder>public CustomErrorResponsePolicyCustomErrorResponseRule.Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field)
clearField in interface com.google.protobuf.Message.BuilderclearField in class com.google.protobuf.GeneratedMessageV3.Builder<CustomErrorResponsePolicyCustomErrorResponseRule.Builder>public CustomErrorResponsePolicyCustomErrorResponseRule.Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof)
clearOneof in interface com.google.protobuf.Message.BuilderclearOneof in class com.google.protobuf.GeneratedMessageV3.Builder<CustomErrorResponsePolicyCustomErrorResponseRule.Builder>public CustomErrorResponsePolicyCustomErrorResponseRule.Builder setRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, int index, Object value)
setRepeatedField in interface com.google.protobuf.Message.BuildersetRepeatedField in class com.google.protobuf.GeneratedMessageV3.Builder<CustomErrorResponsePolicyCustomErrorResponseRule.Builder>public CustomErrorResponsePolicyCustomErrorResponseRule.Builder addRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, Object value)
addRepeatedField in interface com.google.protobuf.Message.BuilderaddRepeatedField in class com.google.protobuf.GeneratedMessageV3.Builder<CustomErrorResponsePolicyCustomErrorResponseRule.Builder>public CustomErrorResponsePolicyCustomErrorResponseRule.Builder mergeFrom(com.google.protobuf.Message other)
mergeFrom in interface com.google.protobuf.Message.BuildermergeFrom in class com.google.protobuf.AbstractMessage.Builder<CustomErrorResponsePolicyCustomErrorResponseRule.Builder>public CustomErrorResponsePolicyCustomErrorResponseRule.Builder mergeFrom(CustomErrorResponsePolicyCustomErrorResponseRule other)
public final boolean isInitialized()
isInitialized in interface com.google.protobuf.MessageLiteOrBuilderisInitialized in class com.google.protobuf.GeneratedMessageV3.Builder<CustomErrorResponsePolicyCustomErrorResponseRule.Builder>public CustomErrorResponsePolicyCustomErrorResponseRule.Builder mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
mergeFrom in interface com.google.protobuf.Message.BuildermergeFrom in interface com.google.protobuf.MessageLite.BuildermergeFrom in class com.google.protobuf.AbstractMessage.Builder<CustomErrorResponsePolicyCustomErrorResponseRule.Builder>IOExceptionpublic com.google.protobuf.ProtocolStringList getMatchResponseCodesList()
Valid values include: - A number between 400 and 599: For example 401 or 503, in which case the load balancer applies the policy if the error code exactly matches this value. - 5xx: Load Balancer will apply the policy if the backend service responds with any response code in the range of 500 to 599. - 4xx: Load Balancer will apply the policy if the backend service responds with any response code in the range of 400 to 499. Values must be unique within matchResponseCodes and across all errorResponseRules of CustomErrorResponsePolicy.
repeated string match_response_codes = 104973410;getMatchResponseCodesList in interface CustomErrorResponsePolicyCustomErrorResponseRuleOrBuilderpublic int getMatchResponseCodesCount()
Valid values include: - A number between 400 and 599: For example 401 or 503, in which case the load balancer applies the policy if the error code exactly matches this value. - 5xx: Load Balancer will apply the policy if the backend service responds with any response code in the range of 500 to 599. - 4xx: Load Balancer will apply the policy if the backend service responds with any response code in the range of 400 to 499. Values must be unique within matchResponseCodes and across all errorResponseRules of CustomErrorResponsePolicy.
repeated string match_response_codes = 104973410;getMatchResponseCodesCount in interface CustomErrorResponsePolicyCustomErrorResponseRuleOrBuilderpublic String getMatchResponseCodes(int index)
Valid values include: - A number between 400 and 599: For example 401 or 503, in which case the load balancer applies the policy if the error code exactly matches this value. - 5xx: Load Balancer will apply the policy if the backend service responds with any response code in the range of 500 to 599. - 4xx: Load Balancer will apply the policy if the backend service responds with any response code in the range of 400 to 499. Values must be unique within matchResponseCodes and across all errorResponseRules of CustomErrorResponsePolicy.
repeated string match_response_codes = 104973410;getMatchResponseCodes in interface CustomErrorResponsePolicyCustomErrorResponseRuleOrBuilderindex - The index of the element to return.public com.google.protobuf.ByteString getMatchResponseCodesBytes(int index)
Valid values include: - A number between 400 and 599: For example 401 or 503, in which case the load balancer applies the policy if the error code exactly matches this value. - 5xx: Load Balancer will apply the policy if the backend service responds with any response code in the range of 500 to 599. - 4xx: Load Balancer will apply the policy if the backend service responds with any response code in the range of 400 to 499. Values must be unique within matchResponseCodes and across all errorResponseRules of CustomErrorResponsePolicy.
repeated string match_response_codes = 104973410;getMatchResponseCodesBytes in interface CustomErrorResponsePolicyCustomErrorResponseRuleOrBuilderindex - The index of the value to return.public CustomErrorResponsePolicyCustomErrorResponseRule.Builder setMatchResponseCodes(int index, String value)
Valid values include: - A number between 400 and 599: For example 401 or 503, in which case the load balancer applies the policy if the error code exactly matches this value. - 5xx: Load Balancer will apply the policy if the backend service responds with any response code in the range of 500 to 599. - 4xx: Load Balancer will apply the policy if the backend service responds with any response code in the range of 400 to 499. Values must be unique within matchResponseCodes and across all errorResponseRules of CustomErrorResponsePolicy.
repeated string match_response_codes = 104973410;index - The index to set the value at.value - The matchResponseCodes to set.public CustomErrorResponsePolicyCustomErrorResponseRule.Builder addMatchResponseCodes(String value)
Valid values include: - A number between 400 and 599: For example 401 or 503, in which case the load balancer applies the policy if the error code exactly matches this value. - 5xx: Load Balancer will apply the policy if the backend service responds with any response code in the range of 500 to 599. - 4xx: Load Balancer will apply the policy if the backend service responds with any response code in the range of 400 to 499. Values must be unique within matchResponseCodes and across all errorResponseRules of CustomErrorResponsePolicy.
repeated string match_response_codes = 104973410;value - The matchResponseCodes to add.public CustomErrorResponsePolicyCustomErrorResponseRule.Builder addAllMatchResponseCodes(Iterable<String> values)
Valid values include: - A number between 400 and 599: For example 401 or 503, in which case the load balancer applies the policy if the error code exactly matches this value. - 5xx: Load Balancer will apply the policy if the backend service responds with any response code in the range of 500 to 599. - 4xx: Load Balancer will apply the policy if the backend service responds with any response code in the range of 400 to 499. Values must be unique within matchResponseCodes and across all errorResponseRules of CustomErrorResponsePolicy.
repeated string match_response_codes = 104973410;values - The matchResponseCodes to add.public CustomErrorResponsePolicyCustomErrorResponseRule.Builder clearMatchResponseCodes()
Valid values include: - A number between 400 and 599: For example 401 or 503, in which case the load balancer applies the policy if the error code exactly matches this value. - 5xx: Load Balancer will apply the policy if the backend service responds with any response code in the range of 500 to 599. - 4xx: Load Balancer will apply the policy if the backend service responds with any response code in the range of 400 to 499. Values must be unique within matchResponseCodes and across all errorResponseRules of CustomErrorResponsePolicy.
repeated string match_response_codes = 104973410;public CustomErrorResponsePolicyCustomErrorResponseRule.Builder addMatchResponseCodesBytes(com.google.protobuf.ByteString value)
Valid values include: - A number between 400 and 599: For example 401 or 503, in which case the load balancer applies the policy if the error code exactly matches this value. - 5xx: Load Balancer will apply the policy if the backend service responds with any response code in the range of 500 to 599. - 4xx: Load Balancer will apply the policy if the backend service responds with any response code in the range of 400 to 499. Values must be unique within matchResponseCodes and across all errorResponseRules of CustomErrorResponsePolicy.
repeated string match_response_codes = 104973410;value - The bytes of the matchResponseCodes to add.public boolean hasOverrideResponseCode()
The HTTP status code returned with the response containing the custom error content. If overrideResponseCode is not supplied, the same response code returned by the original backend bucket or backend service is returned to the client.
optional int32 override_response_code = 530328568;hasOverrideResponseCode in interface CustomErrorResponsePolicyCustomErrorResponseRuleOrBuilderpublic int getOverrideResponseCode()
The HTTP status code returned with the response containing the custom error content. If overrideResponseCode is not supplied, the same response code returned by the original backend bucket or backend service is returned to the client.
optional int32 override_response_code = 530328568;getOverrideResponseCode in interface CustomErrorResponsePolicyCustomErrorResponseRuleOrBuilderpublic CustomErrorResponsePolicyCustomErrorResponseRule.Builder setOverrideResponseCode(int value)
The HTTP status code returned with the response containing the custom error content. If overrideResponseCode is not supplied, the same response code returned by the original backend bucket or backend service is returned to the client.
optional int32 override_response_code = 530328568;value - The overrideResponseCode to set.public CustomErrorResponsePolicyCustomErrorResponseRule.Builder clearOverrideResponseCode()
The HTTP status code returned with the response containing the custom error content. If overrideResponseCode is not supplied, the same response code returned by the original backend bucket or backend service is returned to the client.
optional int32 override_response_code = 530328568;public boolean hasPath()
The full path to a file within backendBucket . For example: /errors/defaultError.html path must start with a leading slash. path cannot have trailing slashes. If the file is not available in backendBucket or the load balancer cannot reach the BackendBucket, a simple Not Found Error is returned to the client. The value must be from 1 to 1024 characters
optional string path = 3433509;hasPath in interface CustomErrorResponsePolicyCustomErrorResponseRuleOrBuilderpublic String getPath()
The full path to a file within backendBucket . For example: /errors/defaultError.html path must start with a leading slash. path cannot have trailing slashes. If the file is not available in backendBucket or the load balancer cannot reach the BackendBucket, a simple Not Found Error is returned to the client. The value must be from 1 to 1024 characters
optional string path = 3433509;getPath in interface CustomErrorResponsePolicyCustomErrorResponseRuleOrBuilderpublic com.google.protobuf.ByteString getPathBytes()
The full path to a file within backendBucket . For example: /errors/defaultError.html path must start with a leading slash. path cannot have trailing slashes. If the file is not available in backendBucket or the load balancer cannot reach the BackendBucket, a simple Not Found Error is returned to the client. The value must be from 1 to 1024 characters
optional string path = 3433509;getPathBytes in interface CustomErrorResponsePolicyCustomErrorResponseRuleOrBuilderpublic CustomErrorResponsePolicyCustomErrorResponseRule.Builder setPath(String value)
The full path to a file within backendBucket . For example: /errors/defaultError.html path must start with a leading slash. path cannot have trailing slashes. If the file is not available in backendBucket or the load balancer cannot reach the BackendBucket, a simple Not Found Error is returned to the client. The value must be from 1 to 1024 characters
optional string path = 3433509;value - The path to set.public CustomErrorResponsePolicyCustomErrorResponseRule.Builder clearPath()
The full path to a file within backendBucket . For example: /errors/defaultError.html path must start with a leading slash. path cannot have trailing slashes. If the file is not available in backendBucket or the load balancer cannot reach the BackendBucket, a simple Not Found Error is returned to the client. The value must be from 1 to 1024 characters
optional string path = 3433509;public CustomErrorResponsePolicyCustomErrorResponseRule.Builder setPathBytes(com.google.protobuf.ByteString value)
The full path to a file within backendBucket . For example: /errors/defaultError.html path must start with a leading slash. path cannot have trailing slashes. If the file is not available in backendBucket or the load balancer cannot reach the BackendBucket, a simple Not Found Error is returned to the client. The value must be from 1 to 1024 characters
optional string path = 3433509;value - The bytes for path to set.public final CustomErrorResponsePolicyCustomErrorResponseRule.Builder setUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields)
setUnknownFields in interface com.google.protobuf.Message.BuildersetUnknownFields in class com.google.protobuf.GeneratedMessageV3.Builder<CustomErrorResponsePolicyCustomErrorResponseRule.Builder>public final CustomErrorResponsePolicyCustomErrorResponseRule.Builder mergeUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields)
mergeUnknownFields in interface com.google.protobuf.Message.BuildermergeUnknownFields in class com.google.protobuf.GeneratedMessageV3.Builder<CustomErrorResponsePolicyCustomErrorResponseRule.Builder>Copyright © 2025 Google LLC. All rights reserved.