![JAR search and dependency download from the Maven repository](/logo.png)
io.envoyproxy.envoy.config.route.v3.RetryPolicy Maven / Gradle / Ivy
The newest version!
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: envoy/config/route/v3/route_components.proto
// Protobuf Java Version: 3.25.5
package io.envoyproxy.envoy.config.route.v3;
/**
*
* HTTP retry :ref:`architecture overview <arch_overview_http_routing_retry>`.
* [#next-free-field: 14]
*
*
* Protobuf type {@code envoy.config.route.v3.RetryPolicy}
*/
public final class RetryPolicy extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:envoy.config.route.v3.RetryPolicy)
RetryPolicyOrBuilder {
private static final long serialVersionUID = 0L;
// Use RetryPolicy.newBuilder() to construct.
private RetryPolicy(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private RetryPolicy() {
retryOn_ = "";
retryHostPredicate_ = java.util.Collections.emptyList();
retryOptionsPredicates_ = java.util.Collections.emptyList();
retriableStatusCodes_ = emptyIntList();
retriableHeaders_ = java.util.Collections.emptyList();
retriableRequestHeaders_ = java.util.Collections.emptyList();
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new RetryPolicy();
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RetryPolicy_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RetryPolicy_fieldAccessorTable
.ensureFieldAccessorsInitialized(
io.envoyproxy.envoy.config.route.v3.RetryPolicy.class, io.envoyproxy.envoy.config.route.v3.RetryPolicy.Builder.class);
}
/**
* Protobuf enum {@code envoy.config.route.v3.RetryPolicy.ResetHeaderFormat}
*/
public enum ResetHeaderFormat
implements com.google.protobuf.ProtocolMessageEnum {
/**
* SECONDS = 0;
*/
SECONDS(0),
/**
* UNIX_TIMESTAMP = 1;
*/
UNIX_TIMESTAMP(1),
UNRECOGNIZED(-1),
;
/**
* SECONDS = 0;
*/
public static final int SECONDS_VALUE = 0;
/**
* UNIX_TIMESTAMP = 1;
*/
public static final int UNIX_TIMESTAMP_VALUE = 1;
public final int getNumber() {
if (this == UNRECOGNIZED) {
throw new java.lang.IllegalArgumentException(
"Can't get the number of an unknown enum value.");
}
return value;
}
/**
* @param value The numeric wire value of the corresponding enum entry.
* @return The enum associated with the given numeric wire value.
* @deprecated Use {@link #forNumber(int)} instead.
*/
@java.lang.Deprecated
public static ResetHeaderFormat valueOf(int value) {
return forNumber(value);
}
/**
* @param value The numeric wire value of the corresponding enum entry.
* @return The enum associated with the given numeric wire value.
*/
public static ResetHeaderFormat forNumber(int value) {
switch (value) {
case 0: return SECONDS;
case 1: return UNIX_TIMESTAMP;
default: return null;
}
}
public static com.google.protobuf.Internal.EnumLiteMap
internalGetValueMap() {
return internalValueMap;
}
private static final com.google.protobuf.Internal.EnumLiteMap<
ResetHeaderFormat> internalValueMap =
new com.google.protobuf.Internal.EnumLiteMap() {
public ResetHeaderFormat findValueByNumber(int number) {
return ResetHeaderFormat.forNumber(number);
}
};
public final com.google.protobuf.Descriptors.EnumValueDescriptor
getValueDescriptor() {
if (this == UNRECOGNIZED) {
throw new java.lang.IllegalStateException(
"Can't get the descriptor of an unrecognized enum value.");
}
return getDescriptor().getValues().get(ordinal());
}
public final com.google.protobuf.Descriptors.EnumDescriptor
getDescriptorForType() {
return getDescriptor();
}
public static final com.google.protobuf.Descriptors.EnumDescriptor
getDescriptor() {
return io.envoyproxy.envoy.config.route.v3.RetryPolicy.getDescriptor().getEnumTypes().get(0);
}
private static final ResetHeaderFormat[] VALUES = values();
public static ResetHeaderFormat valueOf(
com.google.protobuf.Descriptors.EnumValueDescriptor desc) {
if (desc.getType() != getDescriptor()) {
throw new java.lang.IllegalArgumentException(
"EnumValueDescriptor is not for this type.");
}
if (desc.getIndex() == -1) {
return UNRECOGNIZED;
}
return VALUES[desc.getIndex()];
}
private final int value;
private ResetHeaderFormat(int value) {
this.value = value;
}
// @@protoc_insertion_point(enum_scope:envoy.config.route.v3.RetryPolicy.ResetHeaderFormat)
}
public interface RetryPriorityOrBuilder extends
// @@protoc_insertion_point(interface_extends:envoy.config.route.v3.RetryPolicy.RetryPriority)
com.google.protobuf.MessageOrBuilder {
/**
* string name = 1 [(.validate.rules) = { ... }
* @return The name.
*/
java.lang.String getName();
/**
* string name = 1 [(.validate.rules) = { ... }
* @return The bytes for name.
*/
com.google.protobuf.ByteString
getNameBytes();
/**
* .google.protobuf.Any typed_config = 3;
* @return Whether the typedConfig field is set.
*/
boolean hasTypedConfig();
/**
* .google.protobuf.Any typed_config = 3;
* @return The typedConfig.
*/
com.google.protobuf.Any getTypedConfig();
/**
* .google.protobuf.Any typed_config = 3;
*/
com.google.protobuf.AnyOrBuilder getTypedConfigOrBuilder();
io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryPriority.ConfigTypeCase getConfigTypeCase();
}
/**
* Protobuf type {@code envoy.config.route.v3.RetryPolicy.RetryPriority}
*/
public static final class RetryPriority extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:envoy.config.route.v3.RetryPolicy.RetryPriority)
RetryPriorityOrBuilder {
private static final long serialVersionUID = 0L;
// Use RetryPriority.newBuilder() to construct.
private RetryPriority(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private RetryPriority() {
name_ = "";
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new RetryPriority();
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RetryPolicy_RetryPriority_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RetryPolicy_RetryPriority_fieldAccessorTable
.ensureFieldAccessorsInitialized(
io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryPriority.class, io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryPriority.Builder.class);
}
private int configTypeCase_ = 0;
@SuppressWarnings("serial")
private java.lang.Object configType_;
public enum ConfigTypeCase
implements com.google.protobuf.Internal.EnumLite,
com.google.protobuf.AbstractMessage.InternalOneOfEnum {
TYPED_CONFIG(3),
CONFIGTYPE_NOT_SET(0);
private final int value;
private ConfigTypeCase(int value) {
this.value = value;
}
/**
* @param value The number of the enum to look for.
* @return The enum associated with the given number.
* @deprecated Use {@link #forNumber(int)} instead.
*/
@java.lang.Deprecated
public static ConfigTypeCase valueOf(int value) {
return forNumber(value);
}
public static ConfigTypeCase forNumber(int value) {
switch (value) {
case 3: return TYPED_CONFIG;
case 0: return CONFIGTYPE_NOT_SET;
default: return null;
}
}
public int getNumber() {
return this.value;
}
};
public ConfigTypeCase
getConfigTypeCase() {
return ConfigTypeCase.forNumber(
configTypeCase_);
}
public static final int NAME_FIELD_NUMBER = 1;
@SuppressWarnings("serial")
private volatile java.lang.Object name_ = "";
/**
* string name = 1 [(.validate.rules) = { ... }
* @return The name.
*/
@java.lang.Override
public java.lang.String getName() {
java.lang.Object ref = name_;
if (ref instanceof java.lang.String) {
return (java.lang.String) ref;
} else {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
name_ = s;
return s;
}
}
/**
* string name = 1 [(.validate.rules) = { ... }
* @return The bytes for name.
*/
@java.lang.Override
public com.google.protobuf.ByteString
getNameBytes() {
java.lang.Object ref = name_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
name_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int TYPED_CONFIG_FIELD_NUMBER = 3;
/**
* .google.protobuf.Any typed_config = 3;
* @return Whether the typedConfig field is set.
*/
@java.lang.Override
public boolean hasTypedConfig() {
return configTypeCase_ == 3;
}
/**
* .google.protobuf.Any typed_config = 3;
* @return The typedConfig.
*/
@java.lang.Override
public com.google.protobuf.Any getTypedConfig() {
if (configTypeCase_ == 3) {
return (com.google.protobuf.Any) configType_;
}
return com.google.protobuf.Any.getDefaultInstance();
}
/**
* .google.protobuf.Any typed_config = 3;
*/
@java.lang.Override
public com.google.protobuf.AnyOrBuilder getTypedConfigOrBuilder() {
if (configTypeCase_ == 3) {
return (com.google.protobuf.Any) configType_;
}
return com.google.protobuf.Any.getDefaultInstance();
}
private byte memoizedIsInitialized = -1;
@java.lang.Override
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
@java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_);
}
if (configTypeCase_ == 3) {
output.writeMessage(3, (com.google.protobuf.Any) configType_);
}
getUnknownFields().writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_);
}
if (configTypeCase_ == 3) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(3, (com.google.protobuf.Any) configType_);
}
size += getUnknownFields().getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryPriority)) {
return super.equals(obj);
}
io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryPriority other = (io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryPriority) obj;
if (!getName()
.equals(other.getName())) return false;
if (!getConfigTypeCase().equals(other.getConfigTypeCase())) return false;
switch (configTypeCase_) {
case 3:
if (!getTypedConfig()
.equals(other.getTypedConfig())) return false;
break;
case 0:
default:
}
if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
hash = (37 * hash) + NAME_FIELD_NUMBER;
hash = (53 * hash) + getName().hashCode();
switch (configTypeCase_) {
case 3:
hash = (37 * hash) + TYPED_CONFIG_FIELD_NUMBER;
hash = (53 * hash) + getTypedConfig().hashCode();
break;
case 0:
default:
}
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryPriority parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryPriority parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryPriority parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryPriority parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryPriority parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryPriority parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryPriority parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryPriority parseFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryPriority parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryPriority parseDelimitedFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryPriority parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryPriority parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
@java.lang.Override
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryPriority prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
@java.lang.Override
public Builder toBuilder() {
return this == DEFAULT_INSTANCE
? new Builder() : new Builder().mergeFrom(this);
}
@java.lang.Override
protected Builder newBuilderForType(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
Builder builder = new Builder(parent);
return builder;
}
/**
* Protobuf type {@code envoy.config.route.v3.RetryPolicy.RetryPriority}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:envoy.config.route.v3.RetryPolicy.RetryPriority)
io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryPriorityOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RetryPolicy_RetryPriority_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RetryPolicy_RetryPriority_fieldAccessorTable
.ensureFieldAccessorsInitialized(
io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryPriority.class, io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryPriority.Builder.class);
}
// Construct using io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryPriority.newBuilder()
private Builder() {
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
}
@java.lang.Override
public Builder clear() {
super.clear();
bitField0_ = 0;
name_ = "";
if (typedConfigBuilder_ != null) {
typedConfigBuilder_.clear();
}
configTypeCase_ = 0;
configType_ = null;
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RetryPolicy_RetryPriority_descriptor;
}
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryPriority getDefaultInstanceForType() {
return io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryPriority.getDefaultInstance();
}
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryPriority build() {
io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryPriority result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryPriority buildPartial() {
io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryPriority result = new io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryPriority(this);
if (bitField0_ != 0) { buildPartial0(result); }
buildPartialOneofs(result);
onBuilt();
return result;
}
private void buildPartial0(io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryPriority result) {
int from_bitField0_ = bitField0_;
if (((from_bitField0_ & 0x00000001) != 0)) {
result.name_ = name_;
}
}
private void buildPartialOneofs(io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryPriority result) {
result.configTypeCase_ = configTypeCase_;
result.configType_ = this.configType_;
if (configTypeCase_ == 3 &&
typedConfigBuilder_ != null) {
result.configType_ = typedConfigBuilder_.build();
}
}
@java.lang.Override
public Builder clone() {
return super.clone();
}
@java.lang.Override
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.setField(field, value);
}
@java.lang.Override
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return super.clearField(field);
}
@java.lang.Override
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return super.clearOneof(oneof);
}
@java.lang.Override
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return super.setRepeatedField(field, index, value);
}
@java.lang.Override
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.addRepeatedField(field, value);
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryPriority) {
return mergeFrom((io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryPriority)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryPriority other) {
if (other == io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryPriority.getDefaultInstance()) return this;
if (!other.getName().isEmpty()) {
name_ = other.name_;
bitField0_ |= 0x00000001;
onChanged();
}
switch (other.getConfigTypeCase()) {
case TYPED_CONFIG: {
mergeTypedConfig(other.getTypedConfig());
break;
}
case CONFIGTYPE_NOT_SET: {
break;
}
}
this.mergeUnknownFields(other.getUnknownFields());
onChanged();
return this;
}
@java.lang.Override
public final boolean isInitialized() {
return true;
}
@java.lang.Override
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
name_ = input.readStringRequireUtf8();
bitField0_ |= 0x00000001;
break;
} // case 10
case 26: {
input.readMessage(
getTypedConfigFieldBuilder().getBuilder(),
extensionRegistry);
configTypeCase_ = 3;
break;
} // case 26
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.unwrapIOException();
} finally {
onChanged();
} // finally
return this;
}
private int configTypeCase_ = 0;
private java.lang.Object configType_;
public ConfigTypeCase
getConfigTypeCase() {
return ConfigTypeCase.forNumber(
configTypeCase_);
}
public Builder clearConfigType() {
configTypeCase_ = 0;
configType_ = null;
onChanged();
return this;
}
private int bitField0_;
private java.lang.Object name_ = "";
/**
* string name = 1 [(.validate.rules) = { ... }
* @return The name.
*/
public java.lang.String getName() {
java.lang.Object ref = name_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
name_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
* string name = 1 [(.validate.rules) = { ... }
* @return The bytes for name.
*/
public com.google.protobuf.ByteString
getNameBytes() {
java.lang.Object ref = name_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
name_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
* string name = 1 [(.validate.rules) = { ... }
* @param value The name to set.
* @return This builder for chaining.
*/
public Builder setName(
java.lang.String value) {
if (value == null) { throw new NullPointerException(); }
name_ = value;
bitField0_ |= 0x00000001;
onChanged();
return this;
}
/**
* string name = 1 [(.validate.rules) = { ... }
* @return This builder for chaining.
*/
public Builder clearName() {
name_ = getDefaultInstance().getName();
bitField0_ = (bitField0_ & ~0x00000001);
onChanged();
return this;
}
/**
* string name = 1 [(.validate.rules) = { ... }
* @param value The bytes for name to set.
* @return This builder for chaining.
*/
public Builder setNameBytes(
com.google.protobuf.ByteString value) {
if (value == null) { throw new NullPointerException(); }
checkByteStringIsUtf8(value);
name_ = value;
bitField0_ |= 0x00000001;
onChanged();
return this;
}
private com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Any, com.google.protobuf.Any.Builder, com.google.protobuf.AnyOrBuilder> typedConfigBuilder_;
/**
* .google.protobuf.Any typed_config = 3;
* @return Whether the typedConfig field is set.
*/
@java.lang.Override
public boolean hasTypedConfig() {
return configTypeCase_ == 3;
}
/**
* .google.protobuf.Any typed_config = 3;
* @return The typedConfig.
*/
@java.lang.Override
public com.google.protobuf.Any getTypedConfig() {
if (typedConfigBuilder_ == null) {
if (configTypeCase_ == 3) {
return (com.google.protobuf.Any) configType_;
}
return com.google.protobuf.Any.getDefaultInstance();
} else {
if (configTypeCase_ == 3) {
return typedConfigBuilder_.getMessage();
}
return com.google.protobuf.Any.getDefaultInstance();
}
}
/**
* .google.protobuf.Any typed_config = 3;
*/
public Builder setTypedConfig(com.google.protobuf.Any value) {
if (typedConfigBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
configType_ = value;
onChanged();
} else {
typedConfigBuilder_.setMessage(value);
}
configTypeCase_ = 3;
return this;
}
/**
* .google.protobuf.Any typed_config = 3;
*/
public Builder setTypedConfig(
com.google.protobuf.Any.Builder builderForValue) {
if (typedConfigBuilder_ == null) {
configType_ = builderForValue.build();
onChanged();
} else {
typedConfigBuilder_.setMessage(builderForValue.build());
}
configTypeCase_ = 3;
return this;
}
/**
* .google.protobuf.Any typed_config = 3;
*/
public Builder mergeTypedConfig(com.google.protobuf.Any value) {
if (typedConfigBuilder_ == null) {
if (configTypeCase_ == 3 &&
configType_ != com.google.protobuf.Any.getDefaultInstance()) {
configType_ = com.google.protobuf.Any.newBuilder((com.google.protobuf.Any) configType_)
.mergeFrom(value).buildPartial();
} else {
configType_ = value;
}
onChanged();
} else {
if (configTypeCase_ == 3) {
typedConfigBuilder_.mergeFrom(value);
} else {
typedConfigBuilder_.setMessage(value);
}
}
configTypeCase_ = 3;
return this;
}
/**
* .google.protobuf.Any typed_config = 3;
*/
public Builder clearTypedConfig() {
if (typedConfigBuilder_ == null) {
if (configTypeCase_ == 3) {
configTypeCase_ = 0;
configType_ = null;
onChanged();
}
} else {
if (configTypeCase_ == 3) {
configTypeCase_ = 0;
configType_ = null;
}
typedConfigBuilder_.clear();
}
return this;
}
/**
* .google.protobuf.Any typed_config = 3;
*/
public com.google.protobuf.Any.Builder getTypedConfigBuilder() {
return getTypedConfigFieldBuilder().getBuilder();
}
/**
* .google.protobuf.Any typed_config = 3;
*/
@java.lang.Override
public com.google.protobuf.AnyOrBuilder getTypedConfigOrBuilder() {
if ((configTypeCase_ == 3) && (typedConfigBuilder_ != null)) {
return typedConfigBuilder_.getMessageOrBuilder();
} else {
if (configTypeCase_ == 3) {
return (com.google.protobuf.Any) configType_;
}
return com.google.protobuf.Any.getDefaultInstance();
}
}
/**
* .google.protobuf.Any typed_config = 3;
*/
private com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Any, com.google.protobuf.Any.Builder, com.google.protobuf.AnyOrBuilder>
getTypedConfigFieldBuilder() {
if (typedConfigBuilder_ == null) {
if (!(configTypeCase_ == 3)) {
configType_ = com.google.protobuf.Any.getDefaultInstance();
}
typedConfigBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Any, com.google.protobuf.Any.Builder, com.google.protobuf.AnyOrBuilder>(
(com.google.protobuf.Any) configType_,
getParentForChildren(),
isClean());
configType_ = null;
}
configTypeCase_ = 3;
onChanged();
return typedConfigBuilder_;
}
@java.lang.Override
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFields(unknownFields);
}
@java.lang.Override
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.mergeUnknownFields(unknownFields);
}
// @@protoc_insertion_point(builder_scope:envoy.config.route.v3.RetryPolicy.RetryPriority)
}
// @@protoc_insertion_point(class_scope:envoy.config.route.v3.RetryPolicy.RetryPriority)
private static final io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryPriority DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryPriority();
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryPriority getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public RetryPriority parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryPriority getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
public interface RetryHostPredicateOrBuilder extends
// @@protoc_insertion_point(interface_extends:envoy.config.route.v3.RetryPolicy.RetryHostPredicate)
com.google.protobuf.MessageOrBuilder {
/**
* string name = 1 [(.validate.rules) = { ... }
* @return The name.
*/
java.lang.String getName();
/**
* string name = 1 [(.validate.rules) = { ... }
* @return The bytes for name.
*/
com.google.protobuf.ByteString
getNameBytes();
/**
* .google.protobuf.Any typed_config = 3;
* @return Whether the typedConfig field is set.
*/
boolean hasTypedConfig();
/**
* .google.protobuf.Any typed_config = 3;
* @return The typedConfig.
*/
com.google.protobuf.Any getTypedConfig();
/**
* .google.protobuf.Any typed_config = 3;
*/
com.google.protobuf.AnyOrBuilder getTypedConfigOrBuilder();
io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicate.ConfigTypeCase getConfigTypeCase();
}
/**
* Protobuf type {@code envoy.config.route.v3.RetryPolicy.RetryHostPredicate}
*/
public static final class RetryHostPredicate extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:envoy.config.route.v3.RetryPolicy.RetryHostPredicate)
RetryHostPredicateOrBuilder {
private static final long serialVersionUID = 0L;
// Use RetryHostPredicate.newBuilder() to construct.
private RetryHostPredicate(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private RetryHostPredicate() {
name_ = "";
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new RetryHostPredicate();
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RetryPolicy_RetryHostPredicate_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RetryPolicy_RetryHostPredicate_fieldAccessorTable
.ensureFieldAccessorsInitialized(
io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicate.class, io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicate.Builder.class);
}
private int configTypeCase_ = 0;
@SuppressWarnings("serial")
private java.lang.Object configType_;
public enum ConfigTypeCase
implements com.google.protobuf.Internal.EnumLite,
com.google.protobuf.AbstractMessage.InternalOneOfEnum {
TYPED_CONFIG(3),
CONFIGTYPE_NOT_SET(0);
private final int value;
private ConfigTypeCase(int value) {
this.value = value;
}
/**
* @param value The number of the enum to look for.
* @return The enum associated with the given number.
* @deprecated Use {@link #forNumber(int)} instead.
*/
@java.lang.Deprecated
public static ConfigTypeCase valueOf(int value) {
return forNumber(value);
}
public static ConfigTypeCase forNumber(int value) {
switch (value) {
case 3: return TYPED_CONFIG;
case 0: return CONFIGTYPE_NOT_SET;
default: return null;
}
}
public int getNumber() {
return this.value;
}
};
public ConfigTypeCase
getConfigTypeCase() {
return ConfigTypeCase.forNumber(
configTypeCase_);
}
public static final int NAME_FIELD_NUMBER = 1;
@SuppressWarnings("serial")
private volatile java.lang.Object name_ = "";
/**
* string name = 1 [(.validate.rules) = { ... }
* @return The name.
*/
@java.lang.Override
public java.lang.String getName() {
java.lang.Object ref = name_;
if (ref instanceof java.lang.String) {
return (java.lang.String) ref;
} else {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
name_ = s;
return s;
}
}
/**
* string name = 1 [(.validate.rules) = { ... }
* @return The bytes for name.
*/
@java.lang.Override
public com.google.protobuf.ByteString
getNameBytes() {
java.lang.Object ref = name_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
name_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int TYPED_CONFIG_FIELD_NUMBER = 3;
/**
* .google.protobuf.Any typed_config = 3;
* @return Whether the typedConfig field is set.
*/
@java.lang.Override
public boolean hasTypedConfig() {
return configTypeCase_ == 3;
}
/**
* .google.protobuf.Any typed_config = 3;
* @return The typedConfig.
*/
@java.lang.Override
public com.google.protobuf.Any getTypedConfig() {
if (configTypeCase_ == 3) {
return (com.google.protobuf.Any) configType_;
}
return com.google.protobuf.Any.getDefaultInstance();
}
/**
* .google.protobuf.Any typed_config = 3;
*/
@java.lang.Override
public com.google.protobuf.AnyOrBuilder getTypedConfigOrBuilder() {
if (configTypeCase_ == 3) {
return (com.google.protobuf.Any) configType_;
}
return com.google.protobuf.Any.getDefaultInstance();
}
private byte memoizedIsInitialized = -1;
@java.lang.Override
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
@java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_);
}
if (configTypeCase_ == 3) {
output.writeMessage(3, (com.google.protobuf.Any) configType_);
}
getUnknownFields().writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_);
}
if (configTypeCase_ == 3) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(3, (com.google.protobuf.Any) configType_);
}
size += getUnknownFields().getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicate)) {
return super.equals(obj);
}
io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicate other = (io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicate) obj;
if (!getName()
.equals(other.getName())) return false;
if (!getConfigTypeCase().equals(other.getConfigTypeCase())) return false;
switch (configTypeCase_) {
case 3:
if (!getTypedConfig()
.equals(other.getTypedConfig())) return false;
break;
case 0:
default:
}
if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
hash = (37 * hash) + NAME_FIELD_NUMBER;
hash = (53 * hash) + getName().hashCode();
switch (configTypeCase_) {
case 3:
hash = (37 * hash) + TYPED_CONFIG_FIELD_NUMBER;
hash = (53 * hash) + getTypedConfig().hashCode();
break;
case 0:
default:
}
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicate parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicate parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicate parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicate parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicate parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicate parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicate parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicate parseFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicate parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicate parseDelimitedFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicate parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicate parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
@java.lang.Override
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicate prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
@java.lang.Override
public Builder toBuilder() {
return this == DEFAULT_INSTANCE
? new Builder() : new Builder().mergeFrom(this);
}
@java.lang.Override
protected Builder newBuilderForType(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
Builder builder = new Builder(parent);
return builder;
}
/**
* Protobuf type {@code envoy.config.route.v3.RetryPolicy.RetryHostPredicate}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:envoy.config.route.v3.RetryPolicy.RetryHostPredicate)
io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicateOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RetryPolicy_RetryHostPredicate_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RetryPolicy_RetryHostPredicate_fieldAccessorTable
.ensureFieldAccessorsInitialized(
io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicate.class, io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicate.Builder.class);
}
// Construct using io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicate.newBuilder()
private Builder() {
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
}
@java.lang.Override
public Builder clear() {
super.clear();
bitField0_ = 0;
name_ = "";
if (typedConfigBuilder_ != null) {
typedConfigBuilder_.clear();
}
configTypeCase_ = 0;
configType_ = null;
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RetryPolicy_RetryHostPredicate_descriptor;
}
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicate getDefaultInstanceForType() {
return io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicate.getDefaultInstance();
}
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicate build() {
io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicate result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicate buildPartial() {
io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicate result = new io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicate(this);
if (bitField0_ != 0) { buildPartial0(result); }
buildPartialOneofs(result);
onBuilt();
return result;
}
private void buildPartial0(io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicate result) {
int from_bitField0_ = bitField0_;
if (((from_bitField0_ & 0x00000001) != 0)) {
result.name_ = name_;
}
}
private void buildPartialOneofs(io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicate result) {
result.configTypeCase_ = configTypeCase_;
result.configType_ = this.configType_;
if (configTypeCase_ == 3 &&
typedConfigBuilder_ != null) {
result.configType_ = typedConfigBuilder_.build();
}
}
@java.lang.Override
public Builder clone() {
return super.clone();
}
@java.lang.Override
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.setField(field, value);
}
@java.lang.Override
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return super.clearField(field);
}
@java.lang.Override
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return super.clearOneof(oneof);
}
@java.lang.Override
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return super.setRepeatedField(field, index, value);
}
@java.lang.Override
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.addRepeatedField(field, value);
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicate) {
return mergeFrom((io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicate)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicate other) {
if (other == io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicate.getDefaultInstance()) return this;
if (!other.getName().isEmpty()) {
name_ = other.name_;
bitField0_ |= 0x00000001;
onChanged();
}
switch (other.getConfigTypeCase()) {
case TYPED_CONFIG: {
mergeTypedConfig(other.getTypedConfig());
break;
}
case CONFIGTYPE_NOT_SET: {
break;
}
}
this.mergeUnknownFields(other.getUnknownFields());
onChanged();
return this;
}
@java.lang.Override
public final boolean isInitialized() {
return true;
}
@java.lang.Override
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
name_ = input.readStringRequireUtf8();
bitField0_ |= 0x00000001;
break;
} // case 10
case 26: {
input.readMessage(
getTypedConfigFieldBuilder().getBuilder(),
extensionRegistry);
configTypeCase_ = 3;
break;
} // case 26
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.unwrapIOException();
} finally {
onChanged();
} // finally
return this;
}
private int configTypeCase_ = 0;
private java.lang.Object configType_;
public ConfigTypeCase
getConfigTypeCase() {
return ConfigTypeCase.forNumber(
configTypeCase_);
}
public Builder clearConfigType() {
configTypeCase_ = 0;
configType_ = null;
onChanged();
return this;
}
private int bitField0_;
private java.lang.Object name_ = "";
/**
* string name = 1 [(.validate.rules) = { ... }
* @return The name.
*/
public java.lang.String getName() {
java.lang.Object ref = name_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
name_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
* string name = 1 [(.validate.rules) = { ... }
* @return The bytes for name.
*/
public com.google.protobuf.ByteString
getNameBytes() {
java.lang.Object ref = name_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
name_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
* string name = 1 [(.validate.rules) = { ... }
* @param value The name to set.
* @return This builder for chaining.
*/
public Builder setName(
java.lang.String value) {
if (value == null) { throw new NullPointerException(); }
name_ = value;
bitField0_ |= 0x00000001;
onChanged();
return this;
}
/**
* string name = 1 [(.validate.rules) = { ... }
* @return This builder for chaining.
*/
public Builder clearName() {
name_ = getDefaultInstance().getName();
bitField0_ = (bitField0_ & ~0x00000001);
onChanged();
return this;
}
/**
* string name = 1 [(.validate.rules) = { ... }
* @param value The bytes for name to set.
* @return This builder for chaining.
*/
public Builder setNameBytes(
com.google.protobuf.ByteString value) {
if (value == null) { throw new NullPointerException(); }
checkByteStringIsUtf8(value);
name_ = value;
bitField0_ |= 0x00000001;
onChanged();
return this;
}
private com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Any, com.google.protobuf.Any.Builder, com.google.protobuf.AnyOrBuilder> typedConfigBuilder_;
/**
* .google.protobuf.Any typed_config = 3;
* @return Whether the typedConfig field is set.
*/
@java.lang.Override
public boolean hasTypedConfig() {
return configTypeCase_ == 3;
}
/**
* .google.protobuf.Any typed_config = 3;
* @return The typedConfig.
*/
@java.lang.Override
public com.google.protobuf.Any getTypedConfig() {
if (typedConfigBuilder_ == null) {
if (configTypeCase_ == 3) {
return (com.google.protobuf.Any) configType_;
}
return com.google.protobuf.Any.getDefaultInstance();
} else {
if (configTypeCase_ == 3) {
return typedConfigBuilder_.getMessage();
}
return com.google.protobuf.Any.getDefaultInstance();
}
}
/**
* .google.protobuf.Any typed_config = 3;
*/
public Builder setTypedConfig(com.google.protobuf.Any value) {
if (typedConfigBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
configType_ = value;
onChanged();
} else {
typedConfigBuilder_.setMessage(value);
}
configTypeCase_ = 3;
return this;
}
/**
* .google.protobuf.Any typed_config = 3;
*/
public Builder setTypedConfig(
com.google.protobuf.Any.Builder builderForValue) {
if (typedConfigBuilder_ == null) {
configType_ = builderForValue.build();
onChanged();
} else {
typedConfigBuilder_.setMessage(builderForValue.build());
}
configTypeCase_ = 3;
return this;
}
/**
* .google.protobuf.Any typed_config = 3;
*/
public Builder mergeTypedConfig(com.google.protobuf.Any value) {
if (typedConfigBuilder_ == null) {
if (configTypeCase_ == 3 &&
configType_ != com.google.protobuf.Any.getDefaultInstance()) {
configType_ = com.google.protobuf.Any.newBuilder((com.google.protobuf.Any) configType_)
.mergeFrom(value).buildPartial();
} else {
configType_ = value;
}
onChanged();
} else {
if (configTypeCase_ == 3) {
typedConfigBuilder_.mergeFrom(value);
} else {
typedConfigBuilder_.setMessage(value);
}
}
configTypeCase_ = 3;
return this;
}
/**
* .google.protobuf.Any typed_config = 3;
*/
public Builder clearTypedConfig() {
if (typedConfigBuilder_ == null) {
if (configTypeCase_ == 3) {
configTypeCase_ = 0;
configType_ = null;
onChanged();
}
} else {
if (configTypeCase_ == 3) {
configTypeCase_ = 0;
configType_ = null;
}
typedConfigBuilder_.clear();
}
return this;
}
/**
* .google.protobuf.Any typed_config = 3;
*/
public com.google.protobuf.Any.Builder getTypedConfigBuilder() {
return getTypedConfigFieldBuilder().getBuilder();
}
/**
* .google.protobuf.Any typed_config = 3;
*/
@java.lang.Override
public com.google.protobuf.AnyOrBuilder getTypedConfigOrBuilder() {
if ((configTypeCase_ == 3) && (typedConfigBuilder_ != null)) {
return typedConfigBuilder_.getMessageOrBuilder();
} else {
if (configTypeCase_ == 3) {
return (com.google.protobuf.Any) configType_;
}
return com.google.protobuf.Any.getDefaultInstance();
}
}
/**
* .google.protobuf.Any typed_config = 3;
*/
private com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Any, com.google.protobuf.Any.Builder, com.google.protobuf.AnyOrBuilder>
getTypedConfigFieldBuilder() {
if (typedConfigBuilder_ == null) {
if (!(configTypeCase_ == 3)) {
configType_ = com.google.protobuf.Any.getDefaultInstance();
}
typedConfigBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Any, com.google.protobuf.Any.Builder, com.google.protobuf.AnyOrBuilder>(
(com.google.protobuf.Any) configType_,
getParentForChildren(),
isClean());
configType_ = null;
}
configTypeCase_ = 3;
onChanged();
return typedConfigBuilder_;
}
@java.lang.Override
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFields(unknownFields);
}
@java.lang.Override
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.mergeUnknownFields(unknownFields);
}
// @@protoc_insertion_point(builder_scope:envoy.config.route.v3.RetryPolicy.RetryHostPredicate)
}
// @@protoc_insertion_point(class_scope:envoy.config.route.v3.RetryPolicy.RetryHostPredicate)
private static final io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicate DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicate();
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicate getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public RetryHostPredicate parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicate getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
public interface RetryBackOffOrBuilder extends
// @@protoc_insertion_point(interface_extends:envoy.config.route.v3.RetryPolicy.RetryBackOff)
com.google.protobuf.MessageOrBuilder {
/**
*
* Specifies the base interval between retries. This parameter is required and must be greater
* than zero. Values less than 1 ms are rounded up to 1 ms.
* See :ref:`config_http_filters_router_x-envoy-max-retries` for a discussion of Envoy's
* back-off algorithm.
*
*
* .google.protobuf.Duration base_interval = 1 [(.validate.rules) = { ... }
* @return Whether the baseInterval field is set.
*/
boolean hasBaseInterval();
/**
*
* Specifies the base interval between retries. This parameter is required and must be greater
* than zero. Values less than 1 ms are rounded up to 1 ms.
* See :ref:`config_http_filters_router_x-envoy-max-retries` for a discussion of Envoy's
* back-off algorithm.
*
*
* .google.protobuf.Duration base_interval = 1 [(.validate.rules) = { ... }
* @return The baseInterval.
*/
com.google.protobuf.Duration getBaseInterval();
/**
*
* Specifies the base interval between retries. This parameter is required and must be greater
* than zero. Values less than 1 ms are rounded up to 1 ms.
* See :ref:`config_http_filters_router_x-envoy-max-retries` for a discussion of Envoy's
* back-off algorithm.
*
*
* .google.protobuf.Duration base_interval = 1 [(.validate.rules) = { ... }
*/
com.google.protobuf.DurationOrBuilder getBaseIntervalOrBuilder();
/**
*
* Specifies the maximum interval between retries. This parameter is optional, but must be
* greater than or equal to the ``base_interval`` if set. The default is 10 times the
* ``base_interval``. See :ref:`config_http_filters_router_x-envoy-max-retries` for a discussion
* of Envoy's back-off algorithm.
*
*
* .google.protobuf.Duration max_interval = 2 [(.validate.rules) = { ... }
* @return Whether the maxInterval field is set.
*/
boolean hasMaxInterval();
/**
*
* Specifies the maximum interval between retries. This parameter is optional, but must be
* greater than or equal to the ``base_interval`` if set. The default is 10 times the
* ``base_interval``. See :ref:`config_http_filters_router_x-envoy-max-retries` for a discussion
* of Envoy's back-off algorithm.
*
*
* .google.protobuf.Duration max_interval = 2 [(.validate.rules) = { ... }
* @return The maxInterval.
*/
com.google.protobuf.Duration getMaxInterval();
/**
*
* Specifies the maximum interval between retries. This parameter is optional, but must be
* greater than or equal to the ``base_interval`` if set. The default is 10 times the
* ``base_interval``. See :ref:`config_http_filters_router_x-envoy-max-retries` for a discussion
* of Envoy's back-off algorithm.
*
*
* .google.protobuf.Duration max_interval = 2 [(.validate.rules) = { ... }
*/
com.google.protobuf.DurationOrBuilder getMaxIntervalOrBuilder();
}
/**
* Protobuf type {@code envoy.config.route.v3.RetryPolicy.RetryBackOff}
*/
public static final class RetryBackOff extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:envoy.config.route.v3.RetryPolicy.RetryBackOff)
RetryBackOffOrBuilder {
private static final long serialVersionUID = 0L;
// Use RetryBackOff.newBuilder() to construct.
private RetryBackOff(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private RetryBackOff() {
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new RetryBackOff();
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RetryPolicy_RetryBackOff_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RetryPolicy_RetryBackOff_fieldAccessorTable
.ensureFieldAccessorsInitialized(
io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryBackOff.class, io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryBackOff.Builder.class);
}
private int bitField0_;
public static final int BASE_INTERVAL_FIELD_NUMBER = 1;
private com.google.protobuf.Duration baseInterval_;
/**
*
* Specifies the base interval between retries. This parameter is required and must be greater
* than zero. Values less than 1 ms are rounded up to 1 ms.
* See :ref:`config_http_filters_router_x-envoy-max-retries` for a discussion of Envoy's
* back-off algorithm.
*
*
* .google.protobuf.Duration base_interval = 1 [(.validate.rules) = { ... }
* @return Whether the baseInterval field is set.
*/
@java.lang.Override
public boolean hasBaseInterval() {
return ((bitField0_ & 0x00000001) != 0);
}
/**
*
* Specifies the base interval between retries. This parameter is required and must be greater
* than zero. Values less than 1 ms are rounded up to 1 ms.
* See :ref:`config_http_filters_router_x-envoy-max-retries` for a discussion of Envoy's
* back-off algorithm.
*
*
* .google.protobuf.Duration base_interval = 1 [(.validate.rules) = { ... }
* @return The baseInterval.
*/
@java.lang.Override
public com.google.protobuf.Duration getBaseInterval() {
return baseInterval_ == null ? com.google.protobuf.Duration.getDefaultInstance() : baseInterval_;
}
/**
*
* Specifies the base interval between retries. This parameter is required and must be greater
* than zero. Values less than 1 ms are rounded up to 1 ms.
* See :ref:`config_http_filters_router_x-envoy-max-retries` for a discussion of Envoy's
* back-off algorithm.
*
*
* .google.protobuf.Duration base_interval = 1 [(.validate.rules) = { ... }
*/
@java.lang.Override
public com.google.protobuf.DurationOrBuilder getBaseIntervalOrBuilder() {
return baseInterval_ == null ? com.google.protobuf.Duration.getDefaultInstance() : baseInterval_;
}
public static final int MAX_INTERVAL_FIELD_NUMBER = 2;
private com.google.protobuf.Duration maxInterval_;
/**
*
* Specifies the maximum interval between retries. This parameter is optional, but must be
* greater than or equal to the ``base_interval`` if set. The default is 10 times the
* ``base_interval``. See :ref:`config_http_filters_router_x-envoy-max-retries` for a discussion
* of Envoy's back-off algorithm.
*
*
* .google.protobuf.Duration max_interval = 2 [(.validate.rules) = { ... }
* @return Whether the maxInterval field is set.
*/
@java.lang.Override
public boolean hasMaxInterval() {
return ((bitField0_ & 0x00000002) != 0);
}
/**
*
* Specifies the maximum interval between retries. This parameter is optional, but must be
* greater than or equal to the ``base_interval`` if set. The default is 10 times the
* ``base_interval``. See :ref:`config_http_filters_router_x-envoy-max-retries` for a discussion
* of Envoy's back-off algorithm.
*
*
* .google.protobuf.Duration max_interval = 2 [(.validate.rules) = { ... }
* @return The maxInterval.
*/
@java.lang.Override
public com.google.protobuf.Duration getMaxInterval() {
return maxInterval_ == null ? com.google.protobuf.Duration.getDefaultInstance() : maxInterval_;
}
/**
*
* Specifies the maximum interval between retries. This parameter is optional, but must be
* greater than or equal to the ``base_interval`` if set. The default is 10 times the
* ``base_interval``. See :ref:`config_http_filters_router_x-envoy-max-retries` for a discussion
* of Envoy's back-off algorithm.
*
*
* .google.protobuf.Duration max_interval = 2 [(.validate.rules) = { ... }
*/
@java.lang.Override
public com.google.protobuf.DurationOrBuilder getMaxIntervalOrBuilder() {
return maxInterval_ == null ? com.google.protobuf.Duration.getDefaultInstance() : maxInterval_;
}
private byte memoizedIsInitialized = -1;
@java.lang.Override
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
@java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
if (((bitField0_ & 0x00000001) != 0)) {
output.writeMessage(1, getBaseInterval());
}
if (((bitField0_ & 0x00000002) != 0)) {
output.writeMessage(2, getMaxInterval());
}
getUnknownFields().writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (((bitField0_ & 0x00000001) != 0)) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(1, getBaseInterval());
}
if (((bitField0_ & 0x00000002) != 0)) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(2, getMaxInterval());
}
size += getUnknownFields().getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryBackOff)) {
return super.equals(obj);
}
io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryBackOff other = (io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryBackOff) obj;
if (hasBaseInterval() != other.hasBaseInterval()) return false;
if (hasBaseInterval()) {
if (!getBaseInterval()
.equals(other.getBaseInterval())) return false;
}
if (hasMaxInterval() != other.hasMaxInterval()) return false;
if (hasMaxInterval()) {
if (!getMaxInterval()
.equals(other.getMaxInterval())) return false;
}
if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
if (hasBaseInterval()) {
hash = (37 * hash) + BASE_INTERVAL_FIELD_NUMBER;
hash = (53 * hash) + getBaseInterval().hashCode();
}
if (hasMaxInterval()) {
hash = (37 * hash) + MAX_INTERVAL_FIELD_NUMBER;
hash = (53 * hash) + getMaxInterval().hashCode();
}
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryBackOff parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryBackOff parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryBackOff parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryBackOff parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryBackOff parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryBackOff parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryBackOff parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryBackOff parseFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryBackOff parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryBackOff parseDelimitedFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryBackOff parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryBackOff parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
@java.lang.Override
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryBackOff prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
@java.lang.Override
public Builder toBuilder() {
return this == DEFAULT_INSTANCE
? new Builder() : new Builder().mergeFrom(this);
}
@java.lang.Override
protected Builder newBuilderForType(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
Builder builder = new Builder(parent);
return builder;
}
/**
* Protobuf type {@code envoy.config.route.v3.RetryPolicy.RetryBackOff}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:envoy.config.route.v3.RetryPolicy.RetryBackOff)
io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryBackOffOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RetryPolicy_RetryBackOff_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RetryPolicy_RetryBackOff_fieldAccessorTable
.ensureFieldAccessorsInitialized(
io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryBackOff.class, io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryBackOff.Builder.class);
}
// Construct using io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryBackOff.newBuilder()
private Builder() {
maybeForceBuilderInitialization();
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (com.google.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
getBaseIntervalFieldBuilder();
getMaxIntervalFieldBuilder();
}
}
@java.lang.Override
public Builder clear() {
super.clear();
bitField0_ = 0;
baseInterval_ = null;
if (baseIntervalBuilder_ != null) {
baseIntervalBuilder_.dispose();
baseIntervalBuilder_ = null;
}
maxInterval_ = null;
if (maxIntervalBuilder_ != null) {
maxIntervalBuilder_.dispose();
maxIntervalBuilder_ = null;
}
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RetryPolicy_RetryBackOff_descriptor;
}
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryBackOff getDefaultInstanceForType() {
return io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryBackOff.getDefaultInstance();
}
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryBackOff build() {
io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryBackOff result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryBackOff buildPartial() {
io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryBackOff result = new io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryBackOff(this);
if (bitField0_ != 0) { buildPartial0(result); }
onBuilt();
return result;
}
private void buildPartial0(io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryBackOff result) {
int from_bitField0_ = bitField0_;
int to_bitField0_ = 0;
if (((from_bitField0_ & 0x00000001) != 0)) {
result.baseInterval_ = baseIntervalBuilder_ == null
? baseInterval_
: baseIntervalBuilder_.build();
to_bitField0_ |= 0x00000001;
}
if (((from_bitField0_ & 0x00000002) != 0)) {
result.maxInterval_ = maxIntervalBuilder_ == null
? maxInterval_
: maxIntervalBuilder_.build();
to_bitField0_ |= 0x00000002;
}
result.bitField0_ |= to_bitField0_;
}
@java.lang.Override
public Builder clone() {
return super.clone();
}
@java.lang.Override
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.setField(field, value);
}
@java.lang.Override
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return super.clearField(field);
}
@java.lang.Override
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return super.clearOneof(oneof);
}
@java.lang.Override
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return super.setRepeatedField(field, index, value);
}
@java.lang.Override
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.addRepeatedField(field, value);
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryBackOff) {
return mergeFrom((io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryBackOff)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryBackOff other) {
if (other == io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryBackOff.getDefaultInstance()) return this;
if (other.hasBaseInterval()) {
mergeBaseInterval(other.getBaseInterval());
}
if (other.hasMaxInterval()) {
mergeMaxInterval(other.getMaxInterval());
}
this.mergeUnknownFields(other.getUnknownFields());
onChanged();
return this;
}
@java.lang.Override
public final boolean isInitialized() {
return true;
}
@java.lang.Override
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
input.readMessage(
getBaseIntervalFieldBuilder().getBuilder(),
extensionRegistry);
bitField0_ |= 0x00000001;
break;
} // case 10
case 18: {
input.readMessage(
getMaxIntervalFieldBuilder().getBuilder(),
extensionRegistry);
bitField0_ |= 0x00000002;
break;
} // case 18
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.unwrapIOException();
} finally {
onChanged();
} // finally
return this;
}
private int bitField0_;
private com.google.protobuf.Duration baseInterval_;
private com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Duration, com.google.protobuf.Duration.Builder, com.google.protobuf.DurationOrBuilder> baseIntervalBuilder_;
/**
*
* Specifies the base interval between retries. This parameter is required and must be greater
* than zero. Values less than 1 ms are rounded up to 1 ms.
* See :ref:`config_http_filters_router_x-envoy-max-retries` for a discussion of Envoy's
* back-off algorithm.
*
*
* .google.protobuf.Duration base_interval = 1 [(.validate.rules) = { ... }
* @return Whether the baseInterval field is set.
*/
public boolean hasBaseInterval() {
return ((bitField0_ & 0x00000001) != 0);
}
/**
*
* Specifies the base interval between retries. This parameter is required and must be greater
* than zero. Values less than 1 ms are rounded up to 1 ms.
* See :ref:`config_http_filters_router_x-envoy-max-retries` for a discussion of Envoy's
* back-off algorithm.
*
*
* .google.protobuf.Duration base_interval = 1 [(.validate.rules) = { ... }
* @return The baseInterval.
*/
public com.google.protobuf.Duration getBaseInterval() {
if (baseIntervalBuilder_ == null) {
return baseInterval_ == null ? com.google.protobuf.Duration.getDefaultInstance() : baseInterval_;
} else {
return baseIntervalBuilder_.getMessage();
}
}
/**
*
* Specifies the base interval between retries. This parameter is required and must be greater
* than zero. Values less than 1 ms are rounded up to 1 ms.
* See :ref:`config_http_filters_router_x-envoy-max-retries` for a discussion of Envoy's
* back-off algorithm.
*
*
* .google.protobuf.Duration base_interval = 1 [(.validate.rules) = { ... }
*/
public Builder setBaseInterval(com.google.protobuf.Duration value) {
if (baseIntervalBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
baseInterval_ = value;
} else {
baseIntervalBuilder_.setMessage(value);
}
bitField0_ |= 0x00000001;
onChanged();
return this;
}
/**
*
* Specifies the base interval between retries. This parameter is required and must be greater
* than zero. Values less than 1 ms are rounded up to 1 ms.
* See :ref:`config_http_filters_router_x-envoy-max-retries` for a discussion of Envoy's
* back-off algorithm.
*
*
* .google.protobuf.Duration base_interval = 1 [(.validate.rules) = { ... }
*/
public Builder setBaseInterval(
com.google.protobuf.Duration.Builder builderForValue) {
if (baseIntervalBuilder_ == null) {
baseInterval_ = builderForValue.build();
} else {
baseIntervalBuilder_.setMessage(builderForValue.build());
}
bitField0_ |= 0x00000001;
onChanged();
return this;
}
/**
*
* Specifies the base interval between retries. This parameter is required and must be greater
* than zero. Values less than 1 ms are rounded up to 1 ms.
* See :ref:`config_http_filters_router_x-envoy-max-retries` for a discussion of Envoy's
* back-off algorithm.
*
*
* .google.protobuf.Duration base_interval = 1 [(.validate.rules) = { ... }
*/
public Builder mergeBaseInterval(com.google.protobuf.Duration value) {
if (baseIntervalBuilder_ == null) {
if (((bitField0_ & 0x00000001) != 0) &&
baseInterval_ != null &&
baseInterval_ != com.google.protobuf.Duration.getDefaultInstance()) {
getBaseIntervalBuilder().mergeFrom(value);
} else {
baseInterval_ = value;
}
} else {
baseIntervalBuilder_.mergeFrom(value);
}
if (baseInterval_ != null) {
bitField0_ |= 0x00000001;
onChanged();
}
return this;
}
/**
*
* Specifies the base interval between retries. This parameter is required and must be greater
* than zero. Values less than 1 ms are rounded up to 1 ms.
* See :ref:`config_http_filters_router_x-envoy-max-retries` for a discussion of Envoy's
* back-off algorithm.
*
*
* .google.protobuf.Duration base_interval = 1 [(.validate.rules) = { ... }
*/
public Builder clearBaseInterval() {
bitField0_ = (bitField0_ & ~0x00000001);
baseInterval_ = null;
if (baseIntervalBuilder_ != null) {
baseIntervalBuilder_.dispose();
baseIntervalBuilder_ = null;
}
onChanged();
return this;
}
/**
*
* Specifies the base interval between retries. This parameter is required and must be greater
* than zero. Values less than 1 ms are rounded up to 1 ms.
* See :ref:`config_http_filters_router_x-envoy-max-retries` for a discussion of Envoy's
* back-off algorithm.
*
*
* .google.protobuf.Duration base_interval = 1 [(.validate.rules) = { ... }
*/
public com.google.protobuf.Duration.Builder getBaseIntervalBuilder() {
bitField0_ |= 0x00000001;
onChanged();
return getBaseIntervalFieldBuilder().getBuilder();
}
/**
*
* Specifies the base interval between retries. This parameter is required and must be greater
* than zero. Values less than 1 ms are rounded up to 1 ms.
* See :ref:`config_http_filters_router_x-envoy-max-retries` for a discussion of Envoy's
* back-off algorithm.
*
*
* .google.protobuf.Duration base_interval = 1 [(.validate.rules) = { ... }
*/
public com.google.protobuf.DurationOrBuilder getBaseIntervalOrBuilder() {
if (baseIntervalBuilder_ != null) {
return baseIntervalBuilder_.getMessageOrBuilder();
} else {
return baseInterval_ == null ?
com.google.protobuf.Duration.getDefaultInstance() : baseInterval_;
}
}
/**
*
* Specifies the base interval between retries. This parameter is required and must be greater
* than zero. Values less than 1 ms are rounded up to 1 ms.
* See :ref:`config_http_filters_router_x-envoy-max-retries` for a discussion of Envoy's
* back-off algorithm.
*
*
* .google.protobuf.Duration base_interval = 1 [(.validate.rules) = { ... }
*/
private com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Duration, com.google.protobuf.Duration.Builder, com.google.protobuf.DurationOrBuilder>
getBaseIntervalFieldBuilder() {
if (baseIntervalBuilder_ == null) {
baseIntervalBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Duration, com.google.protobuf.Duration.Builder, com.google.protobuf.DurationOrBuilder>(
getBaseInterval(),
getParentForChildren(),
isClean());
baseInterval_ = null;
}
return baseIntervalBuilder_;
}
private com.google.protobuf.Duration maxInterval_;
private com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Duration, com.google.protobuf.Duration.Builder, com.google.protobuf.DurationOrBuilder> maxIntervalBuilder_;
/**
*
* Specifies the maximum interval between retries. This parameter is optional, but must be
* greater than or equal to the ``base_interval`` if set. The default is 10 times the
* ``base_interval``. See :ref:`config_http_filters_router_x-envoy-max-retries` for a discussion
* of Envoy's back-off algorithm.
*
*
* .google.protobuf.Duration max_interval = 2 [(.validate.rules) = { ... }
* @return Whether the maxInterval field is set.
*/
public boolean hasMaxInterval() {
return ((bitField0_ & 0x00000002) != 0);
}
/**
*
* Specifies the maximum interval between retries. This parameter is optional, but must be
* greater than or equal to the ``base_interval`` if set. The default is 10 times the
* ``base_interval``. See :ref:`config_http_filters_router_x-envoy-max-retries` for a discussion
* of Envoy's back-off algorithm.
*
*
* .google.protobuf.Duration max_interval = 2 [(.validate.rules) = { ... }
* @return The maxInterval.
*/
public com.google.protobuf.Duration getMaxInterval() {
if (maxIntervalBuilder_ == null) {
return maxInterval_ == null ? com.google.protobuf.Duration.getDefaultInstance() : maxInterval_;
} else {
return maxIntervalBuilder_.getMessage();
}
}
/**
*
* Specifies the maximum interval between retries. This parameter is optional, but must be
* greater than or equal to the ``base_interval`` if set. The default is 10 times the
* ``base_interval``. See :ref:`config_http_filters_router_x-envoy-max-retries` for a discussion
* of Envoy's back-off algorithm.
*
*
* .google.protobuf.Duration max_interval = 2 [(.validate.rules) = { ... }
*/
public Builder setMaxInterval(com.google.protobuf.Duration value) {
if (maxIntervalBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
maxInterval_ = value;
} else {
maxIntervalBuilder_.setMessage(value);
}
bitField0_ |= 0x00000002;
onChanged();
return this;
}
/**
*
* Specifies the maximum interval between retries. This parameter is optional, but must be
* greater than or equal to the ``base_interval`` if set. The default is 10 times the
* ``base_interval``. See :ref:`config_http_filters_router_x-envoy-max-retries` for a discussion
* of Envoy's back-off algorithm.
*
*
* .google.protobuf.Duration max_interval = 2 [(.validate.rules) = { ... }
*/
public Builder setMaxInterval(
com.google.protobuf.Duration.Builder builderForValue) {
if (maxIntervalBuilder_ == null) {
maxInterval_ = builderForValue.build();
} else {
maxIntervalBuilder_.setMessage(builderForValue.build());
}
bitField0_ |= 0x00000002;
onChanged();
return this;
}
/**
*
* Specifies the maximum interval between retries. This parameter is optional, but must be
* greater than or equal to the ``base_interval`` if set. The default is 10 times the
* ``base_interval``. See :ref:`config_http_filters_router_x-envoy-max-retries` for a discussion
* of Envoy's back-off algorithm.
*
*
* .google.protobuf.Duration max_interval = 2 [(.validate.rules) = { ... }
*/
public Builder mergeMaxInterval(com.google.protobuf.Duration value) {
if (maxIntervalBuilder_ == null) {
if (((bitField0_ & 0x00000002) != 0) &&
maxInterval_ != null &&
maxInterval_ != com.google.protobuf.Duration.getDefaultInstance()) {
getMaxIntervalBuilder().mergeFrom(value);
} else {
maxInterval_ = value;
}
} else {
maxIntervalBuilder_.mergeFrom(value);
}
if (maxInterval_ != null) {
bitField0_ |= 0x00000002;
onChanged();
}
return this;
}
/**
*
* Specifies the maximum interval between retries. This parameter is optional, but must be
* greater than or equal to the ``base_interval`` if set. The default is 10 times the
* ``base_interval``. See :ref:`config_http_filters_router_x-envoy-max-retries` for a discussion
* of Envoy's back-off algorithm.
*
*
* .google.protobuf.Duration max_interval = 2 [(.validate.rules) = { ... }
*/
public Builder clearMaxInterval() {
bitField0_ = (bitField0_ & ~0x00000002);
maxInterval_ = null;
if (maxIntervalBuilder_ != null) {
maxIntervalBuilder_.dispose();
maxIntervalBuilder_ = null;
}
onChanged();
return this;
}
/**
*
* Specifies the maximum interval between retries. This parameter is optional, but must be
* greater than or equal to the ``base_interval`` if set. The default is 10 times the
* ``base_interval``. See :ref:`config_http_filters_router_x-envoy-max-retries` for a discussion
* of Envoy's back-off algorithm.
*
*
* .google.protobuf.Duration max_interval = 2 [(.validate.rules) = { ... }
*/
public com.google.protobuf.Duration.Builder getMaxIntervalBuilder() {
bitField0_ |= 0x00000002;
onChanged();
return getMaxIntervalFieldBuilder().getBuilder();
}
/**
*
* Specifies the maximum interval between retries. This parameter is optional, but must be
* greater than or equal to the ``base_interval`` if set. The default is 10 times the
* ``base_interval``. See :ref:`config_http_filters_router_x-envoy-max-retries` for a discussion
* of Envoy's back-off algorithm.
*
*
* .google.protobuf.Duration max_interval = 2 [(.validate.rules) = { ... }
*/
public com.google.protobuf.DurationOrBuilder getMaxIntervalOrBuilder() {
if (maxIntervalBuilder_ != null) {
return maxIntervalBuilder_.getMessageOrBuilder();
} else {
return maxInterval_ == null ?
com.google.protobuf.Duration.getDefaultInstance() : maxInterval_;
}
}
/**
*
* Specifies the maximum interval between retries. This parameter is optional, but must be
* greater than or equal to the ``base_interval`` if set. The default is 10 times the
* ``base_interval``. See :ref:`config_http_filters_router_x-envoy-max-retries` for a discussion
* of Envoy's back-off algorithm.
*
*
* .google.protobuf.Duration max_interval = 2 [(.validate.rules) = { ... }
*/
private com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Duration, com.google.protobuf.Duration.Builder, com.google.protobuf.DurationOrBuilder>
getMaxIntervalFieldBuilder() {
if (maxIntervalBuilder_ == null) {
maxIntervalBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Duration, com.google.protobuf.Duration.Builder, com.google.protobuf.DurationOrBuilder>(
getMaxInterval(),
getParentForChildren(),
isClean());
maxInterval_ = null;
}
return maxIntervalBuilder_;
}
@java.lang.Override
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFields(unknownFields);
}
@java.lang.Override
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.mergeUnknownFields(unknownFields);
}
// @@protoc_insertion_point(builder_scope:envoy.config.route.v3.RetryPolicy.RetryBackOff)
}
// @@protoc_insertion_point(class_scope:envoy.config.route.v3.RetryPolicy.RetryBackOff)
private static final io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryBackOff DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryBackOff();
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryBackOff getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public RetryBackOff parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryBackOff getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
public interface ResetHeaderOrBuilder extends
// @@protoc_insertion_point(interface_extends:envoy.config.route.v3.RetryPolicy.ResetHeader)
com.google.protobuf.MessageOrBuilder {
/**
*
* The name of the reset header.
*
* .. note::
*
* If the header appears multiple times only the first value is used.
*
*
* string name = 1 [(.validate.rules) = { ... }
* @return The name.
*/
java.lang.String getName();
/**
*
* The name of the reset header.
*
* .. note::
*
* If the header appears multiple times only the first value is used.
*
*
* string name = 1 [(.validate.rules) = { ... }
* @return The bytes for name.
*/
com.google.protobuf.ByteString
getNameBytes();
/**
*
* The format of the reset header.
*
*
* .envoy.config.route.v3.RetryPolicy.ResetHeaderFormat format = 2 [(.validate.rules) = { ... }
* @return The enum numeric value on the wire for format.
*/
int getFormatValue();
/**
*
* The format of the reset header.
*
*
* .envoy.config.route.v3.RetryPolicy.ResetHeaderFormat format = 2 [(.validate.rules) = { ... }
* @return The format.
*/
io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeaderFormat getFormat();
}
/**
* Protobuf type {@code envoy.config.route.v3.RetryPolicy.ResetHeader}
*/
public static final class ResetHeader extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:envoy.config.route.v3.RetryPolicy.ResetHeader)
ResetHeaderOrBuilder {
private static final long serialVersionUID = 0L;
// Use ResetHeader.newBuilder() to construct.
private ResetHeader(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private ResetHeader() {
name_ = "";
format_ = 0;
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new ResetHeader();
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RetryPolicy_ResetHeader_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RetryPolicy_ResetHeader_fieldAccessorTable
.ensureFieldAccessorsInitialized(
io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeader.class, io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeader.Builder.class);
}
public static final int NAME_FIELD_NUMBER = 1;
@SuppressWarnings("serial")
private volatile java.lang.Object name_ = "";
/**
*
* The name of the reset header.
*
* .. note::
*
* If the header appears multiple times only the first value is used.
*
*
* string name = 1 [(.validate.rules) = { ... }
* @return The name.
*/
@java.lang.Override
public java.lang.String getName() {
java.lang.Object ref = name_;
if (ref instanceof java.lang.String) {
return (java.lang.String) ref;
} else {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
name_ = s;
return s;
}
}
/**
*
* The name of the reset header.
*
* .. note::
*
* If the header appears multiple times only the first value is used.
*
*
* string name = 1 [(.validate.rules) = { ... }
* @return The bytes for name.
*/
@java.lang.Override
public com.google.protobuf.ByteString
getNameBytes() {
java.lang.Object ref = name_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
name_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int FORMAT_FIELD_NUMBER = 2;
private int format_ = 0;
/**
*
* The format of the reset header.
*
*
* .envoy.config.route.v3.RetryPolicy.ResetHeaderFormat format = 2 [(.validate.rules) = { ... }
* @return The enum numeric value on the wire for format.
*/
@java.lang.Override public int getFormatValue() {
return format_;
}
/**
*
* The format of the reset header.
*
*
* .envoy.config.route.v3.RetryPolicy.ResetHeaderFormat format = 2 [(.validate.rules) = { ... }
* @return The format.
*/
@java.lang.Override public io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeaderFormat getFormat() {
io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeaderFormat result = io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeaderFormat.forNumber(format_);
return result == null ? io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeaderFormat.UNRECOGNIZED : result;
}
private byte memoizedIsInitialized = -1;
@java.lang.Override
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
@java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_);
}
if (format_ != io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeaderFormat.SECONDS.getNumber()) {
output.writeEnum(2, format_);
}
getUnknownFields().writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_);
}
if (format_ != io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeaderFormat.SECONDS.getNumber()) {
size += com.google.protobuf.CodedOutputStream
.computeEnumSize(2, format_);
}
size += getUnknownFields().getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeader)) {
return super.equals(obj);
}
io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeader other = (io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeader) obj;
if (!getName()
.equals(other.getName())) return false;
if (format_ != other.format_) return false;
if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
hash = (37 * hash) + NAME_FIELD_NUMBER;
hash = (53 * hash) + getName().hashCode();
hash = (37 * hash) + FORMAT_FIELD_NUMBER;
hash = (53 * hash) + format_;
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeader parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeader parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeader parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeader parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeader parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeader parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeader parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeader parseFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeader parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeader parseDelimitedFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeader parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeader parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
@java.lang.Override
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeader prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
@java.lang.Override
public Builder toBuilder() {
return this == DEFAULT_INSTANCE
? new Builder() : new Builder().mergeFrom(this);
}
@java.lang.Override
protected Builder newBuilderForType(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
Builder builder = new Builder(parent);
return builder;
}
/**
* Protobuf type {@code envoy.config.route.v3.RetryPolicy.ResetHeader}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:envoy.config.route.v3.RetryPolicy.ResetHeader)
io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeaderOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RetryPolicy_ResetHeader_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RetryPolicy_ResetHeader_fieldAccessorTable
.ensureFieldAccessorsInitialized(
io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeader.class, io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeader.Builder.class);
}
// Construct using io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeader.newBuilder()
private Builder() {
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
}
@java.lang.Override
public Builder clear() {
super.clear();
bitField0_ = 0;
name_ = "";
format_ = 0;
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RetryPolicy_ResetHeader_descriptor;
}
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeader getDefaultInstanceForType() {
return io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeader.getDefaultInstance();
}
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeader build() {
io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeader result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeader buildPartial() {
io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeader result = new io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeader(this);
if (bitField0_ != 0) { buildPartial0(result); }
onBuilt();
return result;
}
private void buildPartial0(io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeader result) {
int from_bitField0_ = bitField0_;
if (((from_bitField0_ & 0x00000001) != 0)) {
result.name_ = name_;
}
if (((from_bitField0_ & 0x00000002) != 0)) {
result.format_ = format_;
}
}
@java.lang.Override
public Builder clone() {
return super.clone();
}
@java.lang.Override
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.setField(field, value);
}
@java.lang.Override
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return super.clearField(field);
}
@java.lang.Override
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return super.clearOneof(oneof);
}
@java.lang.Override
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return super.setRepeatedField(field, index, value);
}
@java.lang.Override
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.addRepeatedField(field, value);
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeader) {
return mergeFrom((io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeader)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeader other) {
if (other == io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeader.getDefaultInstance()) return this;
if (!other.getName().isEmpty()) {
name_ = other.name_;
bitField0_ |= 0x00000001;
onChanged();
}
if (other.format_ != 0) {
setFormatValue(other.getFormatValue());
}
this.mergeUnknownFields(other.getUnknownFields());
onChanged();
return this;
}
@java.lang.Override
public final boolean isInitialized() {
return true;
}
@java.lang.Override
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
name_ = input.readStringRequireUtf8();
bitField0_ |= 0x00000001;
break;
} // case 10
case 16: {
format_ = input.readEnum();
bitField0_ |= 0x00000002;
break;
} // case 16
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.unwrapIOException();
} finally {
onChanged();
} // finally
return this;
}
private int bitField0_;
private java.lang.Object name_ = "";
/**
*
* The name of the reset header.
*
* .. note::
*
* If the header appears multiple times only the first value is used.
*
*
* string name = 1 [(.validate.rules) = { ... }
* @return The name.
*/
public java.lang.String getName() {
java.lang.Object ref = name_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
name_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
*
* The name of the reset header.
*
* .. note::
*
* If the header appears multiple times only the first value is used.
*
*
* string name = 1 [(.validate.rules) = { ... }
* @return The bytes for name.
*/
public com.google.protobuf.ByteString
getNameBytes() {
java.lang.Object ref = name_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
name_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
*
* The name of the reset header.
*
* .. note::
*
* If the header appears multiple times only the first value is used.
*
*
* string name = 1 [(.validate.rules) = { ... }
* @param value The name to set.
* @return This builder for chaining.
*/
public Builder setName(
java.lang.String value) {
if (value == null) { throw new NullPointerException(); }
name_ = value;
bitField0_ |= 0x00000001;
onChanged();
return this;
}
/**
*
* The name of the reset header.
*
* .. note::
*
* If the header appears multiple times only the first value is used.
*
*
* string name = 1 [(.validate.rules) = { ... }
* @return This builder for chaining.
*/
public Builder clearName() {
name_ = getDefaultInstance().getName();
bitField0_ = (bitField0_ & ~0x00000001);
onChanged();
return this;
}
/**
*
* The name of the reset header.
*
* .. note::
*
* If the header appears multiple times only the first value is used.
*
*
* string name = 1 [(.validate.rules) = { ... }
* @param value The bytes for name to set.
* @return This builder for chaining.
*/
public Builder setNameBytes(
com.google.protobuf.ByteString value) {
if (value == null) { throw new NullPointerException(); }
checkByteStringIsUtf8(value);
name_ = value;
bitField0_ |= 0x00000001;
onChanged();
return this;
}
private int format_ = 0;
/**
*
* The format of the reset header.
*
*
* .envoy.config.route.v3.RetryPolicy.ResetHeaderFormat format = 2 [(.validate.rules) = { ... }
* @return The enum numeric value on the wire for format.
*/
@java.lang.Override public int getFormatValue() {
return format_;
}
/**
*
* The format of the reset header.
*
*
* .envoy.config.route.v3.RetryPolicy.ResetHeaderFormat format = 2 [(.validate.rules) = { ... }
* @param value The enum numeric value on the wire for format to set.
* @return This builder for chaining.
*/
public Builder setFormatValue(int value) {
format_ = value;
bitField0_ |= 0x00000002;
onChanged();
return this;
}
/**
*
* The format of the reset header.
*
*
* .envoy.config.route.v3.RetryPolicy.ResetHeaderFormat format = 2 [(.validate.rules) = { ... }
* @return The format.
*/
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeaderFormat getFormat() {
io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeaderFormat result = io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeaderFormat.forNumber(format_);
return result == null ? io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeaderFormat.UNRECOGNIZED : result;
}
/**
*
* The format of the reset header.
*
*
* .envoy.config.route.v3.RetryPolicy.ResetHeaderFormat format = 2 [(.validate.rules) = { ... }
* @param value The format to set.
* @return This builder for chaining.
*/
public Builder setFormat(io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeaderFormat value) {
if (value == null) {
throw new NullPointerException();
}
bitField0_ |= 0x00000002;
format_ = value.getNumber();
onChanged();
return this;
}
/**
*
* The format of the reset header.
*
*
* .envoy.config.route.v3.RetryPolicy.ResetHeaderFormat format = 2 [(.validate.rules) = { ... }
* @return This builder for chaining.
*/
public Builder clearFormat() {
bitField0_ = (bitField0_ & ~0x00000002);
format_ = 0;
onChanged();
return this;
}
@java.lang.Override
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFields(unknownFields);
}
@java.lang.Override
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.mergeUnknownFields(unknownFields);
}
// @@protoc_insertion_point(builder_scope:envoy.config.route.v3.RetryPolicy.ResetHeader)
}
// @@protoc_insertion_point(class_scope:envoy.config.route.v3.RetryPolicy.ResetHeader)
private static final io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeader DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeader();
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeader getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public ResetHeader parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeader getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
public interface RateLimitedRetryBackOffOrBuilder extends
// @@protoc_insertion_point(interface_extends:envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff)
com.google.protobuf.MessageOrBuilder {
/**
*
* Specifies the reset headers (like ``Retry-After`` or ``X-RateLimit-Reset``)
* to match against the response. Headers are tried in order, and matched case
* insensitive. The first header to be parsed successfully is used. If no headers
* match the default exponential back-off is used instead.
*
*
* repeated .envoy.config.route.v3.RetryPolicy.ResetHeader reset_headers = 1 [(.validate.rules) = { ... }
*/
java.util.List
getResetHeadersList();
/**
*
* Specifies the reset headers (like ``Retry-After`` or ``X-RateLimit-Reset``)
* to match against the response. Headers are tried in order, and matched case
* insensitive. The first header to be parsed successfully is used. If no headers
* match the default exponential back-off is used instead.
*
*
* repeated .envoy.config.route.v3.RetryPolicy.ResetHeader reset_headers = 1 [(.validate.rules) = { ... }
*/
io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeader getResetHeaders(int index);
/**
*
* Specifies the reset headers (like ``Retry-After`` or ``X-RateLimit-Reset``)
* to match against the response. Headers are tried in order, and matched case
* insensitive. The first header to be parsed successfully is used. If no headers
* match the default exponential back-off is used instead.
*
*
* repeated .envoy.config.route.v3.RetryPolicy.ResetHeader reset_headers = 1 [(.validate.rules) = { ... }
*/
int getResetHeadersCount();
/**
*
* Specifies the reset headers (like ``Retry-After`` or ``X-RateLimit-Reset``)
* to match against the response. Headers are tried in order, and matched case
* insensitive. The first header to be parsed successfully is used. If no headers
* match the default exponential back-off is used instead.
*
*
* repeated .envoy.config.route.v3.RetryPolicy.ResetHeader reset_headers = 1 [(.validate.rules) = { ... }
*/
java.util.List extends io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeaderOrBuilder>
getResetHeadersOrBuilderList();
/**
*
* Specifies the reset headers (like ``Retry-After`` or ``X-RateLimit-Reset``)
* to match against the response. Headers are tried in order, and matched case
* insensitive. The first header to be parsed successfully is used. If no headers
* match the default exponential back-off is used instead.
*
*
* repeated .envoy.config.route.v3.RetryPolicy.ResetHeader reset_headers = 1 [(.validate.rules) = { ... }
*/
io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeaderOrBuilder getResetHeadersOrBuilder(
int index);
/**
*
* Specifies the maximum back off interval that Envoy will allow. If a reset
* header contains an interval longer than this then it will be discarded and
* the next header will be tried. Defaults to 300 seconds.
*
*
* .google.protobuf.Duration max_interval = 2 [(.validate.rules) = { ... }
* @return Whether the maxInterval field is set.
*/
boolean hasMaxInterval();
/**
*
* Specifies the maximum back off interval that Envoy will allow. If a reset
* header contains an interval longer than this then it will be discarded and
* the next header will be tried. Defaults to 300 seconds.
*
*
* .google.protobuf.Duration max_interval = 2 [(.validate.rules) = { ... }
* @return The maxInterval.
*/
com.google.protobuf.Duration getMaxInterval();
/**
*
* Specifies the maximum back off interval that Envoy will allow. If a reset
* header contains an interval longer than this then it will be discarded and
* the next header will be tried. Defaults to 300 seconds.
*
*
* .google.protobuf.Duration max_interval = 2 [(.validate.rules) = { ... }
*/
com.google.protobuf.DurationOrBuilder getMaxIntervalOrBuilder();
}
/**
*
* A retry back-off strategy that applies when the upstream server rate limits
* the request.
*
* Given this configuration:
*
* .. code-block:: yaml
*
* rate_limited_retry_back_off:
* reset_headers:
* - name: Retry-After
* format: SECONDS
* - name: X-RateLimit-Reset
* format: UNIX_TIMESTAMP
* max_interval: "300s"
*
* The following algorithm will apply:
*
* 1. If the response contains the header ``Retry-After`` its value must be on
* the form ``120`` (an integer that represents the number of seconds to
* wait before retrying). If so, this value is used as the back-off interval.
* 2. Otherwise, if the response contains the header ``X-RateLimit-Reset`` its
* value must be on the form ``1595320702`` (an integer that represents the
* point in time at which to retry, as a Unix timestamp in seconds). If so,
* the current time is subtracted from this value and the result is used as
* the back-off interval.
* 3. Otherwise, Envoy will use the default
* :ref:`exponential back-off <envoy_v3_api_field_config.route.v3.RetryPolicy.retry_back_off>`
* strategy.
*
* No matter which format is used, if the resulting back-off interval exceeds
* ``max_interval`` it is discarded and the next header in ``reset_headers``
* is tried. If a request timeout is configured for the route it will further
* limit how long the request will be allowed to run.
*
* To prevent many clients retrying at the same point in time jitter is added
* to the back-off interval, so the resulting interval is decided by taking:
* ``random(interval, interval * 1.5)``.
*
* .. attention::
*
* Configuring ``rate_limited_retry_back_off`` will not by itself cause a request
* to be retried. You will still need to configure the right retry policy to match
* the responses from the upstream server.
*
*
* Protobuf type {@code envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff}
*/
public static final class RateLimitedRetryBackOff extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff)
RateLimitedRetryBackOffOrBuilder {
private static final long serialVersionUID = 0L;
// Use RateLimitedRetryBackOff.newBuilder() to construct.
private RateLimitedRetryBackOff(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private RateLimitedRetryBackOff() {
resetHeaders_ = java.util.Collections.emptyList();
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new RateLimitedRetryBackOff();
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RetryPolicy_RateLimitedRetryBackOff_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RetryPolicy_RateLimitedRetryBackOff_fieldAccessorTable
.ensureFieldAccessorsInitialized(
io.envoyproxy.envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff.class, io.envoyproxy.envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff.Builder.class);
}
private int bitField0_;
public static final int RESET_HEADERS_FIELD_NUMBER = 1;
@SuppressWarnings("serial")
private java.util.List resetHeaders_;
/**
*
* Specifies the reset headers (like ``Retry-After`` or ``X-RateLimit-Reset``)
* to match against the response. Headers are tried in order, and matched case
* insensitive. The first header to be parsed successfully is used. If no headers
* match the default exponential back-off is used instead.
*
*
* repeated .envoy.config.route.v3.RetryPolicy.ResetHeader reset_headers = 1 [(.validate.rules) = { ... }
*/
@java.lang.Override
public java.util.List getResetHeadersList() {
return resetHeaders_;
}
/**
*
* Specifies the reset headers (like ``Retry-After`` or ``X-RateLimit-Reset``)
* to match against the response. Headers are tried in order, and matched case
* insensitive. The first header to be parsed successfully is used. If no headers
* match the default exponential back-off is used instead.
*
*
* repeated .envoy.config.route.v3.RetryPolicy.ResetHeader reset_headers = 1 [(.validate.rules) = { ... }
*/
@java.lang.Override
public java.util.List extends io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeaderOrBuilder>
getResetHeadersOrBuilderList() {
return resetHeaders_;
}
/**
*
* Specifies the reset headers (like ``Retry-After`` or ``X-RateLimit-Reset``)
* to match against the response. Headers are tried in order, and matched case
* insensitive. The first header to be parsed successfully is used. If no headers
* match the default exponential back-off is used instead.
*
*
* repeated .envoy.config.route.v3.RetryPolicy.ResetHeader reset_headers = 1 [(.validate.rules) = { ... }
*/
@java.lang.Override
public int getResetHeadersCount() {
return resetHeaders_.size();
}
/**
*
* Specifies the reset headers (like ``Retry-After`` or ``X-RateLimit-Reset``)
* to match against the response. Headers are tried in order, and matched case
* insensitive. The first header to be parsed successfully is used. If no headers
* match the default exponential back-off is used instead.
*
*
* repeated .envoy.config.route.v3.RetryPolicy.ResetHeader reset_headers = 1 [(.validate.rules) = { ... }
*/
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeader getResetHeaders(int index) {
return resetHeaders_.get(index);
}
/**
*
* Specifies the reset headers (like ``Retry-After`` or ``X-RateLimit-Reset``)
* to match against the response. Headers are tried in order, and matched case
* insensitive. The first header to be parsed successfully is used. If no headers
* match the default exponential back-off is used instead.
*
*
* repeated .envoy.config.route.v3.RetryPolicy.ResetHeader reset_headers = 1 [(.validate.rules) = { ... }
*/
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeaderOrBuilder getResetHeadersOrBuilder(
int index) {
return resetHeaders_.get(index);
}
public static final int MAX_INTERVAL_FIELD_NUMBER = 2;
private com.google.protobuf.Duration maxInterval_;
/**
*
* Specifies the maximum back off interval that Envoy will allow. If a reset
* header contains an interval longer than this then it will be discarded and
* the next header will be tried. Defaults to 300 seconds.
*
*
* .google.protobuf.Duration max_interval = 2 [(.validate.rules) = { ... }
* @return Whether the maxInterval field is set.
*/
@java.lang.Override
public boolean hasMaxInterval() {
return ((bitField0_ & 0x00000001) != 0);
}
/**
*
* Specifies the maximum back off interval that Envoy will allow. If a reset
* header contains an interval longer than this then it will be discarded and
* the next header will be tried. Defaults to 300 seconds.
*
*
* .google.protobuf.Duration max_interval = 2 [(.validate.rules) = { ... }
* @return The maxInterval.
*/
@java.lang.Override
public com.google.protobuf.Duration getMaxInterval() {
return maxInterval_ == null ? com.google.protobuf.Duration.getDefaultInstance() : maxInterval_;
}
/**
*
* Specifies the maximum back off interval that Envoy will allow. If a reset
* header contains an interval longer than this then it will be discarded and
* the next header will be tried. Defaults to 300 seconds.
*
*
* .google.protobuf.Duration max_interval = 2 [(.validate.rules) = { ... }
*/
@java.lang.Override
public com.google.protobuf.DurationOrBuilder getMaxIntervalOrBuilder() {
return maxInterval_ == null ? com.google.protobuf.Duration.getDefaultInstance() : maxInterval_;
}
private byte memoizedIsInitialized = -1;
@java.lang.Override
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
@java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
for (int i = 0; i < resetHeaders_.size(); i++) {
output.writeMessage(1, resetHeaders_.get(i));
}
if (((bitField0_ & 0x00000001) != 0)) {
output.writeMessage(2, getMaxInterval());
}
getUnknownFields().writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
for (int i = 0; i < resetHeaders_.size(); i++) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(1, resetHeaders_.get(i));
}
if (((bitField0_ & 0x00000001) != 0)) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(2, getMaxInterval());
}
size += getUnknownFields().getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof io.envoyproxy.envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff)) {
return super.equals(obj);
}
io.envoyproxy.envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff other = (io.envoyproxy.envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff) obj;
if (!getResetHeadersList()
.equals(other.getResetHeadersList())) return false;
if (hasMaxInterval() != other.hasMaxInterval()) return false;
if (hasMaxInterval()) {
if (!getMaxInterval()
.equals(other.getMaxInterval())) return false;
}
if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
if (getResetHeadersCount() > 0) {
hash = (37 * hash) + RESET_HEADERS_FIELD_NUMBER;
hash = (53 * hash) + getResetHeadersList().hashCode();
}
if (hasMaxInterval()) {
hash = (37 * hash) + MAX_INTERVAL_FIELD_NUMBER;
hash = (53 * hash) + getMaxInterval().hashCode();
}
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff parseFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff parseDelimitedFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
@java.lang.Override
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(io.envoyproxy.envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
@java.lang.Override
public Builder toBuilder() {
return this == DEFAULT_INSTANCE
? new Builder() : new Builder().mergeFrom(this);
}
@java.lang.Override
protected Builder newBuilderForType(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
Builder builder = new Builder(parent);
return builder;
}
/**
*
* A retry back-off strategy that applies when the upstream server rate limits
* the request.
*
* Given this configuration:
*
* .. code-block:: yaml
*
* rate_limited_retry_back_off:
* reset_headers:
* - name: Retry-After
* format: SECONDS
* - name: X-RateLimit-Reset
* format: UNIX_TIMESTAMP
* max_interval: "300s"
*
* The following algorithm will apply:
*
* 1. If the response contains the header ``Retry-After`` its value must be on
* the form ``120`` (an integer that represents the number of seconds to
* wait before retrying). If so, this value is used as the back-off interval.
* 2. Otherwise, if the response contains the header ``X-RateLimit-Reset`` its
* value must be on the form ``1595320702`` (an integer that represents the
* point in time at which to retry, as a Unix timestamp in seconds). If so,
* the current time is subtracted from this value and the result is used as
* the back-off interval.
* 3. Otherwise, Envoy will use the default
* :ref:`exponential back-off <envoy_v3_api_field_config.route.v3.RetryPolicy.retry_back_off>`
* strategy.
*
* No matter which format is used, if the resulting back-off interval exceeds
* ``max_interval`` it is discarded and the next header in ``reset_headers``
* is tried. If a request timeout is configured for the route it will further
* limit how long the request will be allowed to run.
*
* To prevent many clients retrying at the same point in time jitter is added
* to the back-off interval, so the resulting interval is decided by taking:
* ``random(interval, interval * 1.5)``.
*
* .. attention::
*
* Configuring ``rate_limited_retry_back_off`` will not by itself cause a request
* to be retried. You will still need to configure the right retry policy to match
* the responses from the upstream server.
*
*
* Protobuf type {@code envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff)
io.envoyproxy.envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOffOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RetryPolicy_RateLimitedRetryBackOff_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RetryPolicy_RateLimitedRetryBackOff_fieldAccessorTable
.ensureFieldAccessorsInitialized(
io.envoyproxy.envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff.class, io.envoyproxy.envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff.Builder.class);
}
// Construct using io.envoyproxy.envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff.newBuilder()
private Builder() {
maybeForceBuilderInitialization();
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (com.google.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
getResetHeadersFieldBuilder();
getMaxIntervalFieldBuilder();
}
}
@java.lang.Override
public Builder clear() {
super.clear();
bitField0_ = 0;
if (resetHeadersBuilder_ == null) {
resetHeaders_ = java.util.Collections.emptyList();
} else {
resetHeaders_ = null;
resetHeadersBuilder_.clear();
}
bitField0_ = (bitField0_ & ~0x00000001);
maxInterval_ = null;
if (maxIntervalBuilder_ != null) {
maxIntervalBuilder_.dispose();
maxIntervalBuilder_ = null;
}
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RetryPolicy_RateLimitedRetryBackOff_descriptor;
}
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff getDefaultInstanceForType() {
return io.envoyproxy.envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff.getDefaultInstance();
}
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff build() {
io.envoyproxy.envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff buildPartial() {
io.envoyproxy.envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff result = new io.envoyproxy.envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff(this);
buildPartialRepeatedFields(result);
if (bitField0_ != 0) { buildPartial0(result); }
onBuilt();
return result;
}
private void buildPartialRepeatedFields(io.envoyproxy.envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff result) {
if (resetHeadersBuilder_ == null) {
if (((bitField0_ & 0x00000001) != 0)) {
resetHeaders_ = java.util.Collections.unmodifiableList(resetHeaders_);
bitField0_ = (bitField0_ & ~0x00000001);
}
result.resetHeaders_ = resetHeaders_;
} else {
result.resetHeaders_ = resetHeadersBuilder_.build();
}
}
private void buildPartial0(io.envoyproxy.envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff result) {
int from_bitField0_ = bitField0_;
int to_bitField0_ = 0;
if (((from_bitField0_ & 0x00000002) != 0)) {
result.maxInterval_ = maxIntervalBuilder_ == null
? maxInterval_
: maxIntervalBuilder_.build();
to_bitField0_ |= 0x00000001;
}
result.bitField0_ |= to_bitField0_;
}
@java.lang.Override
public Builder clone() {
return super.clone();
}
@java.lang.Override
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.setField(field, value);
}
@java.lang.Override
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return super.clearField(field);
}
@java.lang.Override
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return super.clearOneof(oneof);
}
@java.lang.Override
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return super.setRepeatedField(field, index, value);
}
@java.lang.Override
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.addRepeatedField(field, value);
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof io.envoyproxy.envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff) {
return mergeFrom((io.envoyproxy.envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(io.envoyproxy.envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff other) {
if (other == io.envoyproxy.envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff.getDefaultInstance()) return this;
if (resetHeadersBuilder_ == null) {
if (!other.resetHeaders_.isEmpty()) {
if (resetHeaders_.isEmpty()) {
resetHeaders_ = other.resetHeaders_;
bitField0_ = (bitField0_ & ~0x00000001);
} else {
ensureResetHeadersIsMutable();
resetHeaders_.addAll(other.resetHeaders_);
}
onChanged();
}
} else {
if (!other.resetHeaders_.isEmpty()) {
if (resetHeadersBuilder_.isEmpty()) {
resetHeadersBuilder_.dispose();
resetHeadersBuilder_ = null;
resetHeaders_ = other.resetHeaders_;
bitField0_ = (bitField0_ & ~0x00000001);
resetHeadersBuilder_ =
com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ?
getResetHeadersFieldBuilder() : null;
} else {
resetHeadersBuilder_.addAllMessages(other.resetHeaders_);
}
}
}
if (other.hasMaxInterval()) {
mergeMaxInterval(other.getMaxInterval());
}
this.mergeUnknownFields(other.getUnknownFields());
onChanged();
return this;
}
@java.lang.Override
public final boolean isInitialized() {
return true;
}
@java.lang.Override
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeader m =
input.readMessage(
io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeader.parser(),
extensionRegistry);
if (resetHeadersBuilder_ == null) {
ensureResetHeadersIsMutable();
resetHeaders_.add(m);
} else {
resetHeadersBuilder_.addMessage(m);
}
break;
} // case 10
case 18: {
input.readMessage(
getMaxIntervalFieldBuilder().getBuilder(),
extensionRegistry);
bitField0_ |= 0x00000002;
break;
} // case 18
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.unwrapIOException();
} finally {
onChanged();
} // finally
return this;
}
private int bitField0_;
private java.util.List resetHeaders_ =
java.util.Collections.emptyList();
private void ensureResetHeadersIsMutable() {
if (!((bitField0_ & 0x00000001) != 0)) {
resetHeaders_ = new java.util.ArrayList(resetHeaders_);
bitField0_ |= 0x00000001;
}
}
private com.google.protobuf.RepeatedFieldBuilderV3<
io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeader, io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeader.Builder, io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeaderOrBuilder> resetHeadersBuilder_;
/**
*
* Specifies the reset headers (like ``Retry-After`` or ``X-RateLimit-Reset``)
* to match against the response. Headers are tried in order, and matched case
* insensitive. The first header to be parsed successfully is used. If no headers
* match the default exponential back-off is used instead.
*
*
* repeated .envoy.config.route.v3.RetryPolicy.ResetHeader reset_headers = 1 [(.validate.rules) = { ... }
*/
public java.util.List getResetHeadersList() {
if (resetHeadersBuilder_ == null) {
return java.util.Collections.unmodifiableList(resetHeaders_);
} else {
return resetHeadersBuilder_.getMessageList();
}
}
/**
*
* Specifies the reset headers (like ``Retry-After`` or ``X-RateLimit-Reset``)
* to match against the response. Headers are tried in order, and matched case
* insensitive. The first header to be parsed successfully is used. If no headers
* match the default exponential back-off is used instead.
*
*
* repeated .envoy.config.route.v3.RetryPolicy.ResetHeader reset_headers = 1 [(.validate.rules) = { ... }
*/
public int getResetHeadersCount() {
if (resetHeadersBuilder_ == null) {
return resetHeaders_.size();
} else {
return resetHeadersBuilder_.getCount();
}
}
/**
*
* Specifies the reset headers (like ``Retry-After`` or ``X-RateLimit-Reset``)
* to match against the response. Headers are tried in order, and matched case
* insensitive. The first header to be parsed successfully is used. If no headers
* match the default exponential back-off is used instead.
*
*
* repeated .envoy.config.route.v3.RetryPolicy.ResetHeader reset_headers = 1 [(.validate.rules) = { ... }
*/
public io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeader getResetHeaders(int index) {
if (resetHeadersBuilder_ == null) {
return resetHeaders_.get(index);
} else {
return resetHeadersBuilder_.getMessage(index);
}
}
/**
*
* Specifies the reset headers (like ``Retry-After`` or ``X-RateLimit-Reset``)
* to match against the response. Headers are tried in order, and matched case
* insensitive. The first header to be parsed successfully is used. If no headers
* match the default exponential back-off is used instead.
*
*
* repeated .envoy.config.route.v3.RetryPolicy.ResetHeader reset_headers = 1 [(.validate.rules) = { ... }
*/
public Builder setResetHeaders(
int index, io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeader value) {
if (resetHeadersBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureResetHeadersIsMutable();
resetHeaders_.set(index, value);
onChanged();
} else {
resetHeadersBuilder_.setMessage(index, value);
}
return this;
}
/**
*
* Specifies the reset headers (like ``Retry-After`` or ``X-RateLimit-Reset``)
* to match against the response. Headers are tried in order, and matched case
* insensitive. The first header to be parsed successfully is used. If no headers
* match the default exponential back-off is used instead.
*
*
* repeated .envoy.config.route.v3.RetryPolicy.ResetHeader reset_headers = 1 [(.validate.rules) = { ... }
*/
public Builder setResetHeaders(
int index, io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeader.Builder builderForValue) {
if (resetHeadersBuilder_ == null) {
ensureResetHeadersIsMutable();
resetHeaders_.set(index, builderForValue.build());
onChanged();
} else {
resetHeadersBuilder_.setMessage(index, builderForValue.build());
}
return this;
}
/**
*
* Specifies the reset headers (like ``Retry-After`` or ``X-RateLimit-Reset``)
* to match against the response. Headers are tried in order, and matched case
* insensitive. The first header to be parsed successfully is used. If no headers
* match the default exponential back-off is used instead.
*
*
* repeated .envoy.config.route.v3.RetryPolicy.ResetHeader reset_headers = 1 [(.validate.rules) = { ... }
*/
public Builder addResetHeaders(io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeader value) {
if (resetHeadersBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureResetHeadersIsMutable();
resetHeaders_.add(value);
onChanged();
} else {
resetHeadersBuilder_.addMessage(value);
}
return this;
}
/**
*
* Specifies the reset headers (like ``Retry-After`` or ``X-RateLimit-Reset``)
* to match against the response. Headers are tried in order, and matched case
* insensitive. The first header to be parsed successfully is used. If no headers
* match the default exponential back-off is used instead.
*
*
* repeated .envoy.config.route.v3.RetryPolicy.ResetHeader reset_headers = 1 [(.validate.rules) = { ... }
*/
public Builder addResetHeaders(
int index, io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeader value) {
if (resetHeadersBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureResetHeadersIsMutable();
resetHeaders_.add(index, value);
onChanged();
} else {
resetHeadersBuilder_.addMessage(index, value);
}
return this;
}
/**
*
* Specifies the reset headers (like ``Retry-After`` or ``X-RateLimit-Reset``)
* to match against the response. Headers are tried in order, and matched case
* insensitive. The first header to be parsed successfully is used. If no headers
* match the default exponential back-off is used instead.
*
*
* repeated .envoy.config.route.v3.RetryPolicy.ResetHeader reset_headers = 1 [(.validate.rules) = { ... }
*/
public Builder addResetHeaders(
io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeader.Builder builderForValue) {
if (resetHeadersBuilder_ == null) {
ensureResetHeadersIsMutable();
resetHeaders_.add(builderForValue.build());
onChanged();
} else {
resetHeadersBuilder_.addMessage(builderForValue.build());
}
return this;
}
/**
*
* Specifies the reset headers (like ``Retry-After`` or ``X-RateLimit-Reset``)
* to match against the response. Headers are tried in order, and matched case
* insensitive. The first header to be parsed successfully is used. If no headers
* match the default exponential back-off is used instead.
*
*
* repeated .envoy.config.route.v3.RetryPolicy.ResetHeader reset_headers = 1 [(.validate.rules) = { ... }
*/
public Builder addResetHeaders(
int index, io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeader.Builder builderForValue) {
if (resetHeadersBuilder_ == null) {
ensureResetHeadersIsMutable();
resetHeaders_.add(index, builderForValue.build());
onChanged();
} else {
resetHeadersBuilder_.addMessage(index, builderForValue.build());
}
return this;
}
/**
*
* Specifies the reset headers (like ``Retry-After`` or ``X-RateLimit-Reset``)
* to match against the response. Headers are tried in order, and matched case
* insensitive. The first header to be parsed successfully is used. If no headers
* match the default exponential back-off is used instead.
*
*
* repeated .envoy.config.route.v3.RetryPolicy.ResetHeader reset_headers = 1 [(.validate.rules) = { ... }
*/
public Builder addAllResetHeaders(
java.lang.Iterable extends io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeader> values) {
if (resetHeadersBuilder_ == null) {
ensureResetHeadersIsMutable();
com.google.protobuf.AbstractMessageLite.Builder.addAll(
values, resetHeaders_);
onChanged();
} else {
resetHeadersBuilder_.addAllMessages(values);
}
return this;
}
/**
*
* Specifies the reset headers (like ``Retry-After`` or ``X-RateLimit-Reset``)
* to match against the response. Headers are tried in order, and matched case
* insensitive. The first header to be parsed successfully is used. If no headers
* match the default exponential back-off is used instead.
*
*
* repeated .envoy.config.route.v3.RetryPolicy.ResetHeader reset_headers = 1 [(.validate.rules) = { ... }
*/
public Builder clearResetHeaders() {
if (resetHeadersBuilder_ == null) {
resetHeaders_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000001);
onChanged();
} else {
resetHeadersBuilder_.clear();
}
return this;
}
/**
*
* Specifies the reset headers (like ``Retry-After`` or ``X-RateLimit-Reset``)
* to match against the response. Headers are tried in order, and matched case
* insensitive. The first header to be parsed successfully is used. If no headers
* match the default exponential back-off is used instead.
*
*
* repeated .envoy.config.route.v3.RetryPolicy.ResetHeader reset_headers = 1 [(.validate.rules) = { ... }
*/
public Builder removeResetHeaders(int index) {
if (resetHeadersBuilder_ == null) {
ensureResetHeadersIsMutable();
resetHeaders_.remove(index);
onChanged();
} else {
resetHeadersBuilder_.remove(index);
}
return this;
}
/**
*
* Specifies the reset headers (like ``Retry-After`` or ``X-RateLimit-Reset``)
* to match against the response. Headers are tried in order, and matched case
* insensitive. The first header to be parsed successfully is used. If no headers
* match the default exponential back-off is used instead.
*
*
* repeated .envoy.config.route.v3.RetryPolicy.ResetHeader reset_headers = 1 [(.validate.rules) = { ... }
*/
public io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeader.Builder getResetHeadersBuilder(
int index) {
return getResetHeadersFieldBuilder().getBuilder(index);
}
/**
*
* Specifies the reset headers (like ``Retry-After`` or ``X-RateLimit-Reset``)
* to match against the response. Headers are tried in order, and matched case
* insensitive. The first header to be parsed successfully is used. If no headers
* match the default exponential back-off is used instead.
*
*
* repeated .envoy.config.route.v3.RetryPolicy.ResetHeader reset_headers = 1 [(.validate.rules) = { ... }
*/
public io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeaderOrBuilder getResetHeadersOrBuilder(
int index) {
if (resetHeadersBuilder_ == null) {
return resetHeaders_.get(index); } else {
return resetHeadersBuilder_.getMessageOrBuilder(index);
}
}
/**
*
* Specifies the reset headers (like ``Retry-After`` or ``X-RateLimit-Reset``)
* to match against the response. Headers are tried in order, and matched case
* insensitive. The first header to be parsed successfully is used. If no headers
* match the default exponential back-off is used instead.
*
*
* repeated .envoy.config.route.v3.RetryPolicy.ResetHeader reset_headers = 1 [(.validate.rules) = { ... }
*/
public java.util.List extends io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeaderOrBuilder>
getResetHeadersOrBuilderList() {
if (resetHeadersBuilder_ != null) {
return resetHeadersBuilder_.getMessageOrBuilderList();
} else {
return java.util.Collections.unmodifiableList(resetHeaders_);
}
}
/**
*
* Specifies the reset headers (like ``Retry-After`` or ``X-RateLimit-Reset``)
* to match against the response. Headers are tried in order, and matched case
* insensitive. The first header to be parsed successfully is used. If no headers
* match the default exponential back-off is used instead.
*
*
* repeated .envoy.config.route.v3.RetryPolicy.ResetHeader reset_headers = 1 [(.validate.rules) = { ... }
*/
public io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeader.Builder addResetHeadersBuilder() {
return getResetHeadersFieldBuilder().addBuilder(
io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeader.getDefaultInstance());
}
/**
*
* Specifies the reset headers (like ``Retry-After`` or ``X-RateLimit-Reset``)
* to match against the response. Headers are tried in order, and matched case
* insensitive. The first header to be parsed successfully is used. If no headers
* match the default exponential back-off is used instead.
*
*
* repeated .envoy.config.route.v3.RetryPolicy.ResetHeader reset_headers = 1 [(.validate.rules) = { ... }
*/
public io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeader.Builder addResetHeadersBuilder(
int index) {
return getResetHeadersFieldBuilder().addBuilder(
index, io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeader.getDefaultInstance());
}
/**
*
* Specifies the reset headers (like ``Retry-After`` or ``X-RateLimit-Reset``)
* to match against the response. Headers are tried in order, and matched case
* insensitive. The first header to be parsed successfully is used. If no headers
* match the default exponential back-off is used instead.
*
*
* repeated .envoy.config.route.v3.RetryPolicy.ResetHeader reset_headers = 1 [(.validate.rules) = { ... }
*/
public java.util.List
getResetHeadersBuilderList() {
return getResetHeadersFieldBuilder().getBuilderList();
}
private com.google.protobuf.RepeatedFieldBuilderV3<
io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeader, io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeader.Builder, io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeaderOrBuilder>
getResetHeadersFieldBuilder() {
if (resetHeadersBuilder_ == null) {
resetHeadersBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3<
io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeader, io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeader.Builder, io.envoyproxy.envoy.config.route.v3.RetryPolicy.ResetHeaderOrBuilder>(
resetHeaders_,
((bitField0_ & 0x00000001) != 0),
getParentForChildren(),
isClean());
resetHeaders_ = null;
}
return resetHeadersBuilder_;
}
private com.google.protobuf.Duration maxInterval_;
private com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Duration, com.google.protobuf.Duration.Builder, com.google.protobuf.DurationOrBuilder> maxIntervalBuilder_;
/**
*
* Specifies the maximum back off interval that Envoy will allow. If a reset
* header contains an interval longer than this then it will be discarded and
* the next header will be tried. Defaults to 300 seconds.
*
*
* .google.protobuf.Duration max_interval = 2 [(.validate.rules) = { ... }
* @return Whether the maxInterval field is set.
*/
public boolean hasMaxInterval() {
return ((bitField0_ & 0x00000002) != 0);
}
/**
*
* Specifies the maximum back off interval that Envoy will allow. If a reset
* header contains an interval longer than this then it will be discarded and
* the next header will be tried. Defaults to 300 seconds.
*
*
* .google.protobuf.Duration max_interval = 2 [(.validate.rules) = { ... }
* @return The maxInterval.
*/
public com.google.protobuf.Duration getMaxInterval() {
if (maxIntervalBuilder_ == null) {
return maxInterval_ == null ? com.google.protobuf.Duration.getDefaultInstance() : maxInterval_;
} else {
return maxIntervalBuilder_.getMessage();
}
}
/**
*
* Specifies the maximum back off interval that Envoy will allow. If a reset
* header contains an interval longer than this then it will be discarded and
* the next header will be tried. Defaults to 300 seconds.
*
*
* .google.protobuf.Duration max_interval = 2 [(.validate.rules) = { ... }
*/
public Builder setMaxInterval(com.google.protobuf.Duration value) {
if (maxIntervalBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
maxInterval_ = value;
} else {
maxIntervalBuilder_.setMessage(value);
}
bitField0_ |= 0x00000002;
onChanged();
return this;
}
/**
*
* Specifies the maximum back off interval that Envoy will allow. If a reset
* header contains an interval longer than this then it will be discarded and
* the next header will be tried. Defaults to 300 seconds.
*
*
* .google.protobuf.Duration max_interval = 2 [(.validate.rules) = { ... }
*/
public Builder setMaxInterval(
com.google.protobuf.Duration.Builder builderForValue) {
if (maxIntervalBuilder_ == null) {
maxInterval_ = builderForValue.build();
} else {
maxIntervalBuilder_.setMessage(builderForValue.build());
}
bitField0_ |= 0x00000002;
onChanged();
return this;
}
/**
*
* Specifies the maximum back off interval that Envoy will allow. If a reset
* header contains an interval longer than this then it will be discarded and
* the next header will be tried. Defaults to 300 seconds.
*
*
* .google.protobuf.Duration max_interval = 2 [(.validate.rules) = { ... }
*/
public Builder mergeMaxInterval(com.google.protobuf.Duration value) {
if (maxIntervalBuilder_ == null) {
if (((bitField0_ & 0x00000002) != 0) &&
maxInterval_ != null &&
maxInterval_ != com.google.protobuf.Duration.getDefaultInstance()) {
getMaxIntervalBuilder().mergeFrom(value);
} else {
maxInterval_ = value;
}
} else {
maxIntervalBuilder_.mergeFrom(value);
}
if (maxInterval_ != null) {
bitField0_ |= 0x00000002;
onChanged();
}
return this;
}
/**
*
* Specifies the maximum back off interval that Envoy will allow. If a reset
* header contains an interval longer than this then it will be discarded and
* the next header will be tried. Defaults to 300 seconds.
*
*
* .google.protobuf.Duration max_interval = 2 [(.validate.rules) = { ... }
*/
public Builder clearMaxInterval() {
bitField0_ = (bitField0_ & ~0x00000002);
maxInterval_ = null;
if (maxIntervalBuilder_ != null) {
maxIntervalBuilder_.dispose();
maxIntervalBuilder_ = null;
}
onChanged();
return this;
}
/**
*
* Specifies the maximum back off interval that Envoy will allow. If a reset
* header contains an interval longer than this then it will be discarded and
* the next header will be tried. Defaults to 300 seconds.
*
*
* .google.protobuf.Duration max_interval = 2 [(.validate.rules) = { ... }
*/
public com.google.protobuf.Duration.Builder getMaxIntervalBuilder() {
bitField0_ |= 0x00000002;
onChanged();
return getMaxIntervalFieldBuilder().getBuilder();
}
/**
*
* Specifies the maximum back off interval that Envoy will allow. If a reset
* header contains an interval longer than this then it will be discarded and
* the next header will be tried. Defaults to 300 seconds.
*
*
* .google.protobuf.Duration max_interval = 2 [(.validate.rules) = { ... }
*/
public com.google.protobuf.DurationOrBuilder getMaxIntervalOrBuilder() {
if (maxIntervalBuilder_ != null) {
return maxIntervalBuilder_.getMessageOrBuilder();
} else {
return maxInterval_ == null ?
com.google.protobuf.Duration.getDefaultInstance() : maxInterval_;
}
}
/**
*
* Specifies the maximum back off interval that Envoy will allow. If a reset
* header contains an interval longer than this then it will be discarded and
* the next header will be tried. Defaults to 300 seconds.
*
*
* .google.protobuf.Duration max_interval = 2 [(.validate.rules) = { ... }
*/
private com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Duration, com.google.protobuf.Duration.Builder, com.google.protobuf.DurationOrBuilder>
getMaxIntervalFieldBuilder() {
if (maxIntervalBuilder_ == null) {
maxIntervalBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Duration, com.google.protobuf.Duration.Builder, com.google.protobuf.DurationOrBuilder>(
getMaxInterval(),
getParentForChildren(),
isClean());
maxInterval_ = null;
}
return maxIntervalBuilder_;
}
@java.lang.Override
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFields(unknownFields);
}
@java.lang.Override
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.mergeUnknownFields(unknownFields);
}
// @@protoc_insertion_point(builder_scope:envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff)
}
// @@protoc_insertion_point(class_scope:envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff)
private static final io.envoyproxy.envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new io.envoyproxy.envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff();
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public RateLimitedRetryBackOff parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
private int bitField0_;
public static final int RETRY_ON_FIELD_NUMBER = 1;
@SuppressWarnings("serial")
private volatile java.lang.Object retryOn_ = "";
/**
*
* Specifies the conditions under which retry takes place. These are the same
* conditions documented for :ref:`config_http_filters_router_x-envoy-retry-on` and
* :ref:`config_http_filters_router_x-envoy-retry-grpc-on`.
*
*
* string retry_on = 1;
* @return The retryOn.
*/
@java.lang.Override
public java.lang.String getRetryOn() {
java.lang.Object ref = retryOn_;
if (ref instanceof java.lang.String) {
return (java.lang.String) ref;
} else {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
retryOn_ = s;
return s;
}
}
/**
*
* Specifies the conditions under which retry takes place. These are the same
* conditions documented for :ref:`config_http_filters_router_x-envoy-retry-on` and
* :ref:`config_http_filters_router_x-envoy-retry-grpc-on`.
*
*
* string retry_on = 1;
* @return The bytes for retryOn.
*/
@java.lang.Override
public com.google.protobuf.ByteString
getRetryOnBytes() {
java.lang.Object ref = retryOn_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
retryOn_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int NUM_RETRIES_FIELD_NUMBER = 2;
private com.google.protobuf.UInt32Value numRetries_;
/**
*
* Specifies the allowed number of retries. This parameter is optional and
* defaults to 1. These are the same conditions documented for
* :ref:`config_http_filters_router_x-envoy-max-retries`.
*
*
* .google.protobuf.UInt32Value num_retries = 2 [(.udpa.annotations.field_migrate) = { ... }
* @return Whether the numRetries field is set.
*/
@java.lang.Override
public boolean hasNumRetries() {
return ((bitField0_ & 0x00000001) != 0);
}
/**
*
* Specifies the allowed number of retries. This parameter is optional and
* defaults to 1. These are the same conditions documented for
* :ref:`config_http_filters_router_x-envoy-max-retries`.
*
*
* .google.protobuf.UInt32Value num_retries = 2 [(.udpa.annotations.field_migrate) = { ... }
* @return The numRetries.
*/
@java.lang.Override
public com.google.protobuf.UInt32Value getNumRetries() {
return numRetries_ == null ? com.google.protobuf.UInt32Value.getDefaultInstance() : numRetries_;
}
/**
*
* Specifies the allowed number of retries. This parameter is optional and
* defaults to 1. These are the same conditions documented for
* :ref:`config_http_filters_router_x-envoy-max-retries`.
*
*
* .google.protobuf.UInt32Value num_retries = 2 [(.udpa.annotations.field_migrate) = { ... }
*/
@java.lang.Override
public com.google.protobuf.UInt32ValueOrBuilder getNumRetriesOrBuilder() {
return numRetries_ == null ? com.google.protobuf.UInt32Value.getDefaultInstance() : numRetries_;
}
public static final int PER_TRY_TIMEOUT_FIELD_NUMBER = 3;
private com.google.protobuf.Duration perTryTimeout_;
/**
*
* Specifies a non-zero upstream timeout per retry attempt (including the initial attempt). This
* parameter is optional. The same conditions documented for
* :ref:`config_http_filters_router_x-envoy-upstream-rq-per-try-timeout-ms` apply.
*
* .. note::
*
* If left unspecified, Envoy will use the global
* :ref:`route timeout <envoy_v3_api_field_config.route.v3.RouteAction.timeout>` for the request.
* Consequently, when using a :ref:`5xx <config_http_filters_router_x-envoy-retry-on>` based
* retry policy, a request that times out will not be retried as the total timeout budget
* would have been exhausted.
*
*
* .google.protobuf.Duration per_try_timeout = 3;
* @return Whether the perTryTimeout field is set.
*/
@java.lang.Override
public boolean hasPerTryTimeout() {
return ((bitField0_ & 0x00000002) != 0);
}
/**
*
* Specifies a non-zero upstream timeout per retry attempt (including the initial attempt). This
* parameter is optional. The same conditions documented for
* :ref:`config_http_filters_router_x-envoy-upstream-rq-per-try-timeout-ms` apply.
*
* .. note::
*
* If left unspecified, Envoy will use the global
* :ref:`route timeout <envoy_v3_api_field_config.route.v3.RouteAction.timeout>` for the request.
* Consequently, when using a :ref:`5xx <config_http_filters_router_x-envoy-retry-on>` based
* retry policy, a request that times out will not be retried as the total timeout budget
* would have been exhausted.
*
*
* .google.protobuf.Duration per_try_timeout = 3;
* @return The perTryTimeout.
*/
@java.lang.Override
public com.google.protobuf.Duration getPerTryTimeout() {
return perTryTimeout_ == null ? com.google.protobuf.Duration.getDefaultInstance() : perTryTimeout_;
}
/**
*
* Specifies a non-zero upstream timeout per retry attempt (including the initial attempt). This
* parameter is optional. The same conditions documented for
* :ref:`config_http_filters_router_x-envoy-upstream-rq-per-try-timeout-ms` apply.
*
* .. note::
*
* If left unspecified, Envoy will use the global
* :ref:`route timeout <envoy_v3_api_field_config.route.v3.RouteAction.timeout>` for the request.
* Consequently, when using a :ref:`5xx <config_http_filters_router_x-envoy-retry-on>` based
* retry policy, a request that times out will not be retried as the total timeout budget
* would have been exhausted.
*
*
* .google.protobuf.Duration per_try_timeout = 3;
*/
@java.lang.Override
public com.google.protobuf.DurationOrBuilder getPerTryTimeoutOrBuilder() {
return perTryTimeout_ == null ? com.google.protobuf.Duration.getDefaultInstance() : perTryTimeout_;
}
public static final int PER_TRY_IDLE_TIMEOUT_FIELD_NUMBER = 13;
private com.google.protobuf.Duration perTryIdleTimeout_;
/**
*
* Specifies an upstream idle timeout per retry attempt (including the initial attempt). This
* parameter is optional and if absent there is no per try idle timeout. The semantics of the per
* try idle timeout are similar to the
* :ref:`route idle timeout <envoy_v3_api_field_config.route.v3.RouteAction.timeout>` and
* :ref:`stream idle timeout
* <envoy_v3_api_field_extensions.filters.network.http_connection_manager.v3.HttpConnectionManager.stream_idle_timeout>`
* both enforced by the HTTP connection manager. The difference is that this idle timeout
* is enforced by the router for each individual attempt and thus after all previous filters have
* run, as opposed to *before* all previous filters run for the other idle timeouts. This timeout
* is useful in cases in which total request timeout is bounded by a number of retries and a
* :ref:`per_try_timeout <envoy_v3_api_field_config.route.v3.RetryPolicy.per_try_timeout>`, but
* there is a desire to ensure each try is making incremental progress. Note also that similar
* to :ref:`per_try_timeout <envoy_v3_api_field_config.route.v3.RetryPolicy.per_try_timeout>`,
* this idle timeout does not start until after both the entire request has been received by the
* router *and* a connection pool connection has been obtained. Unlike
* :ref:`per_try_timeout <envoy_v3_api_field_config.route.v3.RetryPolicy.per_try_timeout>`,
* the idle timer continues once the response starts streaming back to the downstream client.
* This ensures that response data continues to make progress without using one of the HTTP
* connection manager idle timeouts.
*
*
* .google.protobuf.Duration per_try_idle_timeout = 13;
* @return Whether the perTryIdleTimeout field is set.
*/
@java.lang.Override
public boolean hasPerTryIdleTimeout() {
return ((bitField0_ & 0x00000004) != 0);
}
/**
*
* Specifies an upstream idle timeout per retry attempt (including the initial attempt). This
* parameter is optional and if absent there is no per try idle timeout. The semantics of the per
* try idle timeout are similar to the
* :ref:`route idle timeout <envoy_v3_api_field_config.route.v3.RouteAction.timeout>` and
* :ref:`stream idle timeout
* <envoy_v3_api_field_extensions.filters.network.http_connection_manager.v3.HttpConnectionManager.stream_idle_timeout>`
* both enforced by the HTTP connection manager. The difference is that this idle timeout
* is enforced by the router for each individual attempt and thus after all previous filters have
* run, as opposed to *before* all previous filters run for the other idle timeouts. This timeout
* is useful in cases in which total request timeout is bounded by a number of retries and a
* :ref:`per_try_timeout <envoy_v3_api_field_config.route.v3.RetryPolicy.per_try_timeout>`, but
* there is a desire to ensure each try is making incremental progress. Note also that similar
* to :ref:`per_try_timeout <envoy_v3_api_field_config.route.v3.RetryPolicy.per_try_timeout>`,
* this idle timeout does not start until after both the entire request has been received by the
* router *and* a connection pool connection has been obtained. Unlike
* :ref:`per_try_timeout <envoy_v3_api_field_config.route.v3.RetryPolicy.per_try_timeout>`,
* the idle timer continues once the response starts streaming back to the downstream client.
* This ensures that response data continues to make progress without using one of the HTTP
* connection manager idle timeouts.
*
*
* .google.protobuf.Duration per_try_idle_timeout = 13;
* @return The perTryIdleTimeout.
*/
@java.lang.Override
public com.google.protobuf.Duration getPerTryIdleTimeout() {
return perTryIdleTimeout_ == null ? com.google.protobuf.Duration.getDefaultInstance() : perTryIdleTimeout_;
}
/**
*
* Specifies an upstream idle timeout per retry attempt (including the initial attempt). This
* parameter is optional and if absent there is no per try idle timeout. The semantics of the per
* try idle timeout are similar to the
* :ref:`route idle timeout <envoy_v3_api_field_config.route.v3.RouteAction.timeout>` and
* :ref:`stream idle timeout
* <envoy_v3_api_field_extensions.filters.network.http_connection_manager.v3.HttpConnectionManager.stream_idle_timeout>`
* both enforced by the HTTP connection manager. The difference is that this idle timeout
* is enforced by the router for each individual attempt and thus after all previous filters have
* run, as opposed to *before* all previous filters run for the other idle timeouts. This timeout
* is useful in cases in which total request timeout is bounded by a number of retries and a
* :ref:`per_try_timeout <envoy_v3_api_field_config.route.v3.RetryPolicy.per_try_timeout>`, but
* there is a desire to ensure each try is making incremental progress. Note also that similar
* to :ref:`per_try_timeout <envoy_v3_api_field_config.route.v3.RetryPolicy.per_try_timeout>`,
* this idle timeout does not start until after both the entire request has been received by the
* router *and* a connection pool connection has been obtained. Unlike
* :ref:`per_try_timeout <envoy_v3_api_field_config.route.v3.RetryPolicy.per_try_timeout>`,
* the idle timer continues once the response starts streaming back to the downstream client.
* This ensures that response data continues to make progress without using one of the HTTP
* connection manager idle timeouts.
*
*
* .google.protobuf.Duration per_try_idle_timeout = 13;
*/
@java.lang.Override
public com.google.protobuf.DurationOrBuilder getPerTryIdleTimeoutOrBuilder() {
return perTryIdleTimeout_ == null ? com.google.protobuf.Duration.getDefaultInstance() : perTryIdleTimeout_;
}
public static final int RETRY_PRIORITY_FIELD_NUMBER = 4;
private io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryPriority retryPriority_;
/**
*
* Specifies an implementation of a RetryPriority which is used to determine the
* distribution of load across priorities used for retries. Refer to
* :ref:`retry plugin configuration <arch_overview_http_retry_plugins>` for more details.
*
*
* .envoy.config.route.v3.RetryPolicy.RetryPriority retry_priority = 4;
* @return Whether the retryPriority field is set.
*/
@java.lang.Override
public boolean hasRetryPriority() {
return ((bitField0_ & 0x00000008) != 0);
}
/**
*
* Specifies an implementation of a RetryPriority which is used to determine the
* distribution of load across priorities used for retries. Refer to
* :ref:`retry plugin configuration <arch_overview_http_retry_plugins>` for more details.
*
*
* .envoy.config.route.v3.RetryPolicy.RetryPriority retry_priority = 4;
* @return The retryPriority.
*/
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryPriority getRetryPriority() {
return retryPriority_ == null ? io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryPriority.getDefaultInstance() : retryPriority_;
}
/**
*
* Specifies an implementation of a RetryPriority which is used to determine the
* distribution of load across priorities used for retries. Refer to
* :ref:`retry plugin configuration <arch_overview_http_retry_plugins>` for more details.
*
*
* .envoy.config.route.v3.RetryPolicy.RetryPriority retry_priority = 4;
*/
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryPriorityOrBuilder getRetryPriorityOrBuilder() {
return retryPriority_ == null ? io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryPriority.getDefaultInstance() : retryPriority_;
}
public static final int RETRY_HOST_PREDICATE_FIELD_NUMBER = 5;
@SuppressWarnings("serial")
private java.util.List retryHostPredicate_;
/**
*
* Specifies a collection of RetryHostPredicates that will be consulted when selecting a host
* for retries. If any of the predicates reject the host, host selection will be reattempted.
* Refer to :ref:`retry plugin configuration <arch_overview_http_retry_plugins>` for more
* details.
*
*
* repeated .envoy.config.route.v3.RetryPolicy.RetryHostPredicate retry_host_predicate = 5;
*/
@java.lang.Override
public java.util.List getRetryHostPredicateList() {
return retryHostPredicate_;
}
/**
*
* Specifies a collection of RetryHostPredicates that will be consulted when selecting a host
* for retries. If any of the predicates reject the host, host selection will be reattempted.
* Refer to :ref:`retry plugin configuration <arch_overview_http_retry_plugins>` for more
* details.
*
*
* repeated .envoy.config.route.v3.RetryPolicy.RetryHostPredicate retry_host_predicate = 5;
*/
@java.lang.Override
public java.util.List extends io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicateOrBuilder>
getRetryHostPredicateOrBuilderList() {
return retryHostPredicate_;
}
/**
*
* Specifies a collection of RetryHostPredicates that will be consulted when selecting a host
* for retries. If any of the predicates reject the host, host selection will be reattempted.
* Refer to :ref:`retry plugin configuration <arch_overview_http_retry_plugins>` for more
* details.
*
*
* repeated .envoy.config.route.v3.RetryPolicy.RetryHostPredicate retry_host_predicate = 5;
*/
@java.lang.Override
public int getRetryHostPredicateCount() {
return retryHostPredicate_.size();
}
/**
*
* Specifies a collection of RetryHostPredicates that will be consulted when selecting a host
* for retries. If any of the predicates reject the host, host selection will be reattempted.
* Refer to :ref:`retry plugin configuration <arch_overview_http_retry_plugins>` for more
* details.
*
*
* repeated .envoy.config.route.v3.RetryPolicy.RetryHostPredicate retry_host_predicate = 5;
*/
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicate getRetryHostPredicate(int index) {
return retryHostPredicate_.get(index);
}
/**
*
* Specifies a collection of RetryHostPredicates that will be consulted when selecting a host
* for retries. If any of the predicates reject the host, host selection will be reattempted.
* Refer to :ref:`retry plugin configuration <arch_overview_http_retry_plugins>` for more
* details.
*
*
* repeated .envoy.config.route.v3.RetryPolicy.RetryHostPredicate retry_host_predicate = 5;
*/
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicateOrBuilder getRetryHostPredicateOrBuilder(
int index) {
return retryHostPredicate_.get(index);
}
public static final int RETRY_OPTIONS_PREDICATES_FIELD_NUMBER = 12;
@SuppressWarnings("serial")
private java.util.List retryOptionsPredicates_;
/**
*
* Retry options predicates that will be applied prior to retrying a request. These predicates
* allow customizing request behavior between retries.
* [#comment: add [#extension-category: envoy.retry_options_predicates] when there are built-in extensions]
*
*
* repeated .envoy.config.core.v3.TypedExtensionConfig retry_options_predicates = 12;
*/
@java.lang.Override
public java.util.List getRetryOptionsPredicatesList() {
return retryOptionsPredicates_;
}
/**
*
* Retry options predicates that will be applied prior to retrying a request. These predicates
* allow customizing request behavior between retries.
* [#comment: add [#extension-category: envoy.retry_options_predicates] when there are built-in extensions]
*
*
* repeated .envoy.config.core.v3.TypedExtensionConfig retry_options_predicates = 12;
*/
@java.lang.Override
public java.util.List extends io.envoyproxy.envoy.config.core.v3.TypedExtensionConfigOrBuilder>
getRetryOptionsPredicatesOrBuilderList() {
return retryOptionsPredicates_;
}
/**
*
* Retry options predicates that will be applied prior to retrying a request. These predicates
* allow customizing request behavior between retries.
* [#comment: add [#extension-category: envoy.retry_options_predicates] when there are built-in extensions]
*
*
* repeated .envoy.config.core.v3.TypedExtensionConfig retry_options_predicates = 12;
*/
@java.lang.Override
public int getRetryOptionsPredicatesCount() {
return retryOptionsPredicates_.size();
}
/**
*
* Retry options predicates that will be applied prior to retrying a request. These predicates
* allow customizing request behavior between retries.
* [#comment: add [#extension-category: envoy.retry_options_predicates] when there are built-in extensions]
*
*
* repeated .envoy.config.core.v3.TypedExtensionConfig retry_options_predicates = 12;
*/
@java.lang.Override
public io.envoyproxy.envoy.config.core.v3.TypedExtensionConfig getRetryOptionsPredicates(int index) {
return retryOptionsPredicates_.get(index);
}
/**
*
* Retry options predicates that will be applied prior to retrying a request. These predicates
* allow customizing request behavior between retries.
* [#comment: add [#extension-category: envoy.retry_options_predicates] when there are built-in extensions]
*
*
* repeated .envoy.config.core.v3.TypedExtensionConfig retry_options_predicates = 12;
*/
@java.lang.Override
public io.envoyproxy.envoy.config.core.v3.TypedExtensionConfigOrBuilder getRetryOptionsPredicatesOrBuilder(
int index) {
return retryOptionsPredicates_.get(index);
}
public static final int HOST_SELECTION_RETRY_MAX_ATTEMPTS_FIELD_NUMBER = 6;
private long hostSelectionRetryMaxAttempts_ = 0L;
/**
*
* The maximum number of times host selection will be reattempted before giving up, at which
* point the host that was last selected will be routed to. If unspecified, this will default to
* retrying once.
*
*
* int64 host_selection_retry_max_attempts = 6;
* @return The hostSelectionRetryMaxAttempts.
*/
@java.lang.Override
public long getHostSelectionRetryMaxAttempts() {
return hostSelectionRetryMaxAttempts_;
}
public static final int RETRIABLE_STATUS_CODES_FIELD_NUMBER = 7;
@SuppressWarnings("serial")
private com.google.protobuf.Internal.IntList retriableStatusCodes_ =
emptyIntList();
/**
*
* HTTP status codes that should trigger a retry in addition to those specified by retry_on.
*
*
* repeated uint32 retriable_status_codes = 7;
* @return A list containing the retriableStatusCodes.
*/
@java.lang.Override
public java.util.List
getRetriableStatusCodesList() {
return retriableStatusCodes_;
}
/**
*
* HTTP status codes that should trigger a retry in addition to those specified by retry_on.
*
*
* repeated uint32 retriable_status_codes = 7;
* @return The count of retriableStatusCodes.
*/
public int getRetriableStatusCodesCount() {
return retriableStatusCodes_.size();
}
/**
*
* HTTP status codes that should trigger a retry in addition to those specified by retry_on.
*
*
* repeated uint32 retriable_status_codes = 7;
* @param index The index of the element to return.
* @return The retriableStatusCodes at the given index.
*/
public int getRetriableStatusCodes(int index) {
return retriableStatusCodes_.getInt(index);
}
private int retriableStatusCodesMemoizedSerializedSize = -1;
public static final int RETRY_BACK_OFF_FIELD_NUMBER = 8;
private io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryBackOff retryBackOff_;
/**
*
* Specifies parameters that control exponential retry back off. This parameter is optional, in which case the
* default base interval is 25 milliseconds or, if set, the current value of the
* ``upstream.base_retry_backoff_ms`` runtime parameter. The default maximum interval is 10 times
* the base interval. The documentation for :ref:`config_http_filters_router_x-envoy-max-retries`
* describes Envoy's back-off algorithm.
*
*
* .envoy.config.route.v3.RetryPolicy.RetryBackOff retry_back_off = 8;
* @return Whether the retryBackOff field is set.
*/
@java.lang.Override
public boolean hasRetryBackOff() {
return ((bitField0_ & 0x00000010) != 0);
}
/**
*
* Specifies parameters that control exponential retry back off. This parameter is optional, in which case the
* default base interval is 25 milliseconds or, if set, the current value of the
* ``upstream.base_retry_backoff_ms`` runtime parameter. The default maximum interval is 10 times
* the base interval. The documentation for :ref:`config_http_filters_router_x-envoy-max-retries`
* describes Envoy's back-off algorithm.
*
*
* .envoy.config.route.v3.RetryPolicy.RetryBackOff retry_back_off = 8;
* @return The retryBackOff.
*/
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryBackOff getRetryBackOff() {
return retryBackOff_ == null ? io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryBackOff.getDefaultInstance() : retryBackOff_;
}
/**
*
* Specifies parameters that control exponential retry back off. This parameter is optional, in which case the
* default base interval is 25 milliseconds or, if set, the current value of the
* ``upstream.base_retry_backoff_ms`` runtime parameter. The default maximum interval is 10 times
* the base interval. The documentation for :ref:`config_http_filters_router_x-envoy-max-retries`
* describes Envoy's back-off algorithm.
*
*
* .envoy.config.route.v3.RetryPolicy.RetryBackOff retry_back_off = 8;
*/
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryBackOffOrBuilder getRetryBackOffOrBuilder() {
return retryBackOff_ == null ? io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryBackOff.getDefaultInstance() : retryBackOff_;
}
public static final int RATE_LIMITED_RETRY_BACK_OFF_FIELD_NUMBER = 11;
private io.envoyproxy.envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff rateLimitedRetryBackOff_;
/**
*
* Specifies parameters that control a retry back-off strategy that is used
* when the request is rate limited by the upstream server. The server may
* return a response header like ``Retry-After`` or ``X-RateLimit-Reset`` to
* provide feedback to the client on how long to wait before retrying. If
* configured, this back-off strategy will be used instead of the
* default exponential back off strategy (configured using ``retry_back_off``)
* whenever a response includes the matching headers.
*
*
* .envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff rate_limited_retry_back_off = 11;
* @return Whether the rateLimitedRetryBackOff field is set.
*/
@java.lang.Override
public boolean hasRateLimitedRetryBackOff() {
return ((bitField0_ & 0x00000020) != 0);
}
/**
*
* Specifies parameters that control a retry back-off strategy that is used
* when the request is rate limited by the upstream server. The server may
* return a response header like ``Retry-After`` or ``X-RateLimit-Reset`` to
* provide feedback to the client on how long to wait before retrying. If
* configured, this back-off strategy will be used instead of the
* default exponential back off strategy (configured using ``retry_back_off``)
* whenever a response includes the matching headers.
*
*
* .envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff rate_limited_retry_back_off = 11;
* @return The rateLimitedRetryBackOff.
*/
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff getRateLimitedRetryBackOff() {
return rateLimitedRetryBackOff_ == null ? io.envoyproxy.envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff.getDefaultInstance() : rateLimitedRetryBackOff_;
}
/**
*
* Specifies parameters that control a retry back-off strategy that is used
* when the request is rate limited by the upstream server. The server may
* return a response header like ``Retry-After`` or ``X-RateLimit-Reset`` to
* provide feedback to the client on how long to wait before retrying. If
* configured, this back-off strategy will be used instead of the
* default exponential back off strategy (configured using ``retry_back_off``)
* whenever a response includes the matching headers.
*
*
* .envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff rate_limited_retry_back_off = 11;
*/
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOffOrBuilder getRateLimitedRetryBackOffOrBuilder() {
return rateLimitedRetryBackOff_ == null ? io.envoyproxy.envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff.getDefaultInstance() : rateLimitedRetryBackOff_;
}
public static final int RETRIABLE_HEADERS_FIELD_NUMBER = 9;
@SuppressWarnings("serial")
private java.util.List retriableHeaders_;
/**
*
* HTTP response headers that trigger a retry if present in the response. A retry will be
* triggered if any of the header matches match the upstream response headers.
* The field is only consulted if 'retriable-headers' retry policy is active.
*
*
* repeated .envoy.config.route.v3.HeaderMatcher retriable_headers = 9;
*/
@java.lang.Override
public java.util.List getRetriableHeadersList() {
return retriableHeaders_;
}
/**
*
* HTTP response headers that trigger a retry if present in the response. A retry will be
* triggered if any of the header matches match the upstream response headers.
* The field is only consulted if 'retriable-headers' retry policy is active.
*
*
* repeated .envoy.config.route.v3.HeaderMatcher retriable_headers = 9;
*/
@java.lang.Override
public java.util.List extends io.envoyproxy.envoy.config.route.v3.HeaderMatcherOrBuilder>
getRetriableHeadersOrBuilderList() {
return retriableHeaders_;
}
/**
*
* HTTP response headers that trigger a retry if present in the response. A retry will be
* triggered if any of the header matches match the upstream response headers.
* The field is only consulted if 'retriable-headers' retry policy is active.
*
*
* repeated .envoy.config.route.v3.HeaderMatcher retriable_headers = 9;
*/
@java.lang.Override
public int getRetriableHeadersCount() {
return retriableHeaders_.size();
}
/**
*
* HTTP response headers that trigger a retry if present in the response. A retry will be
* triggered if any of the header matches match the upstream response headers.
* The field is only consulted if 'retriable-headers' retry policy is active.
*
*
* repeated .envoy.config.route.v3.HeaderMatcher retriable_headers = 9;
*/
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.HeaderMatcher getRetriableHeaders(int index) {
return retriableHeaders_.get(index);
}
/**
*
* HTTP response headers that trigger a retry if present in the response. A retry will be
* triggered if any of the header matches match the upstream response headers.
* The field is only consulted if 'retriable-headers' retry policy is active.
*
*
* repeated .envoy.config.route.v3.HeaderMatcher retriable_headers = 9;
*/
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.HeaderMatcherOrBuilder getRetriableHeadersOrBuilder(
int index) {
return retriableHeaders_.get(index);
}
public static final int RETRIABLE_REQUEST_HEADERS_FIELD_NUMBER = 10;
@SuppressWarnings("serial")
private java.util.List retriableRequestHeaders_;
/**
*
* HTTP headers which must be present in the request for retries to be attempted.
*
*
* repeated .envoy.config.route.v3.HeaderMatcher retriable_request_headers = 10;
*/
@java.lang.Override
public java.util.List getRetriableRequestHeadersList() {
return retriableRequestHeaders_;
}
/**
*
* HTTP headers which must be present in the request for retries to be attempted.
*
*
* repeated .envoy.config.route.v3.HeaderMatcher retriable_request_headers = 10;
*/
@java.lang.Override
public java.util.List extends io.envoyproxy.envoy.config.route.v3.HeaderMatcherOrBuilder>
getRetriableRequestHeadersOrBuilderList() {
return retriableRequestHeaders_;
}
/**
*
* HTTP headers which must be present in the request for retries to be attempted.
*
*
* repeated .envoy.config.route.v3.HeaderMatcher retriable_request_headers = 10;
*/
@java.lang.Override
public int getRetriableRequestHeadersCount() {
return retriableRequestHeaders_.size();
}
/**
*
* HTTP headers which must be present in the request for retries to be attempted.
*
*
* repeated .envoy.config.route.v3.HeaderMatcher retriable_request_headers = 10;
*/
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.HeaderMatcher getRetriableRequestHeaders(int index) {
return retriableRequestHeaders_.get(index);
}
/**
*
* HTTP headers which must be present in the request for retries to be attempted.
*
*
* repeated .envoy.config.route.v3.HeaderMatcher retriable_request_headers = 10;
*/
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.HeaderMatcherOrBuilder getRetriableRequestHeadersOrBuilder(
int index) {
return retriableRequestHeaders_.get(index);
}
private byte memoizedIsInitialized = -1;
@java.lang.Override
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
@java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
getSerializedSize();
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(retryOn_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 1, retryOn_);
}
if (((bitField0_ & 0x00000001) != 0)) {
output.writeMessage(2, getNumRetries());
}
if (((bitField0_ & 0x00000002) != 0)) {
output.writeMessage(3, getPerTryTimeout());
}
if (((bitField0_ & 0x00000008) != 0)) {
output.writeMessage(4, getRetryPriority());
}
for (int i = 0; i < retryHostPredicate_.size(); i++) {
output.writeMessage(5, retryHostPredicate_.get(i));
}
if (hostSelectionRetryMaxAttempts_ != 0L) {
output.writeInt64(6, hostSelectionRetryMaxAttempts_);
}
if (getRetriableStatusCodesList().size() > 0) {
output.writeUInt32NoTag(58);
output.writeUInt32NoTag(retriableStatusCodesMemoizedSerializedSize);
}
for (int i = 0; i < retriableStatusCodes_.size(); i++) {
output.writeUInt32NoTag(retriableStatusCodes_.getInt(i));
}
if (((bitField0_ & 0x00000010) != 0)) {
output.writeMessage(8, getRetryBackOff());
}
for (int i = 0; i < retriableHeaders_.size(); i++) {
output.writeMessage(9, retriableHeaders_.get(i));
}
for (int i = 0; i < retriableRequestHeaders_.size(); i++) {
output.writeMessage(10, retriableRequestHeaders_.get(i));
}
if (((bitField0_ & 0x00000020) != 0)) {
output.writeMessage(11, getRateLimitedRetryBackOff());
}
for (int i = 0; i < retryOptionsPredicates_.size(); i++) {
output.writeMessage(12, retryOptionsPredicates_.get(i));
}
if (((bitField0_ & 0x00000004) != 0)) {
output.writeMessage(13, getPerTryIdleTimeout());
}
getUnknownFields().writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(retryOn_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, retryOn_);
}
if (((bitField0_ & 0x00000001) != 0)) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(2, getNumRetries());
}
if (((bitField0_ & 0x00000002) != 0)) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(3, getPerTryTimeout());
}
if (((bitField0_ & 0x00000008) != 0)) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(4, getRetryPriority());
}
for (int i = 0; i < retryHostPredicate_.size(); i++) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(5, retryHostPredicate_.get(i));
}
if (hostSelectionRetryMaxAttempts_ != 0L) {
size += com.google.protobuf.CodedOutputStream
.computeInt64Size(6, hostSelectionRetryMaxAttempts_);
}
{
int dataSize = 0;
for (int i = 0; i < retriableStatusCodes_.size(); i++) {
dataSize += com.google.protobuf.CodedOutputStream
.computeUInt32SizeNoTag(retriableStatusCodes_.getInt(i));
}
size += dataSize;
if (!getRetriableStatusCodesList().isEmpty()) {
size += 1;
size += com.google.protobuf.CodedOutputStream
.computeInt32SizeNoTag(dataSize);
}
retriableStatusCodesMemoizedSerializedSize = dataSize;
}
if (((bitField0_ & 0x00000010) != 0)) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(8, getRetryBackOff());
}
for (int i = 0; i < retriableHeaders_.size(); i++) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(9, retriableHeaders_.get(i));
}
for (int i = 0; i < retriableRequestHeaders_.size(); i++) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(10, retriableRequestHeaders_.get(i));
}
if (((bitField0_ & 0x00000020) != 0)) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(11, getRateLimitedRetryBackOff());
}
for (int i = 0; i < retryOptionsPredicates_.size(); i++) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(12, retryOptionsPredicates_.get(i));
}
if (((bitField0_ & 0x00000004) != 0)) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(13, getPerTryIdleTimeout());
}
size += getUnknownFields().getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof io.envoyproxy.envoy.config.route.v3.RetryPolicy)) {
return super.equals(obj);
}
io.envoyproxy.envoy.config.route.v3.RetryPolicy other = (io.envoyproxy.envoy.config.route.v3.RetryPolicy) obj;
if (!getRetryOn()
.equals(other.getRetryOn())) return false;
if (hasNumRetries() != other.hasNumRetries()) return false;
if (hasNumRetries()) {
if (!getNumRetries()
.equals(other.getNumRetries())) return false;
}
if (hasPerTryTimeout() != other.hasPerTryTimeout()) return false;
if (hasPerTryTimeout()) {
if (!getPerTryTimeout()
.equals(other.getPerTryTimeout())) return false;
}
if (hasPerTryIdleTimeout() != other.hasPerTryIdleTimeout()) return false;
if (hasPerTryIdleTimeout()) {
if (!getPerTryIdleTimeout()
.equals(other.getPerTryIdleTimeout())) return false;
}
if (hasRetryPriority() != other.hasRetryPriority()) return false;
if (hasRetryPriority()) {
if (!getRetryPriority()
.equals(other.getRetryPriority())) return false;
}
if (!getRetryHostPredicateList()
.equals(other.getRetryHostPredicateList())) return false;
if (!getRetryOptionsPredicatesList()
.equals(other.getRetryOptionsPredicatesList())) return false;
if (getHostSelectionRetryMaxAttempts()
!= other.getHostSelectionRetryMaxAttempts()) return false;
if (!getRetriableStatusCodesList()
.equals(other.getRetriableStatusCodesList())) return false;
if (hasRetryBackOff() != other.hasRetryBackOff()) return false;
if (hasRetryBackOff()) {
if (!getRetryBackOff()
.equals(other.getRetryBackOff())) return false;
}
if (hasRateLimitedRetryBackOff() != other.hasRateLimitedRetryBackOff()) return false;
if (hasRateLimitedRetryBackOff()) {
if (!getRateLimitedRetryBackOff()
.equals(other.getRateLimitedRetryBackOff())) return false;
}
if (!getRetriableHeadersList()
.equals(other.getRetriableHeadersList())) return false;
if (!getRetriableRequestHeadersList()
.equals(other.getRetriableRequestHeadersList())) return false;
if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
hash = (37 * hash) + RETRY_ON_FIELD_NUMBER;
hash = (53 * hash) + getRetryOn().hashCode();
if (hasNumRetries()) {
hash = (37 * hash) + NUM_RETRIES_FIELD_NUMBER;
hash = (53 * hash) + getNumRetries().hashCode();
}
if (hasPerTryTimeout()) {
hash = (37 * hash) + PER_TRY_TIMEOUT_FIELD_NUMBER;
hash = (53 * hash) + getPerTryTimeout().hashCode();
}
if (hasPerTryIdleTimeout()) {
hash = (37 * hash) + PER_TRY_IDLE_TIMEOUT_FIELD_NUMBER;
hash = (53 * hash) + getPerTryIdleTimeout().hashCode();
}
if (hasRetryPriority()) {
hash = (37 * hash) + RETRY_PRIORITY_FIELD_NUMBER;
hash = (53 * hash) + getRetryPriority().hashCode();
}
if (getRetryHostPredicateCount() > 0) {
hash = (37 * hash) + RETRY_HOST_PREDICATE_FIELD_NUMBER;
hash = (53 * hash) + getRetryHostPredicateList().hashCode();
}
if (getRetryOptionsPredicatesCount() > 0) {
hash = (37 * hash) + RETRY_OPTIONS_PREDICATES_FIELD_NUMBER;
hash = (53 * hash) + getRetryOptionsPredicatesList().hashCode();
}
hash = (37 * hash) + HOST_SELECTION_RETRY_MAX_ATTEMPTS_FIELD_NUMBER;
hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
getHostSelectionRetryMaxAttempts());
if (getRetriableStatusCodesCount() > 0) {
hash = (37 * hash) + RETRIABLE_STATUS_CODES_FIELD_NUMBER;
hash = (53 * hash) + getRetriableStatusCodesList().hashCode();
}
if (hasRetryBackOff()) {
hash = (37 * hash) + RETRY_BACK_OFF_FIELD_NUMBER;
hash = (53 * hash) + getRetryBackOff().hashCode();
}
if (hasRateLimitedRetryBackOff()) {
hash = (37 * hash) + RATE_LIMITED_RETRY_BACK_OFF_FIELD_NUMBER;
hash = (53 * hash) + getRateLimitedRetryBackOff().hashCode();
}
if (getRetriableHeadersCount() > 0) {
hash = (37 * hash) + RETRIABLE_HEADERS_FIELD_NUMBER;
hash = (53 * hash) + getRetriableHeadersList().hashCode();
}
if (getRetriableRequestHeadersCount() > 0) {
hash = (37 * hash) + RETRIABLE_REQUEST_HEADERS_FIELD_NUMBER;
hash = (53 * hash) + getRetriableRequestHeadersList().hashCode();
}
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy parseFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy parseDelimitedFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
@java.lang.Override
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(io.envoyproxy.envoy.config.route.v3.RetryPolicy prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
@java.lang.Override
public Builder toBuilder() {
return this == DEFAULT_INSTANCE
? new Builder() : new Builder().mergeFrom(this);
}
@java.lang.Override
protected Builder newBuilderForType(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
Builder builder = new Builder(parent);
return builder;
}
/**
*
* HTTP retry :ref:`architecture overview <arch_overview_http_routing_retry>`.
* [#next-free-field: 14]
*
*
* Protobuf type {@code envoy.config.route.v3.RetryPolicy}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:envoy.config.route.v3.RetryPolicy)
io.envoyproxy.envoy.config.route.v3.RetryPolicyOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RetryPolicy_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RetryPolicy_fieldAccessorTable
.ensureFieldAccessorsInitialized(
io.envoyproxy.envoy.config.route.v3.RetryPolicy.class, io.envoyproxy.envoy.config.route.v3.RetryPolicy.Builder.class);
}
// Construct using io.envoyproxy.envoy.config.route.v3.RetryPolicy.newBuilder()
private Builder() {
maybeForceBuilderInitialization();
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (com.google.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
getNumRetriesFieldBuilder();
getPerTryTimeoutFieldBuilder();
getPerTryIdleTimeoutFieldBuilder();
getRetryPriorityFieldBuilder();
getRetryHostPredicateFieldBuilder();
getRetryOptionsPredicatesFieldBuilder();
getRetryBackOffFieldBuilder();
getRateLimitedRetryBackOffFieldBuilder();
getRetriableHeadersFieldBuilder();
getRetriableRequestHeadersFieldBuilder();
}
}
@java.lang.Override
public Builder clear() {
super.clear();
bitField0_ = 0;
retryOn_ = "";
numRetries_ = null;
if (numRetriesBuilder_ != null) {
numRetriesBuilder_.dispose();
numRetriesBuilder_ = null;
}
perTryTimeout_ = null;
if (perTryTimeoutBuilder_ != null) {
perTryTimeoutBuilder_.dispose();
perTryTimeoutBuilder_ = null;
}
perTryIdleTimeout_ = null;
if (perTryIdleTimeoutBuilder_ != null) {
perTryIdleTimeoutBuilder_.dispose();
perTryIdleTimeoutBuilder_ = null;
}
retryPriority_ = null;
if (retryPriorityBuilder_ != null) {
retryPriorityBuilder_.dispose();
retryPriorityBuilder_ = null;
}
if (retryHostPredicateBuilder_ == null) {
retryHostPredicate_ = java.util.Collections.emptyList();
} else {
retryHostPredicate_ = null;
retryHostPredicateBuilder_.clear();
}
bitField0_ = (bitField0_ & ~0x00000020);
if (retryOptionsPredicatesBuilder_ == null) {
retryOptionsPredicates_ = java.util.Collections.emptyList();
} else {
retryOptionsPredicates_ = null;
retryOptionsPredicatesBuilder_.clear();
}
bitField0_ = (bitField0_ & ~0x00000040);
hostSelectionRetryMaxAttempts_ = 0L;
retriableStatusCodes_ = emptyIntList();
retryBackOff_ = null;
if (retryBackOffBuilder_ != null) {
retryBackOffBuilder_.dispose();
retryBackOffBuilder_ = null;
}
rateLimitedRetryBackOff_ = null;
if (rateLimitedRetryBackOffBuilder_ != null) {
rateLimitedRetryBackOffBuilder_.dispose();
rateLimitedRetryBackOffBuilder_ = null;
}
if (retriableHeadersBuilder_ == null) {
retriableHeaders_ = java.util.Collections.emptyList();
} else {
retriableHeaders_ = null;
retriableHeadersBuilder_.clear();
}
bitField0_ = (bitField0_ & ~0x00000800);
if (retriableRequestHeadersBuilder_ == null) {
retriableRequestHeaders_ = java.util.Collections.emptyList();
} else {
retriableRequestHeaders_ = null;
retriableRequestHeadersBuilder_.clear();
}
bitField0_ = (bitField0_ & ~0x00001000);
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return io.envoyproxy.envoy.config.route.v3.RouteComponentsProto.internal_static_envoy_config_route_v3_RetryPolicy_descriptor;
}
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RetryPolicy getDefaultInstanceForType() {
return io.envoyproxy.envoy.config.route.v3.RetryPolicy.getDefaultInstance();
}
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RetryPolicy build() {
io.envoyproxy.envoy.config.route.v3.RetryPolicy result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RetryPolicy buildPartial() {
io.envoyproxy.envoy.config.route.v3.RetryPolicy result = new io.envoyproxy.envoy.config.route.v3.RetryPolicy(this);
buildPartialRepeatedFields(result);
if (bitField0_ != 0) { buildPartial0(result); }
onBuilt();
return result;
}
private void buildPartialRepeatedFields(io.envoyproxy.envoy.config.route.v3.RetryPolicy result) {
if (retryHostPredicateBuilder_ == null) {
if (((bitField0_ & 0x00000020) != 0)) {
retryHostPredicate_ = java.util.Collections.unmodifiableList(retryHostPredicate_);
bitField0_ = (bitField0_ & ~0x00000020);
}
result.retryHostPredicate_ = retryHostPredicate_;
} else {
result.retryHostPredicate_ = retryHostPredicateBuilder_.build();
}
if (retryOptionsPredicatesBuilder_ == null) {
if (((bitField0_ & 0x00000040) != 0)) {
retryOptionsPredicates_ = java.util.Collections.unmodifiableList(retryOptionsPredicates_);
bitField0_ = (bitField0_ & ~0x00000040);
}
result.retryOptionsPredicates_ = retryOptionsPredicates_;
} else {
result.retryOptionsPredicates_ = retryOptionsPredicatesBuilder_.build();
}
if (retriableHeadersBuilder_ == null) {
if (((bitField0_ & 0x00000800) != 0)) {
retriableHeaders_ = java.util.Collections.unmodifiableList(retriableHeaders_);
bitField0_ = (bitField0_ & ~0x00000800);
}
result.retriableHeaders_ = retriableHeaders_;
} else {
result.retriableHeaders_ = retriableHeadersBuilder_.build();
}
if (retriableRequestHeadersBuilder_ == null) {
if (((bitField0_ & 0x00001000) != 0)) {
retriableRequestHeaders_ = java.util.Collections.unmodifiableList(retriableRequestHeaders_);
bitField0_ = (bitField0_ & ~0x00001000);
}
result.retriableRequestHeaders_ = retriableRequestHeaders_;
} else {
result.retriableRequestHeaders_ = retriableRequestHeadersBuilder_.build();
}
}
private void buildPartial0(io.envoyproxy.envoy.config.route.v3.RetryPolicy result) {
int from_bitField0_ = bitField0_;
if (((from_bitField0_ & 0x00000001) != 0)) {
result.retryOn_ = retryOn_;
}
int to_bitField0_ = 0;
if (((from_bitField0_ & 0x00000002) != 0)) {
result.numRetries_ = numRetriesBuilder_ == null
? numRetries_
: numRetriesBuilder_.build();
to_bitField0_ |= 0x00000001;
}
if (((from_bitField0_ & 0x00000004) != 0)) {
result.perTryTimeout_ = perTryTimeoutBuilder_ == null
? perTryTimeout_
: perTryTimeoutBuilder_.build();
to_bitField0_ |= 0x00000002;
}
if (((from_bitField0_ & 0x00000008) != 0)) {
result.perTryIdleTimeout_ = perTryIdleTimeoutBuilder_ == null
? perTryIdleTimeout_
: perTryIdleTimeoutBuilder_.build();
to_bitField0_ |= 0x00000004;
}
if (((from_bitField0_ & 0x00000010) != 0)) {
result.retryPriority_ = retryPriorityBuilder_ == null
? retryPriority_
: retryPriorityBuilder_.build();
to_bitField0_ |= 0x00000008;
}
if (((from_bitField0_ & 0x00000080) != 0)) {
result.hostSelectionRetryMaxAttempts_ = hostSelectionRetryMaxAttempts_;
}
if (((from_bitField0_ & 0x00000100) != 0)) {
retriableStatusCodes_.makeImmutable();
result.retriableStatusCodes_ = retriableStatusCodes_;
}
if (((from_bitField0_ & 0x00000200) != 0)) {
result.retryBackOff_ = retryBackOffBuilder_ == null
? retryBackOff_
: retryBackOffBuilder_.build();
to_bitField0_ |= 0x00000010;
}
if (((from_bitField0_ & 0x00000400) != 0)) {
result.rateLimitedRetryBackOff_ = rateLimitedRetryBackOffBuilder_ == null
? rateLimitedRetryBackOff_
: rateLimitedRetryBackOffBuilder_.build();
to_bitField0_ |= 0x00000020;
}
result.bitField0_ |= to_bitField0_;
}
@java.lang.Override
public Builder clone() {
return super.clone();
}
@java.lang.Override
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.setField(field, value);
}
@java.lang.Override
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return super.clearField(field);
}
@java.lang.Override
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return super.clearOneof(oneof);
}
@java.lang.Override
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return super.setRepeatedField(field, index, value);
}
@java.lang.Override
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.addRepeatedField(field, value);
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof io.envoyproxy.envoy.config.route.v3.RetryPolicy) {
return mergeFrom((io.envoyproxy.envoy.config.route.v3.RetryPolicy)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(io.envoyproxy.envoy.config.route.v3.RetryPolicy other) {
if (other == io.envoyproxy.envoy.config.route.v3.RetryPolicy.getDefaultInstance()) return this;
if (!other.getRetryOn().isEmpty()) {
retryOn_ = other.retryOn_;
bitField0_ |= 0x00000001;
onChanged();
}
if (other.hasNumRetries()) {
mergeNumRetries(other.getNumRetries());
}
if (other.hasPerTryTimeout()) {
mergePerTryTimeout(other.getPerTryTimeout());
}
if (other.hasPerTryIdleTimeout()) {
mergePerTryIdleTimeout(other.getPerTryIdleTimeout());
}
if (other.hasRetryPriority()) {
mergeRetryPriority(other.getRetryPriority());
}
if (retryHostPredicateBuilder_ == null) {
if (!other.retryHostPredicate_.isEmpty()) {
if (retryHostPredicate_.isEmpty()) {
retryHostPredicate_ = other.retryHostPredicate_;
bitField0_ = (bitField0_ & ~0x00000020);
} else {
ensureRetryHostPredicateIsMutable();
retryHostPredicate_.addAll(other.retryHostPredicate_);
}
onChanged();
}
} else {
if (!other.retryHostPredicate_.isEmpty()) {
if (retryHostPredicateBuilder_.isEmpty()) {
retryHostPredicateBuilder_.dispose();
retryHostPredicateBuilder_ = null;
retryHostPredicate_ = other.retryHostPredicate_;
bitField0_ = (bitField0_ & ~0x00000020);
retryHostPredicateBuilder_ =
com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ?
getRetryHostPredicateFieldBuilder() : null;
} else {
retryHostPredicateBuilder_.addAllMessages(other.retryHostPredicate_);
}
}
}
if (retryOptionsPredicatesBuilder_ == null) {
if (!other.retryOptionsPredicates_.isEmpty()) {
if (retryOptionsPredicates_.isEmpty()) {
retryOptionsPredicates_ = other.retryOptionsPredicates_;
bitField0_ = (bitField0_ & ~0x00000040);
} else {
ensureRetryOptionsPredicatesIsMutable();
retryOptionsPredicates_.addAll(other.retryOptionsPredicates_);
}
onChanged();
}
} else {
if (!other.retryOptionsPredicates_.isEmpty()) {
if (retryOptionsPredicatesBuilder_.isEmpty()) {
retryOptionsPredicatesBuilder_.dispose();
retryOptionsPredicatesBuilder_ = null;
retryOptionsPredicates_ = other.retryOptionsPredicates_;
bitField0_ = (bitField0_ & ~0x00000040);
retryOptionsPredicatesBuilder_ =
com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ?
getRetryOptionsPredicatesFieldBuilder() : null;
} else {
retryOptionsPredicatesBuilder_.addAllMessages(other.retryOptionsPredicates_);
}
}
}
if (other.getHostSelectionRetryMaxAttempts() != 0L) {
setHostSelectionRetryMaxAttempts(other.getHostSelectionRetryMaxAttempts());
}
if (!other.retriableStatusCodes_.isEmpty()) {
if (retriableStatusCodes_.isEmpty()) {
retriableStatusCodes_ = other.retriableStatusCodes_;
retriableStatusCodes_.makeImmutable();
bitField0_ |= 0x00000100;
} else {
ensureRetriableStatusCodesIsMutable();
retriableStatusCodes_.addAll(other.retriableStatusCodes_);
}
onChanged();
}
if (other.hasRetryBackOff()) {
mergeRetryBackOff(other.getRetryBackOff());
}
if (other.hasRateLimitedRetryBackOff()) {
mergeRateLimitedRetryBackOff(other.getRateLimitedRetryBackOff());
}
if (retriableHeadersBuilder_ == null) {
if (!other.retriableHeaders_.isEmpty()) {
if (retriableHeaders_.isEmpty()) {
retriableHeaders_ = other.retriableHeaders_;
bitField0_ = (bitField0_ & ~0x00000800);
} else {
ensureRetriableHeadersIsMutable();
retriableHeaders_.addAll(other.retriableHeaders_);
}
onChanged();
}
} else {
if (!other.retriableHeaders_.isEmpty()) {
if (retriableHeadersBuilder_.isEmpty()) {
retriableHeadersBuilder_.dispose();
retriableHeadersBuilder_ = null;
retriableHeaders_ = other.retriableHeaders_;
bitField0_ = (bitField0_ & ~0x00000800);
retriableHeadersBuilder_ =
com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ?
getRetriableHeadersFieldBuilder() : null;
} else {
retriableHeadersBuilder_.addAllMessages(other.retriableHeaders_);
}
}
}
if (retriableRequestHeadersBuilder_ == null) {
if (!other.retriableRequestHeaders_.isEmpty()) {
if (retriableRequestHeaders_.isEmpty()) {
retriableRequestHeaders_ = other.retriableRequestHeaders_;
bitField0_ = (bitField0_ & ~0x00001000);
} else {
ensureRetriableRequestHeadersIsMutable();
retriableRequestHeaders_.addAll(other.retriableRequestHeaders_);
}
onChanged();
}
} else {
if (!other.retriableRequestHeaders_.isEmpty()) {
if (retriableRequestHeadersBuilder_.isEmpty()) {
retriableRequestHeadersBuilder_.dispose();
retriableRequestHeadersBuilder_ = null;
retriableRequestHeaders_ = other.retriableRequestHeaders_;
bitField0_ = (bitField0_ & ~0x00001000);
retriableRequestHeadersBuilder_ =
com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ?
getRetriableRequestHeadersFieldBuilder() : null;
} else {
retriableRequestHeadersBuilder_.addAllMessages(other.retriableRequestHeaders_);
}
}
}
this.mergeUnknownFields(other.getUnknownFields());
onChanged();
return this;
}
@java.lang.Override
public final boolean isInitialized() {
return true;
}
@java.lang.Override
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
retryOn_ = input.readStringRequireUtf8();
bitField0_ |= 0x00000001;
break;
} // case 10
case 18: {
input.readMessage(
getNumRetriesFieldBuilder().getBuilder(),
extensionRegistry);
bitField0_ |= 0x00000002;
break;
} // case 18
case 26: {
input.readMessage(
getPerTryTimeoutFieldBuilder().getBuilder(),
extensionRegistry);
bitField0_ |= 0x00000004;
break;
} // case 26
case 34: {
input.readMessage(
getRetryPriorityFieldBuilder().getBuilder(),
extensionRegistry);
bitField0_ |= 0x00000010;
break;
} // case 34
case 42: {
io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicate m =
input.readMessage(
io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicate.parser(),
extensionRegistry);
if (retryHostPredicateBuilder_ == null) {
ensureRetryHostPredicateIsMutable();
retryHostPredicate_.add(m);
} else {
retryHostPredicateBuilder_.addMessage(m);
}
break;
} // case 42
case 48: {
hostSelectionRetryMaxAttempts_ = input.readInt64();
bitField0_ |= 0x00000080;
break;
} // case 48
case 56: {
int v = input.readUInt32();
ensureRetriableStatusCodesIsMutable();
retriableStatusCodes_.addInt(v);
break;
} // case 56
case 58: {
int length = input.readRawVarint32();
int limit = input.pushLimit(length);
ensureRetriableStatusCodesIsMutable();
while (input.getBytesUntilLimit() > 0) {
retriableStatusCodes_.addInt(input.readUInt32());
}
input.popLimit(limit);
break;
} // case 58
case 66: {
input.readMessage(
getRetryBackOffFieldBuilder().getBuilder(),
extensionRegistry);
bitField0_ |= 0x00000200;
break;
} // case 66
case 74: {
io.envoyproxy.envoy.config.route.v3.HeaderMatcher m =
input.readMessage(
io.envoyproxy.envoy.config.route.v3.HeaderMatcher.parser(),
extensionRegistry);
if (retriableHeadersBuilder_ == null) {
ensureRetriableHeadersIsMutable();
retriableHeaders_.add(m);
} else {
retriableHeadersBuilder_.addMessage(m);
}
break;
} // case 74
case 82: {
io.envoyproxy.envoy.config.route.v3.HeaderMatcher m =
input.readMessage(
io.envoyproxy.envoy.config.route.v3.HeaderMatcher.parser(),
extensionRegistry);
if (retriableRequestHeadersBuilder_ == null) {
ensureRetriableRequestHeadersIsMutable();
retriableRequestHeaders_.add(m);
} else {
retriableRequestHeadersBuilder_.addMessage(m);
}
break;
} // case 82
case 90: {
input.readMessage(
getRateLimitedRetryBackOffFieldBuilder().getBuilder(),
extensionRegistry);
bitField0_ |= 0x00000400;
break;
} // case 90
case 98: {
io.envoyproxy.envoy.config.core.v3.TypedExtensionConfig m =
input.readMessage(
io.envoyproxy.envoy.config.core.v3.TypedExtensionConfig.parser(),
extensionRegistry);
if (retryOptionsPredicatesBuilder_ == null) {
ensureRetryOptionsPredicatesIsMutable();
retryOptionsPredicates_.add(m);
} else {
retryOptionsPredicatesBuilder_.addMessage(m);
}
break;
} // case 98
case 106: {
input.readMessage(
getPerTryIdleTimeoutFieldBuilder().getBuilder(),
extensionRegistry);
bitField0_ |= 0x00000008;
break;
} // case 106
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.unwrapIOException();
} finally {
onChanged();
} // finally
return this;
}
private int bitField0_;
private java.lang.Object retryOn_ = "";
/**
*
* Specifies the conditions under which retry takes place. These are the same
* conditions documented for :ref:`config_http_filters_router_x-envoy-retry-on` and
* :ref:`config_http_filters_router_x-envoy-retry-grpc-on`.
*
*
* string retry_on = 1;
* @return The retryOn.
*/
public java.lang.String getRetryOn() {
java.lang.Object ref = retryOn_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
retryOn_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
*
* Specifies the conditions under which retry takes place. These are the same
* conditions documented for :ref:`config_http_filters_router_x-envoy-retry-on` and
* :ref:`config_http_filters_router_x-envoy-retry-grpc-on`.
*
*
* string retry_on = 1;
* @return The bytes for retryOn.
*/
public com.google.protobuf.ByteString
getRetryOnBytes() {
java.lang.Object ref = retryOn_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
retryOn_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
*
* Specifies the conditions under which retry takes place. These are the same
* conditions documented for :ref:`config_http_filters_router_x-envoy-retry-on` and
* :ref:`config_http_filters_router_x-envoy-retry-grpc-on`.
*
*
* string retry_on = 1;
* @param value The retryOn to set.
* @return This builder for chaining.
*/
public Builder setRetryOn(
java.lang.String value) {
if (value == null) { throw new NullPointerException(); }
retryOn_ = value;
bitField0_ |= 0x00000001;
onChanged();
return this;
}
/**
*
* Specifies the conditions under which retry takes place. These are the same
* conditions documented for :ref:`config_http_filters_router_x-envoy-retry-on` and
* :ref:`config_http_filters_router_x-envoy-retry-grpc-on`.
*
*
* string retry_on = 1;
* @return This builder for chaining.
*/
public Builder clearRetryOn() {
retryOn_ = getDefaultInstance().getRetryOn();
bitField0_ = (bitField0_ & ~0x00000001);
onChanged();
return this;
}
/**
*
* Specifies the conditions under which retry takes place. These are the same
* conditions documented for :ref:`config_http_filters_router_x-envoy-retry-on` and
* :ref:`config_http_filters_router_x-envoy-retry-grpc-on`.
*
*
* string retry_on = 1;
* @param value The bytes for retryOn to set.
* @return This builder for chaining.
*/
public Builder setRetryOnBytes(
com.google.protobuf.ByteString value) {
if (value == null) { throw new NullPointerException(); }
checkByteStringIsUtf8(value);
retryOn_ = value;
bitField0_ |= 0x00000001;
onChanged();
return this;
}
private com.google.protobuf.UInt32Value numRetries_;
private com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.UInt32Value, com.google.protobuf.UInt32Value.Builder, com.google.protobuf.UInt32ValueOrBuilder> numRetriesBuilder_;
/**
*
* Specifies the allowed number of retries. This parameter is optional and
* defaults to 1. These are the same conditions documented for
* :ref:`config_http_filters_router_x-envoy-max-retries`.
*
*
* .google.protobuf.UInt32Value num_retries = 2 [(.udpa.annotations.field_migrate) = { ... }
* @return Whether the numRetries field is set.
*/
public boolean hasNumRetries() {
return ((bitField0_ & 0x00000002) != 0);
}
/**
*
* Specifies the allowed number of retries. This parameter is optional and
* defaults to 1. These are the same conditions documented for
* :ref:`config_http_filters_router_x-envoy-max-retries`.
*
*
* .google.protobuf.UInt32Value num_retries = 2 [(.udpa.annotations.field_migrate) = { ... }
* @return The numRetries.
*/
public com.google.protobuf.UInt32Value getNumRetries() {
if (numRetriesBuilder_ == null) {
return numRetries_ == null ? com.google.protobuf.UInt32Value.getDefaultInstance() : numRetries_;
} else {
return numRetriesBuilder_.getMessage();
}
}
/**
*
* Specifies the allowed number of retries. This parameter is optional and
* defaults to 1. These are the same conditions documented for
* :ref:`config_http_filters_router_x-envoy-max-retries`.
*
*
* .google.protobuf.UInt32Value num_retries = 2 [(.udpa.annotations.field_migrate) = { ... }
*/
public Builder setNumRetries(com.google.protobuf.UInt32Value value) {
if (numRetriesBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
numRetries_ = value;
} else {
numRetriesBuilder_.setMessage(value);
}
bitField0_ |= 0x00000002;
onChanged();
return this;
}
/**
*
* Specifies the allowed number of retries. This parameter is optional and
* defaults to 1. These are the same conditions documented for
* :ref:`config_http_filters_router_x-envoy-max-retries`.
*
*
* .google.protobuf.UInt32Value num_retries = 2 [(.udpa.annotations.field_migrate) = { ... }
*/
public Builder setNumRetries(
com.google.protobuf.UInt32Value.Builder builderForValue) {
if (numRetriesBuilder_ == null) {
numRetries_ = builderForValue.build();
} else {
numRetriesBuilder_.setMessage(builderForValue.build());
}
bitField0_ |= 0x00000002;
onChanged();
return this;
}
/**
*
* Specifies the allowed number of retries. This parameter is optional and
* defaults to 1. These are the same conditions documented for
* :ref:`config_http_filters_router_x-envoy-max-retries`.
*
*
* .google.protobuf.UInt32Value num_retries = 2 [(.udpa.annotations.field_migrate) = { ... }
*/
public Builder mergeNumRetries(com.google.protobuf.UInt32Value value) {
if (numRetriesBuilder_ == null) {
if (((bitField0_ & 0x00000002) != 0) &&
numRetries_ != null &&
numRetries_ != com.google.protobuf.UInt32Value.getDefaultInstance()) {
getNumRetriesBuilder().mergeFrom(value);
} else {
numRetries_ = value;
}
} else {
numRetriesBuilder_.mergeFrom(value);
}
if (numRetries_ != null) {
bitField0_ |= 0x00000002;
onChanged();
}
return this;
}
/**
*
* Specifies the allowed number of retries. This parameter is optional and
* defaults to 1. These are the same conditions documented for
* :ref:`config_http_filters_router_x-envoy-max-retries`.
*
*
* .google.protobuf.UInt32Value num_retries = 2 [(.udpa.annotations.field_migrate) = { ... }
*/
public Builder clearNumRetries() {
bitField0_ = (bitField0_ & ~0x00000002);
numRetries_ = null;
if (numRetriesBuilder_ != null) {
numRetriesBuilder_.dispose();
numRetriesBuilder_ = null;
}
onChanged();
return this;
}
/**
*
* Specifies the allowed number of retries. This parameter is optional and
* defaults to 1. These are the same conditions documented for
* :ref:`config_http_filters_router_x-envoy-max-retries`.
*
*
* .google.protobuf.UInt32Value num_retries = 2 [(.udpa.annotations.field_migrate) = { ... }
*/
public com.google.protobuf.UInt32Value.Builder getNumRetriesBuilder() {
bitField0_ |= 0x00000002;
onChanged();
return getNumRetriesFieldBuilder().getBuilder();
}
/**
*
* Specifies the allowed number of retries. This parameter is optional and
* defaults to 1. These are the same conditions documented for
* :ref:`config_http_filters_router_x-envoy-max-retries`.
*
*
* .google.protobuf.UInt32Value num_retries = 2 [(.udpa.annotations.field_migrate) = { ... }
*/
public com.google.protobuf.UInt32ValueOrBuilder getNumRetriesOrBuilder() {
if (numRetriesBuilder_ != null) {
return numRetriesBuilder_.getMessageOrBuilder();
} else {
return numRetries_ == null ?
com.google.protobuf.UInt32Value.getDefaultInstance() : numRetries_;
}
}
/**
*
* Specifies the allowed number of retries. This parameter is optional and
* defaults to 1. These are the same conditions documented for
* :ref:`config_http_filters_router_x-envoy-max-retries`.
*
*
* .google.protobuf.UInt32Value num_retries = 2 [(.udpa.annotations.field_migrate) = { ... }
*/
private com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.UInt32Value, com.google.protobuf.UInt32Value.Builder, com.google.protobuf.UInt32ValueOrBuilder>
getNumRetriesFieldBuilder() {
if (numRetriesBuilder_ == null) {
numRetriesBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.UInt32Value, com.google.protobuf.UInt32Value.Builder, com.google.protobuf.UInt32ValueOrBuilder>(
getNumRetries(),
getParentForChildren(),
isClean());
numRetries_ = null;
}
return numRetriesBuilder_;
}
private com.google.protobuf.Duration perTryTimeout_;
private com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Duration, com.google.protobuf.Duration.Builder, com.google.protobuf.DurationOrBuilder> perTryTimeoutBuilder_;
/**
*
* Specifies a non-zero upstream timeout per retry attempt (including the initial attempt). This
* parameter is optional. The same conditions documented for
* :ref:`config_http_filters_router_x-envoy-upstream-rq-per-try-timeout-ms` apply.
*
* .. note::
*
* If left unspecified, Envoy will use the global
* :ref:`route timeout <envoy_v3_api_field_config.route.v3.RouteAction.timeout>` for the request.
* Consequently, when using a :ref:`5xx <config_http_filters_router_x-envoy-retry-on>` based
* retry policy, a request that times out will not be retried as the total timeout budget
* would have been exhausted.
*
*
* .google.protobuf.Duration per_try_timeout = 3;
* @return Whether the perTryTimeout field is set.
*/
public boolean hasPerTryTimeout() {
return ((bitField0_ & 0x00000004) != 0);
}
/**
*
* Specifies a non-zero upstream timeout per retry attempt (including the initial attempt). This
* parameter is optional. The same conditions documented for
* :ref:`config_http_filters_router_x-envoy-upstream-rq-per-try-timeout-ms` apply.
*
* .. note::
*
* If left unspecified, Envoy will use the global
* :ref:`route timeout <envoy_v3_api_field_config.route.v3.RouteAction.timeout>` for the request.
* Consequently, when using a :ref:`5xx <config_http_filters_router_x-envoy-retry-on>` based
* retry policy, a request that times out will not be retried as the total timeout budget
* would have been exhausted.
*
*
* .google.protobuf.Duration per_try_timeout = 3;
* @return The perTryTimeout.
*/
public com.google.protobuf.Duration getPerTryTimeout() {
if (perTryTimeoutBuilder_ == null) {
return perTryTimeout_ == null ? com.google.protobuf.Duration.getDefaultInstance() : perTryTimeout_;
} else {
return perTryTimeoutBuilder_.getMessage();
}
}
/**
*
* Specifies a non-zero upstream timeout per retry attempt (including the initial attempt). This
* parameter is optional. The same conditions documented for
* :ref:`config_http_filters_router_x-envoy-upstream-rq-per-try-timeout-ms` apply.
*
* .. note::
*
* If left unspecified, Envoy will use the global
* :ref:`route timeout <envoy_v3_api_field_config.route.v3.RouteAction.timeout>` for the request.
* Consequently, when using a :ref:`5xx <config_http_filters_router_x-envoy-retry-on>` based
* retry policy, a request that times out will not be retried as the total timeout budget
* would have been exhausted.
*
*
* .google.protobuf.Duration per_try_timeout = 3;
*/
public Builder setPerTryTimeout(com.google.protobuf.Duration value) {
if (perTryTimeoutBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
perTryTimeout_ = value;
} else {
perTryTimeoutBuilder_.setMessage(value);
}
bitField0_ |= 0x00000004;
onChanged();
return this;
}
/**
*
* Specifies a non-zero upstream timeout per retry attempt (including the initial attempt). This
* parameter is optional. The same conditions documented for
* :ref:`config_http_filters_router_x-envoy-upstream-rq-per-try-timeout-ms` apply.
*
* .. note::
*
* If left unspecified, Envoy will use the global
* :ref:`route timeout <envoy_v3_api_field_config.route.v3.RouteAction.timeout>` for the request.
* Consequently, when using a :ref:`5xx <config_http_filters_router_x-envoy-retry-on>` based
* retry policy, a request that times out will not be retried as the total timeout budget
* would have been exhausted.
*
*
* .google.protobuf.Duration per_try_timeout = 3;
*/
public Builder setPerTryTimeout(
com.google.protobuf.Duration.Builder builderForValue) {
if (perTryTimeoutBuilder_ == null) {
perTryTimeout_ = builderForValue.build();
} else {
perTryTimeoutBuilder_.setMessage(builderForValue.build());
}
bitField0_ |= 0x00000004;
onChanged();
return this;
}
/**
*
* Specifies a non-zero upstream timeout per retry attempt (including the initial attempt). This
* parameter is optional. The same conditions documented for
* :ref:`config_http_filters_router_x-envoy-upstream-rq-per-try-timeout-ms` apply.
*
* .. note::
*
* If left unspecified, Envoy will use the global
* :ref:`route timeout <envoy_v3_api_field_config.route.v3.RouteAction.timeout>` for the request.
* Consequently, when using a :ref:`5xx <config_http_filters_router_x-envoy-retry-on>` based
* retry policy, a request that times out will not be retried as the total timeout budget
* would have been exhausted.
*
*
* .google.protobuf.Duration per_try_timeout = 3;
*/
public Builder mergePerTryTimeout(com.google.protobuf.Duration value) {
if (perTryTimeoutBuilder_ == null) {
if (((bitField0_ & 0x00000004) != 0) &&
perTryTimeout_ != null &&
perTryTimeout_ != com.google.protobuf.Duration.getDefaultInstance()) {
getPerTryTimeoutBuilder().mergeFrom(value);
} else {
perTryTimeout_ = value;
}
} else {
perTryTimeoutBuilder_.mergeFrom(value);
}
if (perTryTimeout_ != null) {
bitField0_ |= 0x00000004;
onChanged();
}
return this;
}
/**
*
* Specifies a non-zero upstream timeout per retry attempt (including the initial attempt). This
* parameter is optional. The same conditions documented for
* :ref:`config_http_filters_router_x-envoy-upstream-rq-per-try-timeout-ms` apply.
*
* .. note::
*
* If left unspecified, Envoy will use the global
* :ref:`route timeout <envoy_v3_api_field_config.route.v3.RouteAction.timeout>` for the request.
* Consequently, when using a :ref:`5xx <config_http_filters_router_x-envoy-retry-on>` based
* retry policy, a request that times out will not be retried as the total timeout budget
* would have been exhausted.
*
*
* .google.protobuf.Duration per_try_timeout = 3;
*/
public Builder clearPerTryTimeout() {
bitField0_ = (bitField0_ & ~0x00000004);
perTryTimeout_ = null;
if (perTryTimeoutBuilder_ != null) {
perTryTimeoutBuilder_.dispose();
perTryTimeoutBuilder_ = null;
}
onChanged();
return this;
}
/**
*
* Specifies a non-zero upstream timeout per retry attempt (including the initial attempt). This
* parameter is optional. The same conditions documented for
* :ref:`config_http_filters_router_x-envoy-upstream-rq-per-try-timeout-ms` apply.
*
* .. note::
*
* If left unspecified, Envoy will use the global
* :ref:`route timeout <envoy_v3_api_field_config.route.v3.RouteAction.timeout>` for the request.
* Consequently, when using a :ref:`5xx <config_http_filters_router_x-envoy-retry-on>` based
* retry policy, a request that times out will not be retried as the total timeout budget
* would have been exhausted.
*
*
* .google.protobuf.Duration per_try_timeout = 3;
*/
public com.google.protobuf.Duration.Builder getPerTryTimeoutBuilder() {
bitField0_ |= 0x00000004;
onChanged();
return getPerTryTimeoutFieldBuilder().getBuilder();
}
/**
*
* Specifies a non-zero upstream timeout per retry attempt (including the initial attempt). This
* parameter is optional. The same conditions documented for
* :ref:`config_http_filters_router_x-envoy-upstream-rq-per-try-timeout-ms` apply.
*
* .. note::
*
* If left unspecified, Envoy will use the global
* :ref:`route timeout <envoy_v3_api_field_config.route.v3.RouteAction.timeout>` for the request.
* Consequently, when using a :ref:`5xx <config_http_filters_router_x-envoy-retry-on>` based
* retry policy, a request that times out will not be retried as the total timeout budget
* would have been exhausted.
*
*
* .google.protobuf.Duration per_try_timeout = 3;
*/
public com.google.protobuf.DurationOrBuilder getPerTryTimeoutOrBuilder() {
if (perTryTimeoutBuilder_ != null) {
return perTryTimeoutBuilder_.getMessageOrBuilder();
} else {
return perTryTimeout_ == null ?
com.google.protobuf.Duration.getDefaultInstance() : perTryTimeout_;
}
}
/**
*
* Specifies a non-zero upstream timeout per retry attempt (including the initial attempt). This
* parameter is optional. The same conditions documented for
* :ref:`config_http_filters_router_x-envoy-upstream-rq-per-try-timeout-ms` apply.
*
* .. note::
*
* If left unspecified, Envoy will use the global
* :ref:`route timeout <envoy_v3_api_field_config.route.v3.RouteAction.timeout>` for the request.
* Consequently, when using a :ref:`5xx <config_http_filters_router_x-envoy-retry-on>` based
* retry policy, a request that times out will not be retried as the total timeout budget
* would have been exhausted.
*
*
* .google.protobuf.Duration per_try_timeout = 3;
*/
private com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Duration, com.google.protobuf.Duration.Builder, com.google.protobuf.DurationOrBuilder>
getPerTryTimeoutFieldBuilder() {
if (perTryTimeoutBuilder_ == null) {
perTryTimeoutBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Duration, com.google.protobuf.Duration.Builder, com.google.protobuf.DurationOrBuilder>(
getPerTryTimeout(),
getParentForChildren(),
isClean());
perTryTimeout_ = null;
}
return perTryTimeoutBuilder_;
}
private com.google.protobuf.Duration perTryIdleTimeout_;
private com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Duration, com.google.protobuf.Duration.Builder, com.google.protobuf.DurationOrBuilder> perTryIdleTimeoutBuilder_;
/**
*
* Specifies an upstream idle timeout per retry attempt (including the initial attempt). This
* parameter is optional and if absent there is no per try idle timeout. The semantics of the per
* try idle timeout are similar to the
* :ref:`route idle timeout <envoy_v3_api_field_config.route.v3.RouteAction.timeout>` and
* :ref:`stream idle timeout
* <envoy_v3_api_field_extensions.filters.network.http_connection_manager.v3.HttpConnectionManager.stream_idle_timeout>`
* both enforced by the HTTP connection manager. The difference is that this idle timeout
* is enforced by the router for each individual attempt and thus after all previous filters have
* run, as opposed to *before* all previous filters run for the other idle timeouts. This timeout
* is useful in cases in which total request timeout is bounded by a number of retries and a
* :ref:`per_try_timeout <envoy_v3_api_field_config.route.v3.RetryPolicy.per_try_timeout>`, but
* there is a desire to ensure each try is making incremental progress. Note also that similar
* to :ref:`per_try_timeout <envoy_v3_api_field_config.route.v3.RetryPolicy.per_try_timeout>`,
* this idle timeout does not start until after both the entire request has been received by the
* router *and* a connection pool connection has been obtained. Unlike
* :ref:`per_try_timeout <envoy_v3_api_field_config.route.v3.RetryPolicy.per_try_timeout>`,
* the idle timer continues once the response starts streaming back to the downstream client.
* This ensures that response data continues to make progress without using one of the HTTP
* connection manager idle timeouts.
*
*
* .google.protobuf.Duration per_try_idle_timeout = 13;
* @return Whether the perTryIdleTimeout field is set.
*/
public boolean hasPerTryIdleTimeout() {
return ((bitField0_ & 0x00000008) != 0);
}
/**
*
* Specifies an upstream idle timeout per retry attempt (including the initial attempt). This
* parameter is optional and if absent there is no per try idle timeout. The semantics of the per
* try idle timeout are similar to the
* :ref:`route idle timeout <envoy_v3_api_field_config.route.v3.RouteAction.timeout>` and
* :ref:`stream idle timeout
* <envoy_v3_api_field_extensions.filters.network.http_connection_manager.v3.HttpConnectionManager.stream_idle_timeout>`
* both enforced by the HTTP connection manager. The difference is that this idle timeout
* is enforced by the router for each individual attempt and thus after all previous filters have
* run, as opposed to *before* all previous filters run for the other idle timeouts. This timeout
* is useful in cases in which total request timeout is bounded by a number of retries and a
* :ref:`per_try_timeout <envoy_v3_api_field_config.route.v3.RetryPolicy.per_try_timeout>`, but
* there is a desire to ensure each try is making incremental progress. Note also that similar
* to :ref:`per_try_timeout <envoy_v3_api_field_config.route.v3.RetryPolicy.per_try_timeout>`,
* this idle timeout does not start until after both the entire request has been received by the
* router *and* a connection pool connection has been obtained. Unlike
* :ref:`per_try_timeout <envoy_v3_api_field_config.route.v3.RetryPolicy.per_try_timeout>`,
* the idle timer continues once the response starts streaming back to the downstream client.
* This ensures that response data continues to make progress without using one of the HTTP
* connection manager idle timeouts.
*
*
* .google.protobuf.Duration per_try_idle_timeout = 13;
* @return The perTryIdleTimeout.
*/
public com.google.protobuf.Duration getPerTryIdleTimeout() {
if (perTryIdleTimeoutBuilder_ == null) {
return perTryIdleTimeout_ == null ? com.google.protobuf.Duration.getDefaultInstance() : perTryIdleTimeout_;
} else {
return perTryIdleTimeoutBuilder_.getMessage();
}
}
/**
*
* Specifies an upstream idle timeout per retry attempt (including the initial attempt). This
* parameter is optional and if absent there is no per try idle timeout. The semantics of the per
* try idle timeout are similar to the
* :ref:`route idle timeout <envoy_v3_api_field_config.route.v3.RouteAction.timeout>` and
* :ref:`stream idle timeout
* <envoy_v3_api_field_extensions.filters.network.http_connection_manager.v3.HttpConnectionManager.stream_idle_timeout>`
* both enforced by the HTTP connection manager. The difference is that this idle timeout
* is enforced by the router for each individual attempt and thus after all previous filters have
* run, as opposed to *before* all previous filters run for the other idle timeouts. This timeout
* is useful in cases in which total request timeout is bounded by a number of retries and a
* :ref:`per_try_timeout <envoy_v3_api_field_config.route.v3.RetryPolicy.per_try_timeout>`, but
* there is a desire to ensure each try is making incremental progress. Note also that similar
* to :ref:`per_try_timeout <envoy_v3_api_field_config.route.v3.RetryPolicy.per_try_timeout>`,
* this idle timeout does not start until after both the entire request has been received by the
* router *and* a connection pool connection has been obtained. Unlike
* :ref:`per_try_timeout <envoy_v3_api_field_config.route.v3.RetryPolicy.per_try_timeout>`,
* the idle timer continues once the response starts streaming back to the downstream client.
* This ensures that response data continues to make progress without using one of the HTTP
* connection manager idle timeouts.
*
*
* .google.protobuf.Duration per_try_idle_timeout = 13;
*/
public Builder setPerTryIdleTimeout(com.google.protobuf.Duration value) {
if (perTryIdleTimeoutBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
perTryIdleTimeout_ = value;
} else {
perTryIdleTimeoutBuilder_.setMessage(value);
}
bitField0_ |= 0x00000008;
onChanged();
return this;
}
/**
*
* Specifies an upstream idle timeout per retry attempt (including the initial attempt). This
* parameter is optional and if absent there is no per try idle timeout. The semantics of the per
* try idle timeout are similar to the
* :ref:`route idle timeout <envoy_v3_api_field_config.route.v3.RouteAction.timeout>` and
* :ref:`stream idle timeout
* <envoy_v3_api_field_extensions.filters.network.http_connection_manager.v3.HttpConnectionManager.stream_idle_timeout>`
* both enforced by the HTTP connection manager. The difference is that this idle timeout
* is enforced by the router for each individual attempt and thus after all previous filters have
* run, as opposed to *before* all previous filters run for the other idle timeouts. This timeout
* is useful in cases in which total request timeout is bounded by a number of retries and a
* :ref:`per_try_timeout <envoy_v3_api_field_config.route.v3.RetryPolicy.per_try_timeout>`, but
* there is a desire to ensure each try is making incremental progress. Note also that similar
* to :ref:`per_try_timeout <envoy_v3_api_field_config.route.v3.RetryPolicy.per_try_timeout>`,
* this idle timeout does not start until after both the entire request has been received by the
* router *and* a connection pool connection has been obtained. Unlike
* :ref:`per_try_timeout <envoy_v3_api_field_config.route.v3.RetryPolicy.per_try_timeout>`,
* the idle timer continues once the response starts streaming back to the downstream client.
* This ensures that response data continues to make progress without using one of the HTTP
* connection manager idle timeouts.
*
*
* .google.protobuf.Duration per_try_idle_timeout = 13;
*/
public Builder setPerTryIdleTimeout(
com.google.protobuf.Duration.Builder builderForValue) {
if (perTryIdleTimeoutBuilder_ == null) {
perTryIdleTimeout_ = builderForValue.build();
} else {
perTryIdleTimeoutBuilder_.setMessage(builderForValue.build());
}
bitField0_ |= 0x00000008;
onChanged();
return this;
}
/**
*
* Specifies an upstream idle timeout per retry attempt (including the initial attempt). This
* parameter is optional and if absent there is no per try idle timeout. The semantics of the per
* try idle timeout are similar to the
* :ref:`route idle timeout <envoy_v3_api_field_config.route.v3.RouteAction.timeout>` and
* :ref:`stream idle timeout
* <envoy_v3_api_field_extensions.filters.network.http_connection_manager.v3.HttpConnectionManager.stream_idle_timeout>`
* both enforced by the HTTP connection manager. The difference is that this idle timeout
* is enforced by the router for each individual attempt and thus after all previous filters have
* run, as opposed to *before* all previous filters run for the other idle timeouts. This timeout
* is useful in cases in which total request timeout is bounded by a number of retries and a
* :ref:`per_try_timeout <envoy_v3_api_field_config.route.v3.RetryPolicy.per_try_timeout>`, but
* there is a desire to ensure each try is making incremental progress. Note also that similar
* to :ref:`per_try_timeout <envoy_v3_api_field_config.route.v3.RetryPolicy.per_try_timeout>`,
* this idle timeout does not start until after both the entire request has been received by the
* router *and* a connection pool connection has been obtained. Unlike
* :ref:`per_try_timeout <envoy_v3_api_field_config.route.v3.RetryPolicy.per_try_timeout>`,
* the idle timer continues once the response starts streaming back to the downstream client.
* This ensures that response data continues to make progress without using one of the HTTP
* connection manager idle timeouts.
*
*
* .google.protobuf.Duration per_try_idle_timeout = 13;
*/
public Builder mergePerTryIdleTimeout(com.google.protobuf.Duration value) {
if (perTryIdleTimeoutBuilder_ == null) {
if (((bitField0_ & 0x00000008) != 0) &&
perTryIdleTimeout_ != null &&
perTryIdleTimeout_ != com.google.protobuf.Duration.getDefaultInstance()) {
getPerTryIdleTimeoutBuilder().mergeFrom(value);
} else {
perTryIdleTimeout_ = value;
}
} else {
perTryIdleTimeoutBuilder_.mergeFrom(value);
}
if (perTryIdleTimeout_ != null) {
bitField0_ |= 0x00000008;
onChanged();
}
return this;
}
/**
*
* Specifies an upstream idle timeout per retry attempt (including the initial attempt). This
* parameter is optional and if absent there is no per try idle timeout. The semantics of the per
* try idle timeout are similar to the
* :ref:`route idle timeout <envoy_v3_api_field_config.route.v3.RouteAction.timeout>` and
* :ref:`stream idle timeout
* <envoy_v3_api_field_extensions.filters.network.http_connection_manager.v3.HttpConnectionManager.stream_idle_timeout>`
* both enforced by the HTTP connection manager. The difference is that this idle timeout
* is enforced by the router for each individual attempt and thus after all previous filters have
* run, as opposed to *before* all previous filters run for the other idle timeouts. This timeout
* is useful in cases in which total request timeout is bounded by a number of retries and a
* :ref:`per_try_timeout <envoy_v3_api_field_config.route.v3.RetryPolicy.per_try_timeout>`, but
* there is a desire to ensure each try is making incremental progress. Note also that similar
* to :ref:`per_try_timeout <envoy_v3_api_field_config.route.v3.RetryPolicy.per_try_timeout>`,
* this idle timeout does not start until after both the entire request has been received by the
* router *and* a connection pool connection has been obtained. Unlike
* :ref:`per_try_timeout <envoy_v3_api_field_config.route.v3.RetryPolicy.per_try_timeout>`,
* the idle timer continues once the response starts streaming back to the downstream client.
* This ensures that response data continues to make progress without using one of the HTTP
* connection manager idle timeouts.
*
*
* .google.protobuf.Duration per_try_idle_timeout = 13;
*/
public Builder clearPerTryIdleTimeout() {
bitField0_ = (bitField0_ & ~0x00000008);
perTryIdleTimeout_ = null;
if (perTryIdleTimeoutBuilder_ != null) {
perTryIdleTimeoutBuilder_.dispose();
perTryIdleTimeoutBuilder_ = null;
}
onChanged();
return this;
}
/**
*
* Specifies an upstream idle timeout per retry attempt (including the initial attempt). This
* parameter is optional and if absent there is no per try idle timeout. The semantics of the per
* try idle timeout are similar to the
* :ref:`route idle timeout <envoy_v3_api_field_config.route.v3.RouteAction.timeout>` and
* :ref:`stream idle timeout
* <envoy_v3_api_field_extensions.filters.network.http_connection_manager.v3.HttpConnectionManager.stream_idle_timeout>`
* both enforced by the HTTP connection manager. The difference is that this idle timeout
* is enforced by the router for each individual attempt and thus after all previous filters have
* run, as opposed to *before* all previous filters run for the other idle timeouts. This timeout
* is useful in cases in which total request timeout is bounded by a number of retries and a
* :ref:`per_try_timeout <envoy_v3_api_field_config.route.v3.RetryPolicy.per_try_timeout>`, but
* there is a desire to ensure each try is making incremental progress. Note also that similar
* to :ref:`per_try_timeout <envoy_v3_api_field_config.route.v3.RetryPolicy.per_try_timeout>`,
* this idle timeout does not start until after both the entire request has been received by the
* router *and* a connection pool connection has been obtained. Unlike
* :ref:`per_try_timeout <envoy_v3_api_field_config.route.v3.RetryPolicy.per_try_timeout>`,
* the idle timer continues once the response starts streaming back to the downstream client.
* This ensures that response data continues to make progress without using one of the HTTP
* connection manager idle timeouts.
*
*
* .google.protobuf.Duration per_try_idle_timeout = 13;
*/
public com.google.protobuf.Duration.Builder getPerTryIdleTimeoutBuilder() {
bitField0_ |= 0x00000008;
onChanged();
return getPerTryIdleTimeoutFieldBuilder().getBuilder();
}
/**
*
* Specifies an upstream idle timeout per retry attempt (including the initial attempt). This
* parameter is optional and if absent there is no per try idle timeout. The semantics of the per
* try idle timeout are similar to the
* :ref:`route idle timeout <envoy_v3_api_field_config.route.v3.RouteAction.timeout>` and
* :ref:`stream idle timeout
* <envoy_v3_api_field_extensions.filters.network.http_connection_manager.v3.HttpConnectionManager.stream_idle_timeout>`
* both enforced by the HTTP connection manager. The difference is that this idle timeout
* is enforced by the router for each individual attempt and thus after all previous filters have
* run, as opposed to *before* all previous filters run for the other idle timeouts. This timeout
* is useful in cases in which total request timeout is bounded by a number of retries and a
* :ref:`per_try_timeout <envoy_v3_api_field_config.route.v3.RetryPolicy.per_try_timeout>`, but
* there is a desire to ensure each try is making incremental progress. Note also that similar
* to :ref:`per_try_timeout <envoy_v3_api_field_config.route.v3.RetryPolicy.per_try_timeout>`,
* this idle timeout does not start until after both the entire request has been received by the
* router *and* a connection pool connection has been obtained. Unlike
* :ref:`per_try_timeout <envoy_v3_api_field_config.route.v3.RetryPolicy.per_try_timeout>`,
* the idle timer continues once the response starts streaming back to the downstream client.
* This ensures that response data continues to make progress without using one of the HTTP
* connection manager idle timeouts.
*
*
* .google.protobuf.Duration per_try_idle_timeout = 13;
*/
public com.google.protobuf.DurationOrBuilder getPerTryIdleTimeoutOrBuilder() {
if (perTryIdleTimeoutBuilder_ != null) {
return perTryIdleTimeoutBuilder_.getMessageOrBuilder();
} else {
return perTryIdleTimeout_ == null ?
com.google.protobuf.Duration.getDefaultInstance() : perTryIdleTimeout_;
}
}
/**
*
* Specifies an upstream idle timeout per retry attempt (including the initial attempt). This
* parameter is optional and if absent there is no per try idle timeout. The semantics of the per
* try idle timeout are similar to the
* :ref:`route idle timeout <envoy_v3_api_field_config.route.v3.RouteAction.timeout>` and
* :ref:`stream idle timeout
* <envoy_v3_api_field_extensions.filters.network.http_connection_manager.v3.HttpConnectionManager.stream_idle_timeout>`
* both enforced by the HTTP connection manager. The difference is that this idle timeout
* is enforced by the router for each individual attempt and thus after all previous filters have
* run, as opposed to *before* all previous filters run for the other idle timeouts. This timeout
* is useful in cases in which total request timeout is bounded by a number of retries and a
* :ref:`per_try_timeout <envoy_v3_api_field_config.route.v3.RetryPolicy.per_try_timeout>`, but
* there is a desire to ensure each try is making incremental progress. Note also that similar
* to :ref:`per_try_timeout <envoy_v3_api_field_config.route.v3.RetryPolicy.per_try_timeout>`,
* this idle timeout does not start until after both the entire request has been received by the
* router *and* a connection pool connection has been obtained. Unlike
* :ref:`per_try_timeout <envoy_v3_api_field_config.route.v3.RetryPolicy.per_try_timeout>`,
* the idle timer continues once the response starts streaming back to the downstream client.
* This ensures that response data continues to make progress without using one of the HTTP
* connection manager idle timeouts.
*
*
* .google.protobuf.Duration per_try_idle_timeout = 13;
*/
private com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Duration, com.google.protobuf.Duration.Builder, com.google.protobuf.DurationOrBuilder>
getPerTryIdleTimeoutFieldBuilder() {
if (perTryIdleTimeoutBuilder_ == null) {
perTryIdleTimeoutBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Duration, com.google.protobuf.Duration.Builder, com.google.protobuf.DurationOrBuilder>(
getPerTryIdleTimeout(),
getParentForChildren(),
isClean());
perTryIdleTimeout_ = null;
}
return perTryIdleTimeoutBuilder_;
}
private io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryPriority retryPriority_;
private com.google.protobuf.SingleFieldBuilderV3<
io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryPriority, io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryPriority.Builder, io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryPriorityOrBuilder> retryPriorityBuilder_;
/**
*
* Specifies an implementation of a RetryPriority which is used to determine the
* distribution of load across priorities used for retries. Refer to
* :ref:`retry plugin configuration <arch_overview_http_retry_plugins>` for more details.
*
*
* .envoy.config.route.v3.RetryPolicy.RetryPriority retry_priority = 4;
* @return Whether the retryPriority field is set.
*/
public boolean hasRetryPriority() {
return ((bitField0_ & 0x00000010) != 0);
}
/**
*
* Specifies an implementation of a RetryPriority which is used to determine the
* distribution of load across priorities used for retries. Refer to
* :ref:`retry plugin configuration <arch_overview_http_retry_plugins>` for more details.
*
*
* .envoy.config.route.v3.RetryPolicy.RetryPriority retry_priority = 4;
* @return The retryPriority.
*/
public io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryPriority getRetryPriority() {
if (retryPriorityBuilder_ == null) {
return retryPriority_ == null ? io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryPriority.getDefaultInstance() : retryPriority_;
} else {
return retryPriorityBuilder_.getMessage();
}
}
/**
*
* Specifies an implementation of a RetryPriority which is used to determine the
* distribution of load across priorities used for retries. Refer to
* :ref:`retry plugin configuration <arch_overview_http_retry_plugins>` for more details.
*
*
* .envoy.config.route.v3.RetryPolicy.RetryPriority retry_priority = 4;
*/
public Builder setRetryPriority(io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryPriority value) {
if (retryPriorityBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
retryPriority_ = value;
} else {
retryPriorityBuilder_.setMessage(value);
}
bitField0_ |= 0x00000010;
onChanged();
return this;
}
/**
*
* Specifies an implementation of a RetryPriority which is used to determine the
* distribution of load across priorities used for retries. Refer to
* :ref:`retry plugin configuration <arch_overview_http_retry_plugins>` for more details.
*
*
* .envoy.config.route.v3.RetryPolicy.RetryPriority retry_priority = 4;
*/
public Builder setRetryPriority(
io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryPriority.Builder builderForValue) {
if (retryPriorityBuilder_ == null) {
retryPriority_ = builderForValue.build();
} else {
retryPriorityBuilder_.setMessage(builderForValue.build());
}
bitField0_ |= 0x00000010;
onChanged();
return this;
}
/**
*
* Specifies an implementation of a RetryPriority which is used to determine the
* distribution of load across priorities used for retries. Refer to
* :ref:`retry plugin configuration <arch_overview_http_retry_plugins>` for more details.
*
*
* .envoy.config.route.v3.RetryPolicy.RetryPriority retry_priority = 4;
*/
public Builder mergeRetryPriority(io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryPriority value) {
if (retryPriorityBuilder_ == null) {
if (((bitField0_ & 0x00000010) != 0) &&
retryPriority_ != null &&
retryPriority_ != io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryPriority.getDefaultInstance()) {
getRetryPriorityBuilder().mergeFrom(value);
} else {
retryPriority_ = value;
}
} else {
retryPriorityBuilder_.mergeFrom(value);
}
if (retryPriority_ != null) {
bitField0_ |= 0x00000010;
onChanged();
}
return this;
}
/**
*
* Specifies an implementation of a RetryPriority which is used to determine the
* distribution of load across priorities used for retries. Refer to
* :ref:`retry plugin configuration <arch_overview_http_retry_plugins>` for more details.
*
*
* .envoy.config.route.v3.RetryPolicy.RetryPriority retry_priority = 4;
*/
public Builder clearRetryPriority() {
bitField0_ = (bitField0_ & ~0x00000010);
retryPriority_ = null;
if (retryPriorityBuilder_ != null) {
retryPriorityBuilder_.dispose();
retryPriorityBuilder_ = null;
}
onChanged();
return this;
}
/**
*
* Specifies an implementation of a RetryPriority which is used to determine the
* distribution of load across priorities used for retries. Refer to
* :ref:`retry plugin configuration <arch_overview_http_retry_plugins>` for more details.
*
*
* .envoy.config.route.v3.RetryPolicy.RetryPriority retry_priority = 4;
*/
public io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryPriority.Builder getRetryPriorityBuilder() {
bitField0_ |= 0x00000010;
onChanged();
return getRetryPriorityFieldBuilder().getBuilder();
}
/**
*
* Specifies an implementation of a RetryPriority which is used to determine the
* distribution of load across priorities used for retries. Refer to
* :ref:`retry plugin configuration <arch_overview_http_retry_plugins>` for more details.
*
*
* .envoy.config.route.v3.RetryPolicy.RetryPriority retry_priority = 4;
*/
public io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryPriorityOrBuilder getRetryPriorityOrBuilder() {
if (retryPriorityBuilder_ != null) {
return retryPriorityBuilder_.getMessageOrBuilder();
} else {
return retryPriority_ == null ?
io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryPriority.getDefaultInstance() : retryPriority_;
}
}
/**
*
* Specifies an implementation of a RetryPriority which is used to determine the
* distribution of load across priorities used for retries. Refer to
* :ref:`retry plugin configuration <arch_overview_http_retry_plugins>` for more details.
*
*
* .envoy.config.route.v3.RetryPolicy.RetryPriority retry_priority = 4;
*/
private com.google.protobuf.SingleFieldBuilderV3<
io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryPriority, io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryPriority.Builder, io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryPriorityOrBuilder>
getRetryPriorityFieldBuilder() {
if (retryPriorityBuilder_ == null) {
retryPriorityBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryPriority, io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryPriority.Builder, io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryPriorityOrBuilder>(
getRetryPriority(),
getParentForChildren(),
isClean());
retryPriority_ = null;
}
return retryPriorityBuilder_;
}
private java.util.List retryHostPredicate_ =
java.util.Collections.emptyList();
private void ensureRetryHostPredicateIsMutable() {
if (!((bitField0_ & 0x00000020) != 0)) {
retryHostPredicate_ = new java.util.ArrayList(retryHostPredicate_);
bitField0_ |= 0x00000020;
}
}
private com.google.protobuf.RepeatedFieldBuilderV3<
io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicate, io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicate.Builder, io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicateOrBuilder> retryHostPredicateBuilder_;
/**
*
* Specifies a collection of RetryHostPredicates that will be consulted when selecting a host
* for retries. If any of the predicates reject the host, host selection will be reattempted.
* Refer to :ref:`retry plugin configuration <arch_overview_http_retry_plugins>` for more
* details.
*
*
* repeated .envoy.config.route.v3.RetryPolicy.RetryHostPredicate retry_host_predicate = 5;
*/
public java.util.List getRetryHostPredicateList() {
if (retryHostPredicateBuilder_ == null) {
return java.util.Collections.unmodifiableList(retryHostPredicate_);
} else {
return retryHostPredicateBuilder_.getMessageList();
}
}
/**
*
* Specifies a collection of RetryHostPredicates that will be consulted when selecting a host
* for retries. If any of the predicates reject the host, host selection will be reattempted.
* Refer to :ref:`retry plugin configuration <arch_overview_http_retry_plugins>` for more
* details.
*
*
* repeated .envoy.config.route.v3.RetryPolicy.RetryHostPredicate retry_host_predicate = 5;
*/
public int getRetryHostPredicateCount() {
if (retryHostPredicateBuilder_ == null) {
return retryHostPredicate_.size();
} else {
return retryHostPredicateBuilder_.getCount();
}
}
/**
*
* Specifies a collection of RetryHostPredicates that will be consulted when selecting a host
* for retries. If any of the predicates reject the host, host selection will be reattempted.
* Refer to :ref:`retry plugin configuration <arch_overview_http_retry_plugins>` for more
* details.
*
*
* repeated .envoy.config.route.v3.RetryPolicy.RetryHostPredicate retry_host_predicate = 5;
*/
public io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicate getRetryHostPredicate(int index) {
if (retryHostPredicateBuilder_ == null) {
return retryHostPredicate_.get(index);
} else {
return retryHostPredicateBuilder_.getMessage(index);
}
}
/**
*
* Specifies a collection of RetryHostPredicates that will be consulted when selecting a host
* for retries. If any of the predicates reject the host, host selection will be reattempted.
* Refer to :ref:`retry plugin configuration <arch_overview_http_retry_plugins>` for more
* details.
*
*
* repeated .envoy.config.route.v3.RetryPolicy.RetryHostPredicate retry_host_predicate = 5;
*/
public Builder setRetryHostPredicate(
int index, io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicate value) {
if (retryHostPredicateBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureRetryHostPredicateIsMutable();
retryHostPredicate_.set(index, value);
onChanged();
} else {
retryHostPredicateBuilder_.setMessage(index, value);
}
return this;
}
/**
*
* Specifies a collection of RetryHostPredicates that will be consulted when selecting a host
* for retries. If any of the predicates reject the host, host selection will be reattempted.
* Refer to :ref:`retry plugin configuration <arch_overview_http_retry_plugins>` for more
* details.
*
*
* repeated .envoy.config.route.v3.RetryPolicy.RetryHostPredicate retry_host_predicate = 5;
*/
public Builder setRetryHostPredicate(
int index, io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicate.Builder builderForValue) {
if (retryHostPredicateBuilder_ == null) {
ensureRetryHostPredicateIsMutable();
retryHostPredicate_.set(index, builderForValue.build());
onChanged();
} else {
retryHostPredicateBuilder_.setMessage(index, builderForValue.build());
}
return this;
}
/**
*
* Specifies a collection of RetryHostPredicates that will be consulted when selecting a host
* for retries. If any of the predicates reject the host, host selection will be reattempted.
* Refer to :ref:`retry plugin configuration <arch_overview_http_retry_plugins>` for more
* details.
*
*
* repeated .envoy.config.route.v3.RetryPolicy.RetryHostPredicate retry_host_predicate = 5;
*/
public Builder addRetryHostPredicate(io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicate value) {
if (retryHostPredicateBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureRetryHostPredicateIsMutable();
retryHostPredicate_.add(value);
onChanged();
} else {
retryHostPredicateBuilder_.addMessage(value);
}
return this;
}
/**
*
* Specifies a collection of RetryHostPredicates that will be consulted when selecting a host
* for retries. If any of the predicates reject the host, host selection will be reattempted.
* Refer to :ref:`retry plugin configuration <arch_overview_http_retry_plugins>` for more
* details.
*
*
* repeated .envoy.config.route.v3.RetryPolicy.RetryHostPredicate retry_host_predicate = 5;
*/
public Builder addRetryHostPredicate(
int index, io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicate value) {
if (retryHostPredicateBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureRetryHostPredicateIsMutable();
retryHostPredicate_.add(index, value);
onChanged();
} else {
retryHostPredicateBuilder_.addMessage(index, value);
}
return this;
}
/**
*
* Specifies a collection of RetryHostPredicates that will be consulted when selecting a host
* for retries. If any of the predicates reject the host, host selection will be reattempted.
* Refer to :ref:`retry plugin configuration <arch_overview_http_retry_plugins>` for more
* details.
*
*
* repeated .envoy.config.route.v3.RetryPolicy.RetryHostPredicate retry_host_predicate = 5;
*/
public Builder addRetryHostPredicate(
io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicate.Builder builderForValue) {
if (retryHostPredicateBuilder_ == null) {
ensureRetryHostPredicateIsMutable();
retryHostPredicate_.add(builderForValue.build());
onChanged();
} else {
retryHostPredicateBuilder_.addMessage(builderForValue.build());
}
return this;
}
/**
*
* Specifies a collection of RetryHostPredicates that will be consulted when selecting a host
* for retries. If any of the predicates reject the host, host selection will be reattempted.
* Refer to :ref:`retry plugin configuration <arch_overview_http_retry_plugins>` for more
* details.
*
*
* repeated .envoy.config.route.v3.RetryPolicy.RetryHostPredicate retry_host_predicate = 5;
*/
public Builder addRetryHostPredicate(
int index, io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicate.Builder builderForValue) {
if (retryHostPredicateBuilder_ == null) {
ensureRetryHostPredicateIsMutable();
retryHostPredicate_.add(index, builderForValue.build());
onChanged();
} else {
retryHostPredicateBuilder_.addMessage(index, builderForValue.build());
}
return this;
}
/**
*
* Specifies a collection of RetryHostPredicates that will be consulted when selecting a host
* for retries. If any of the predicates reject the host, host selection will be reattempted.
* Refer to :ref:`retry plugin configuration <arch_overview_http_retry_plugins>` for more
* details.
*
*
* repeated .envoy.config.route.v3.RetryPolicy.RetryHostPredicate retry_host_predicate = 5;
*/
public Builder addAllRetryHostPredicate(
java.lang.Iterable extends io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicate> values) {
if (retryHostPredicateBuilder_ == null) {
ensureRetryHostPredicateIsMutable();
com.google.protobuf.AbstractMessageLite.Builder.addAll(
values, retryHostPredicate_);
onChanged();
} else {
retryHostPredicateBuilder_.addAllMessages(values);
}
return this;
}
/**
*
* Specifies a collection of RetryHostPredicates that will be consulted when selecting a host
* for retries. If any of the predicates reject the host, host selection will be reattempted.
* Refer to :ref:`retry plugin configuration <arch_overview_http_retry_plugins>` for more
* details.
*
*
* repeated .envoy.config.route.v3.RetryPolicy.RetryHostPredicate retry_host_predicate = 5;
*/
public Builder clearRetryHostPredicate() {
if (retryHostPredicateBuilder_ == null) {
retryHostPredicate_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000020);
onChanged();
} else {
retryHostPredicateBuilder_.clear();
}
return this;
}
/**
*
* Specifies a collection of RetryHostPredicates that will be consulted when selecting a host
* for retries. If any of the predicates reject the host, host selection will be reattempted.
* Refer to :ref:`retry plugin configuration <arch_overview_http_retry_plugins>` for more
* details.
*
*
* repeated .envoy.config.route.v3.RetryPolicy.RetryHostPredicate retry_host_predicate = 5;
*/
public Builder removeRetryHostPredicate(int index) {
if (retryHostPredicateBuilder_ == null) {
ensureRetryHostPredicateIsMutable();
retryHostPredicate_.remove(index);
onChanged();
} else {
retryHostPredicateBuilder_.remove(index);
}
return this;
}
/**
*
* Specifies a collection of RetryHostPredicates that will be consulted when selecting a host
* for retries. If any of the predicates reject the host, host selection will be reattempted.
* Refer to :ref:`retry plugin configuration <arch_overview_http_retry_plugins>` for more
* details.
*
*
* repeated .envoy.config.route.v3.RetryPolicy.RetryHostPredicate retry_host_predicate = 5;
*/
public io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicate.Builder getRetryHostPredicateBuilder(
int index) {
return getRetryHostPredicateFieldBuilder().getBuilder(index);
}
/**
*
* Specifies a collection of RetryHostPredicates that will be consulted when selecting a host
* for retries. If any of the predicates reject the host, host selection will be reattempted.
* Refer to :ref:`retry plugin configuration <arch_overview_http_retry_plugins>` for more
* details.
*
*
* repeated .envoy.config.route.v3.RetryPolicy.RetryHostPredicate retry_host_predicate = 5;
*/
public io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicateOrBuilder getRetryHostPredicateOrBuilder(
int index) {
if (retryHostPredicateBuilder_ == null) {
return retryHostPredicate_.get(index); } else {
return retryHostPredicateBuilder_.getMessageOrBuilder(index);
}
}
/**
*
* Specifies a collection of RetryHostPredicates that will be consulted when selecting a host
* for retries. If any of the predicates reject the host, host selection will be reattempted.
* Refer to :ref:`retry plugin configuration <arch_overview_http_retry_plugins>` for more
* details.
*
*
* repeated .envoy.config.route.v3.RetryPolicy.RetryHostPredicate retry_host_predicate = 5;
*/
public java.util.List extends io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicateOrBuilder>
getRetryHostPredicateOrBuilderList() {
if (retryHostPredicateBuilder_ != null) {
return retryHostPredicateBuilder_.getMessageOrBuilderList();
} else {
return java.util.Collections.unmodifiableList(retryHostPredicate_);
}
}
/**
*
* Specifies a collection of RetryHostPredicates that will be consulted when selecting a host
* for retries. If any of the predicates reject the host, host selection will be reattempted.
* Refer to :ref:`retry plugin configuration <arch_overview_http_retry_plugins>` for more
* details.
*
*
* repeated .envoy.config.route.v3.RetryPolicy.RetryHostPredicate retry_host_predicate = 5;
*/
public io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicate.Builder addRetryHostPredicateBuilder() {
return getRetryHostPredicateFieldBuilder().addBuilder(
io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicate.getDefaultInstance());
}
/**
*
* Specifies a collection of RetryHostPredicates that will be consulted when selecting a host
* for retries. If any of the predicates reject the host, host selection will be reattempted.
* Refer to :ref:`retry plugin configuration <arch_overview_http_retry_plugins>` for more
* details.
*
*
* repeated .envoy.config.route.v3.RetryPolicy.RetryHostPredicate retry_host_predicate = 5;
*/
public io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicate.Builder addRetryHostPredicateBuilder(
int index) {
return getRetryHostPredicateFieldBuilder().addBuilder(
index, io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicate.getDefaultInstance());
}
/**
*
* Specifies a collection of RetryHostPredicates that will be consulted when selecting a host
* for retries. If any of the predicates reject the host, host selection will be reattempted.
* Refer to :ref:`retry plugin configuration <arch_overview_http_retry_plugins>` for more
* details.
*
*
* repeated .envoy.config.route.v3.RetryPolicy.RetryHostPredicate retry_host_predicate = 5;
*/
public java.util.List
getRetryHostPredicateBuilderList() {
return getRetryHostPredicateFieldBuilder().getBuilderList();
}
private com.google.protobuf.RepeatedFieldBuilderV3<
io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicate, io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicate.Builder, io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicateOrBuilder>
getRetryHostPredicateFieldBuilder() {
if (retryHostPredicateBuilder_ == null) {
retryHostPredicateBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3<
io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicate, io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicate.Builder, io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryHostPredicateOrBuilder>(
retryHostPredicate_,
((bitField0_ & 0x00000020) != 0),
getParentForChildren(),
isClean());
retryHostPredicate_ = null;
}
return retryHostPredicateBuilder_;
}
private java.util.List retryOptionsPredicates_ =
java.util.Collections.emptyList();
private void ensureRetryOptionsPredicatesIsMutable() {
if (!((bitField0_ & 0x00000040) != 0)) {
retryOptionsPredicates_ = new java.util.ArrayList(retryOptionsPredicates_);
bitField0_ |= 0x00000040;
}
}
private com.google.protobuf.RepeatedFieldBuilderV3<
io.envoyproxy.envoy.config.core.v3.TypedExtensionConfig, io.envoyproxy.envoy.config.core.v3.TypedExtensionConfig.Builder, io.envoyproxy.envoy.config.core.v3.TypedExtensionConfigOrBuilder> retryOptionsPredicatesBuilder_;
/**
*
* Retry options predicates that will be applied prior to retrying a request. These predicates
* allow customizing request behavior between retries.
* [#comment: add [#extension-category: envoy.retry_options_predicates] when there are built-in extensions]
*
*
* repeated .envoy.config.core.v3.TypedExtensionConfig retry_options_predicates = 12;
*/
public java.util.List getRetryOptionsPredicatesList() {
if (retryOptionsPredicatesBuilder_ == null) {
return java.util.Collections.unmodifiableList(retryOptionsPredicates_);
} else {
return retryOptionsPredicatesBuilder_.getMessageList();
}
}
/**
*
* Retry options predicates that will be applied prior to retrying a request. These predicates
* allow customizing request behavior between retries.
* [#comment: add [#extension-category: envoy.retry_options_predicates] when there are built-in extensions]
*
*
* repeated .envoy.config.core.v3.TypedExtensionConfig retry_options_predicates = 12;
*/
public int getRetryOptionsPredicatesCount() {
if (retryOptionsPredicatesBuilder_ == null) {
return retryOptionsPredicates_.size();
} else {
return retryOptionsPredicatesBuilder_.getCount();
}
}
/**
*
* Retry options predicates that will be applied prior to retrying a request. These predicates
* allow customizing request behavior between retries.
* [#comment: add [#extension-category: envoy.retry_options_predicates] when there are built-in extensions]
*
*
* repeated .envoy.config.core.v3.TypedExtensionConfig retry_options_predicates = 12;
*/
public io.envoyproxy.envoy.config.core.v3.TypedExtensionConfig getRetryOptionsPredicates(int index) {
if (retryOptionsPredicatesBuilder_ == null) {
return retryOptionsPredicates_.get(index);
} else {
return retryOptionsPredicatesBuilder_.getMessage(index);
}
}
/**
*
* Retry options predicates that will be applied prior to retrying a request. These predicates
* allow customizing request behavior between retries.
* [#comment: add [#extension-category: envoy.retry_options_predicates] when there are built-in extensions]
*
*
* repeated .envoy.config.core.v3.TypedExtensionConfig retry_options_predicates = 12;
*/
public Builder setRetryOptionsPredicates(
int index, io.envoyproxy.envoy.config.core.v3.TypedExtensionConfig value) {
if (retryOptionsPredicatesBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureRetryOptionsPredicatesIsMutable();
retryOptionsPredicates_.set(index, value);
onChanged();
} else {
retryOptionsPredicatesBuilder_.setMessage(index, value);
}
return this;
}
/**
*
* Retry options predicates that will be applied prior to retrying a request. These predicates
* allow customizing request behavior between retries.
* [#comment: add [#extension-category: envoy.retry_options_predicates] when there are built-in extensions]
*
*
* repeated .envoy.config.core.v3.TypedExtensionConfig retry_options_predicates = 12;
*/
public Builder setRetryOptionsPredicates(
int index, io.envoyproxy.envoy.config.core.v3.TypedExtensionConfig.Builder builderForValue) {
if (retryOptionsPredicatesBuilder_ == null) {
ensureRetryOptionsPredicatesIsMutable();
retryOptionsPredicates_.set(index, builderForValue.build());
onChanged();
} else {
retryOptionsPredicatesBuilder_.setMessage(index, builderForValue.build());
}
return this;
}
/**
*
* Retry options predicates that will be applied prior to retrying a request. These predicates
* allow customizing request behavior between retries.
* [#comment: add [#extension-category: envoy.retry_options_predicates] when there are built-in extensions]
*
*
* repeated .envoy.config.core.v3.TypedExtensionConfig retry_options_predicates = 12;
*/
public Builder addRetryOptionsPredicates(io.envoyproxy.envoy.config.core.v3.TypedExtensionConfig value) {
if (retryOptionsPredicatesBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureRetryOptionsPredicatesIsMutable();
retryOptionsPredicates_.add(value);
onChanged();
} else {
retryOptionsPredicatesBuilder_.addMessage(value);
}
return this;
}
/**
*
* Retry options predicates that will be applied prior to retrying a request. These predicates
* allow customizing request behavior between retries.
* [#comment: add [#extension-category: envoy.retry_options_predicates] when there are built-in extensions]
*
*
* repeated .envoy.config.core.v3.TypedExtensionConfig retry_options_predicates = 12;
*/
public Builder addRetryOptionsPredicates(
int index, io.envoyproxy.envoy.config.core.v3.TypedExtensionConfig value) {
if (retryOptionsPredicatesBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureRetryOptionsPredicatesIsMutable();
retryOptionsPredicates_.add(index, value);
onChanged();
} else {
retryOptionsPredicatesBuilder_.addMessage(index, value);
}
return this;
}
/**
*
* Retry options predicates that will be applied prior to retrying a request. These predicates
* allow customizing request behavior between retries.
* [#comment: add [#extension-category: envoy.retry_options_predicates] when there are built-in extensions]
*
*
* repeated .envoy.config.core.v3.TypedExtensionConfig retry_options_predicates = 12;
*/
public Builder addRetryOptionsPredicates(
io.envoyproxy.envoy.config.core.v3.TypedExtensionConfig.Builder builderForValue) {
if (retryOptionsPredicatesBuilder_ == null) {
ensureRetryOptionsPredicatesIsMutable();
retryOptionsPredicates_.add(builderForValue.build());
onChanged();
} else {
retryOptionsPredicatesBuilder_.addMessage(builderForValue.build());
}
return this;
}
/**
*
* Retry options predicates that will be applied prior to retrying a request. These predicates
* allow customizing request behavior between retries.
* [#comment: add [#extension-category: envoy.retry_options_predicates] when there are built-in extensions]
*
*
* repeated .envoy.config.core.v3.TypedExtensionConfig retry_options_predicates = 12;
*/
public Builder addRetryOptionsPredicates(
int index, io.envoyproxy.envoy.config.core.v3.TypedExtensionConfig.Builder builderForValue) {
if (retryOptionsPredicatesBuilder_ == null) {
ensureRetryOptionsPredicatesIsMutable();
retryOptionsPredicates_.add(index, builderForValue.build());
onChanged();
} else {
retryOptionsPredicatesBuilder_.addMessage(index, builderForValue.build());
}
return this;
}
/**
*
* Retry options predicates that will be applied prior to retrying a request. These predicates
* allow customizing request behavior between retries.
* [#comment: add [#extension-category: envoy.retry_options_predicates] when there are built-in extensions]
*
*
* repeated .envoy.config.core.v3.TypedExtensionConfig retry_options_predicates = 12;
*/
public Builder addAllRetryOptionsPredicates(
java.lang.Iterable extends io.envoyproxy.envoy.config.core.v3.TypedExtensionConfig> values) {
if (retryOptionsPredicatesBuilder_ == null) {
ensureRetryOptionsPredicatesIsMutable();
com.google.protobuf.AbstractMessageLite.Builder.addAll(
values, retryOptionsPredicates_);
onChanged();
} else {
retryOptionsPredicatesBuilder_.addAllMessages(values);
}
return this;
}
/**
*
* Retry options predicates that will be applied prior to retrying a request. These predicates
* allow customizing request behavior between retries.
* [#comment: add [#extension-category: envoy.retry_options_predicates] when there are built-in extensions]
*
*
* repeated .envoy.config.core.v3.TypedExtensionConfig retry_options_predicates = 12;
*/
public Builder clearRetryOptionsPredicates() {
if (retryOptionsPredicatesBuilder_ == null) {
retryOptionsPredicates_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000040);
onChanged();
} else {
retryOptionsPredicatesBuilder_.clear();
}
return this;
}
/**
*
* Retry options predicates that will be applied prior to retrying a request. These predicates
* allow customizing request behavior between retries.
* [#comment: add [#extension-category: envoy.retry_options_predicates] when there are built-in extensions]
*
*
* repeated .envoy.config.core.v3.TypedExtensionConfig retry_options_predicates = 12;
*/
public Builder removeRetryOptionsPredicates(int index) {
if (retryOptionsPredicatesBuilder_ == null) {
ensureRetryOptionsPredicatesIsMutable();
retryOptionsPredicates_.remove(index);
onChanged();
} else {
retryOptionsPredicatesBuilder_.remove(index);
}
return this;
}
/**
*
* Retry options predicates that will be applied prior to retrying a request. These predicates
* allow customizing request behavior between retries.
* [#comment: add [#extension-category: envoy.retry_options_predicates] when there are built-in extensions]
*
*
* repeated .envoy.config.core.v3.TypedExtensionConfig retry_options_predicates = 12;
*/
public io.envoyproxy.envoy.config.core.v3.TypedExtensionConfig.Builder getRetryOptionsPredicatesBuilder(
int index) {
return getRetryOptionsPredicatesFieldBuilder().getBuilder(index);
}
/**
*
* Retry options predicates that will be applied prior to retrying a request. These predicates
* allow customizing request behavior between retries.
* [#comment: add [#extension-category: envoy.retry_options_predicates] when there are built-in extensions]
*
*
* repeated .envoy.config.core.v3.TypedExtensionConfig retry_options_predicates = 12;
*/
public io.envoyproxy.envoy.config.core.v3.TypedExtensionConfigOrBuilder getRetryOptionsPredicatesOrBuilder(
int index) {
if (retryOptionsPredicatesBuilder_ == null) {
return retryOptionsPredicates_.get(index); } else {
return retryOptionsPredicatesBuilder_.getMessageOrBuilder(index);
}
}
/**
*
* Retry options predicates that will be applied prior to retrying a request. These predicates
* allow customizing request behavior between retries.
* [#comment: add [#extension-category: envoy.retry_options_predicates] when there are built-in extensions]
*
*
* repeated .envoy.config.core.v3.TypedExtensionConfig retry_options_predicates = 12;
*/
public java.util.List extends io.envoyproxy.envoy.config.core.v3.TypedExtensionConfigOrBuilder>
getRetryOptionsPredicatesOrBuilderList() {
if (retryOptionsPredicatesBuilder_ != null) {
return retryOptionsPredicatesBuilder_.getMessageOrBuilderList();
} else {
return java.util.Collections.unmodifiableList(retryOptionsPredicates_);
}
}
/**
*
* Retry options predicates that will be applied prior to retrying a request. These predicates
* allow customizing request behavior between retries.
* [#comment: add [#extension-category: envoy.retry_options_predicates] when there are built-in extensions]
*
*
* repeated .envoy.config.core.v3.TypedExtensionConfig retry_options_predicates = 12;
*/
public io.envoyproxy.envoy.config.core.v3.TypedExtensionConfig.Builder addRetryOptionsPredicatesBuilder() {
return getRetryOptionsPredicatesFieldBuilder().addBuilder(
io.envoyproxy.envoy.config.core.v3.TypedExtensionConfig.getDefaultInstance());
}
/**
*
* Retry options predicates that will be applied prior to retrying a request. These predicates
* allow customizing request behavior between retries.
* [#comment: add [#extension-category: envoy.retry_options_predicates] when there are built-in extensions]
*
*
* repeated .envoy.config.core.v3.TypedExtensionConfig retry_options_predicates = 12;
*/
public io.envoyproxy.envoy.config.core.v3.TypedExtensionConfig.Builder addRetryOptionsPredicatesBuilder(
int index) {
return getRetryOptionsPredicatesFieldBuilder().addBuilder(
index, io.envoyproxy.envoy.config.core.v3.TypedExtensionConfig.getDefaultInstance());
}
/**
*
* Retry options predicates that will be applied prior to retrying a request. These predicates
* allow customizing request behavior between retries.
* [#comment: add [#extension-category: envoy.retry_options_predicates] when there are built-in extensions]
*
*
* repeated .envoy.config.core.v3.TypedExtensionConfig retry_options_predicates = 12;
*/
public java.util.List
getRetryOptionsPredicatesBuilderList() {
return getRetryOptionsPredicatesFieldBuilder().getBuilderList();
}
private com.google.protobuf.RepeatedFieldBuilderV3<
io.envoyproxy.envoy.config.core.v3.TypedExtensionConfig, io.envoyproxy.envoy.config.core.v3.TypedExtensionConfig.Builder, io.envoyproxy.envoy.config.core.v3.TypedExtensionConfigOrBuilder>
getRetryOptionsPredicatesFieldBuilder() {
if (retryOptionsPredicatesBuilder_ == null) {
retryOptionsPredicatesBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3<
io.envoyproxy.envoy.config.core.v3.TypedExtensionConfig, io.envoyproxy.envoy.config.core.v3.TypedExtensionConfig.Builder, io.envoyproxy.envoy.config.core.v3.TypedExtensionConfigOrBuilder>(
retryOptionsPredicates_,
((bitField0_ & 0x00000040) != 0),
getParentForChildren(),
isClean());
retryOptionsPredicates_ = null;
}
return retryOptionsPredicatesBuilder_;
}
private long hostSelectionRetryMaxAttempts_ ;
/**
*
* The maximum number of times host selection will be reattempted before giving up, at which
* point the host that was last selected will be routed to. If unspecified, this will default to
* retrying once.
*
*
* int64 host_selection_retry_max_attempts = 6;
* @return The hostSelectionRetryMaxAttempts.
*/
@java.lang.Override
public long getHostSelectionRetryMaxAttempts() {
return hostSelectionRetryMaxAttempts_;
}
/**
*
* The maximum number of times host selection will be reattempted before giving up, at which
* point the host that was last selected will be routed to. If unspecified, this will default to
* retrying once.
*
*
* int64 host_selection_retry_max_attempts = 6;
* @param value The hostSelectionRetryMaxAttempts to set.
* @return This builder for chaining.
*/
public Builder setHostSelectionRetryMaxAttempts(long value) {
hostSelectionRetryMaxAttempts_ = value;
bitField0_ |= 0x00000080;
onChanged();
return this;
}
/**
*
* The maximum number of times host selection will be reattempted before giving up, at which
* point the host that was last selected will be routed to. If unspecified, this will default to
* retrying once.
*
*
* int64 host_selection_retry_max_attempts = 6;
* @return This builder for chaining.
*/
public Builder clearHostSelectionRetryMaxAttempts() {
bitField0_ = (bitField0_ & ~0x00000080);
hostSelectionRetryMaxAttempts_ = 0L;
onChanged();
return this;
}
private com.google.protobuf.Internal.IntList retriableStatusCodes_ = emptyIntList();
private void ensureRetriableStatusCodesIsMutable() {
if (!retriableStatusCodes_.isModifiable()) {
retriableStatusCodes_ = makeMutableCopy(retriableStatusCodes_);
}
bitField0_ |= 0x00000100;
}
/**
*
* HTTP status codes that should trigger a retry in addition to those specified by retry_on.
*
*
* repeated uint32 retriable_status_codes = 7;
* @return A list containing the retriableStatusCodes.
*/
public java.util.List
getRetriableStatusCodesList() {
retriableStatusCodes_.makeImmutable();
return retriableStatusCodes_;
}
/**
*
* HTTP status codes that should trigger a retry in addition to those specified by retry_on.
*
*
* repeated uint32 retriable_status_codes = 7;
* @return The count of retriableStatusCodes.
*/
public int getRetriableStatusCodesCount() {
return retriableStatusCodes_.size();
}
/**
*
* HTTP status codes that should trigger a retry in addition to those specified by retry_on.
*
*
* repeated uint32 retriable_status_codes = 7;
* @param index The index of the element to return.
* @return The retriableStatusCodes at the given index.
*/
public int getRetriableStatusCodes(int index) {
return retriableStatusCodes_.getInt(index);
}
/**
*
* HTTP status codes that should trigger a retry in addition to those specified by retry_on.
*
*
* repeated uint32 retriable_status_codes = 7;
* @param index The index to set the value at.
* @param value The retriableStatusCodes to set.
* @return This builder for chaining.
*/
public Builder setRetriableStatusCodes(
int index, int value) {
ensureRetriableStatusCodesIsMutable();
retriableStatusCodes_.setInt(index, value);
bitField0_ |= 0x00000100;
onChanged();
return this;
}
/**
*
* HTTP status codes that should trigger a retry in addition to those specified by retry_on.
*
*
* repeated uint32 retriable_status_codes = 7;
* @param value The retriableStatusCodes to add.
* @return This builder for chaining.
*/
public Builder addRetriableStatusCodes(int value) {
ensureRetriableStatusCodesIsMutable();
retriableStatusCodes_.addInt(value);
bitField0_ |= 0x00000100;
onChanged();
return this;
}
/**
*
* HTTP status codes that should trigger a retry in addition to those specified by retry_on.
*
*
* repeated uint32 retriable_status_codes = 7;
* @param values The retriableStatusCodes to add.
* @return This builder for chaining.
*/
public Builder addAllRetriableStatusCodes(
java.lang.Iterable extends java.lang.Integer> values) {
ensureRetriableStatusCodesIsMutable();
com.google.protobuf.AbstractMessageLite.Builder.addAll(
values, retriableStatusCodes_);
bitField0_ |= 0x00000100;
onChanged();
return this;
}
/**
*
* HTTP status codes that should trigger a retry in addition to those specified by retry_on.
*
*
* repeated uint32 retriable_status_codes = 7;
* @return This builder for chaining.
*/
public Builder clearRetriableStatusCodes() {
retriableStatusCodes_ = emptyIntList();
bitField0_ = (bitField0_ & ~0x00000100);
onChanged();
return this;
}
private io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryBackOff retryBackOff_;
private com.google.protobuf.SingleFieldBuilderV3<
io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryBackOff, io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryBackOff.Builder, io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryBackOffOrBuilder> retryBackOffBuilder_;
/**
*
* Specifies parameters that control exponential retry back off. This parameter is optional, in which case the
* default base interval is 25 milliseconds or, if set, the current value of the
* ``upstream.base_retry_backoff_ms`` runtime parameter. The default maximum interval is 10 times
* the base interval. The documentation for :ref:`config_http_filters_router_x-envoy-max-retries`
* describes Envoy's back-off algorithm.
*
*
* .envoy.config.route.v3.RetryPolicy.RetryBackOff retry_back_off = 8;
* @return Whether the retryBackOff field is set.
*/
public boolean hasRetryBackOff() {
return ((bitField0_ & 0x00000200) != 0);
}
/**
*
* Specifies parameters that control exponential retry back off. This parameter is optional, in which case the
* default base interval is 25 milliseconds or, if set, the current value of the
* ``upstream.base_retry_backoff_ms`` runtime parameter. The default maximum interval is 10 times
* the base interval. The documentation for :ref:`config_http_filters_router_x-envoy-max-retries`
* describes Envoy's back-off algorithm.
*
*
* .envoy.config.route.v3.RetryPolicy.RetryBackOff retry_back_off = 8;
* @return The retryBackOff.
*/
public io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryBackOff getRetryBackOff() {
if (retryBackOffBuilder_ == null) {
return retryBackOff_ == null ? io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryBackOff.getDefaultInstance() : retryBackOff_;
} else {
return retryBackOffBuilder_.getMessage();
}
}
/**
*
* Specifies parameters that control exponential retry back off. This parameter is optional, in which case the
* default base interval is 25 milliseconds or, if set, the current value of the
* ``upstream.base_retry_backoff_ms`` runtime parameter. The default maximum interval is 10 times
* the base interval. The documentation for :ref:`config_http_filters_router_x-envoy-max-retries`
* describes Envoy's back-off algorithm.
*
*
* .envoy.config.route.v3.RetryPolicy.RetryBackOff retry_back_off = 8;
*/
public Builder setRetryBackOff(io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryBackOff value) {
if (retryBackOffBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
retryBackOff_ = value;
} else {
retryBackOffBuilder_.setMessage(value);
}
bitField0_ |= 0x00000200;
onChanged();
return this;
}
/**
*
* Specifies parameters that control exponential retry back off. This parameter is optional, in which case the
* default base interval is 25 milliseconds or, if set, the current value of the
* ``upstream.base_retry_backoff_ms`` runtime parameter. The default maximum interval is 10 times
* the base interval. The documentation for :ref:`config_http_filters_router_x-envoy-max-retries`
* describes Envoy's back-off algorithm.
*
*
* .envoy.config.route.v3.RetryPolicy.RetryBackOff retry_back_off = 8;
*/
public Builder setRetryBackOff(
io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryBackOff.Builder builderForValue) {
if (retryBackOffBuilder_ == null) {
retryBackOff_ = builderForValue.build();
} else {
retryBackOffBuilder_.setMessage(builderForValue.build());
}
bitField0_ |= 0x00000200;
onChanged();
return this;
}
/**
*
* Specifies parameters that control exponential retry back off. This parameter is optional, in which case the
* default base interval is 25 milliseconds or, if set, the current value of the
* ``upstream.base_retry_backoff_ms`` runtime parameter. The default maximum interval is 10 times
* the base interval. The documentation for :ref:`config_http_filters_router_x-envoy-max-retries`
* describes Envoy's back-off algorithm.
*
*
* .envoy.config.route.v3.RetryPolicy.RetryBackOff retry_back_off = 8;
*/
public Builder mergeRetryBackOff(io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryBackOff value) {
if (retryBackOffBuilder_ == null) {
if (((bitField0_ & 0x00000200) != 0) &&
retryBackOff_ != null &&
retryBackOff_ != io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryBackOff.getDefaultInstance()) {
getRetryBackOffBuilder().mergeFrom(value);
} else {
retryBackOff_ = value;
}
} else {
retryBackOffBuilder_.mergeFrom(value);
}
if (retryBackOff_ != null) {
bitField0_ |= 0x00000200;
onChanged();
}
return this;
}
/**
*
* Specifies parameters that control exponential retry back off. This parameter is optional, in which case the
* default base interval is 25 milliseconds or, if set, the current value of the
* ``upstream.base_retry_backoff_ms`` runtime parameter. The default maximum interval is 10 times
* the base interval. The documentation for :ref:`config_http_filters_router_x-envoy-max-retries`
* describes Envoy's back-off algorithm.
*
*
* .envoy.config.route.v3.RetryPolicy.RetryBackOff retry_back_off = 8;
*/
public Builder clearRetryBackOff() {
bitField0_ = (bitField0_ & ~0x00000200);
retryBackOff_ = null;
if (retryBackOffBuilder_ != null) {
retryBackOffBuilder_.dispose();
retryBackOffBuilder_ = null;
}
onChanged();
return this;
}
/**
*
* Specifies parameters that control exponential retry back off. This parameter is optional, in which case the
* default base interval is 25 milliseconds or, if set, the current value of the
* ``upstream.base_retry_backoff_ms`` runtime parameter. The default maximum interval is 10 times
* the base interval. The documentation for :ref:`config_http_filters_router_x-envoy-max-retries`
* describes Envoy's back-off algorithm.
*
*
* .envoy.config.route.v3.RetryPolicy.RetryBackOff retry_back_off = 8;
*/
public io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryBackOff.Builder getRetryBackOffBuilder() {
bitField0_ |= 0x00000200;
onChanged();
return getRetryBackOffFieldBuilder().getBuilder();
}
/**
*
* Specifies parameters that control exponential retry back off. This parameter is optional, in which case the
* default base interval is 25 milliseconds or, if set, the current value of the
* ``upstream.base_retry_backoff_ms`` runtime parameter. The default maximum interval is 10 times
* the base interval. The documentation for :ref:`config_http_filters_router_x-envoy-max-retries`
* describes Envoy's back-off algorithm.
*
*
* .envoy.config.route.v3.RetryPolicy.RetryBackOff retry_back_off = 8;
*/
public io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryBackOffOrBuilder getRetryBackOffOrBuilder() {
if (retryBackOffBuilder_ != null) {
return retryBackOffBuilder_.getMessageOrBuilder();
} else {
return retryBackOff_ == null ?
io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryBackOff.getDefaultInstance() : retryBackOff_;
}
}
/**
*
* Specifies parameters that control exponential retry back off. This parameter is optional, in which case the
* default base interval is 25 milliseconds or, if set, the current value of the
* ``upstream.base_retry_backoff_ms`` runtime parameter. The default maximum interval is 10 times
* the base interval. The documentation for :ref:`config_http_filters_router_x-envoy-max-retries`
* describes Envoy's back-off algorithm.
*
*
* .envoy.config.route.v3.RetryPolicy.RetryBackOff retry_back_off = 8;
*/
private com.google.protobuf.SingleFieldBuilderV3<
io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryBackOff, io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryBackOff.Builder, io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryBackOffOrBuilder>
getRetryBackOffFieldBuilder() {
if (retryBackOffBuilder_ == null) {
retryBackOffBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryBackOff, io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryBackOff.Builder, io.envoyproxy.envoy.config.route.v3.RetryPolicy.RetryBackOffOrBuilder>(
getRetryBackOff(),
getParentForChildren(),
isClean());
retryBackOff_ = null;
}
return retryBackOffBuilder_;
}
private io.envoyproxy.envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff rateLimitedRetryBackOff_;
private com.google.protobuf.SingleFieldBuilderV3<
io.envoyproxy.envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff, io.envoyproxy.envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff.Builder, io.envoyproxy.envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOffOrBuilder> rateLimitedRetryBackOffBuilder_;
/**
*
* Specifies parameters that control a retry back-off strategy that is used
* when the request is rate limited by the upstream server. The server may
* return a response header like ``Retry-After`` or ``X-RateLimit-Reset`` to
* provide feedback to the client on how long to wait before retrying. If
* configured, this back-off strategy will be used instead of the
* default exponential back off strategy (configured using ``retry_back_off``)
* whenever a response includes the matching headers.
*
*
* .envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff rate_limited_retry_back_off = 11;
* @return Whether the rateLimitedRetryBackOff field is set.
*/
public boolean hasRateLimitedRetryBackOff() {
return ((bitField0_ & 0x00000400) != 0);
}
/**
*
* Specifies parameters that control a retry back-off strategy that is used
* when the request is rate limited by the upstream server. The server may
* return a response header like ``Retry-After`` or ``X-RateLimit-Reset`` to
* provide feedback to the client on how long to wait before retrying. If
* configured, this back-off strategy will be used instead of the
* default exponential back off strategy (configured using ``retry_back_off``)
* whenever a response includes the matching headers.
*
*
* .envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff rate_limited_retry_back_off = 11;
* @return The rateLimitedRetryBackOff.
*/
public io.envoyproxy.envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff getRateLimitedRetryBackOff() {
if (rateLimitedRetryBackOffBuilder_ == null) {
return rateLimitedRetryBackOff_ == null ? io.envoyproxy.envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff.getDefaultInstance() : rateLimitedRetryBackOff_;
} else {
return rateLimitedRetryBackOffBuilder_.getMessage();
}
}
/**
*
* Specifies parameters that control a retry back-off strategy that is used
* when the request is rate limited by the upstream server. The server may
* return a response header like ``Retry-After`` or ``X-RateLimit-Reset`` to
* provide feedback to the client on how long to wait before retrying. If
* configured, this back-off strategy will be used instead of the
* default exponential back off strategy (configured using ``retry_back_off``)
* whenever a response includes the matching headers.
*
*
* .envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff rate_limited_retry_back_off = 11;
*/
public Builder setRateLimitedRetryBackOff(io.envoyproxy.envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff value) {
if (rateLimitedRetryBackOffBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
rateLimitedRetryBackOff_ = value;
} else {
rateLimitedRetryBackOffBuilder_.setMessage(value);
}
bitField0_ |= 0x00000400;
onChanged();
return this;
}
/**
*
* Specifies parameters that control a retry back-off strategy that is used
* when the request is rate limited by the upstream server. The server may
* return a response header like ``Retry-After`` or ``X-RateLimit-Reset`` to
* provide feedback to the client on how long to wait before retrying. If
* configured, this back-off strategy will be used instead of the
* default exponential back off strategy (configured using ``retry_back_off``)
* whenever a response includes the matching headers.
*
*
* .envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff rate_limited_retry_back_off = 11;
*/
public Builder setRateLimitedRetryBackOff(
io.envoyproxy.envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff.Builder builderForValue) {
if (rateLimitedRetryBackOffBuilder_ == null) {
rateLimitedRetryBackOff_ = builderForValue.build();
} else {
rateLimitedRetryBackOffBuilder_.setMessage(builderForValue.build());
}
bitField0_ |= 0x00000400;
onChanged();
return this;
}
/**
*
* Specifies parameters that control a retry back-off strategy that is used
* when the request is rate limited by the upstream server. The server may
* return a response header like ``Retry-After`` or ``X-RateLimit-Reset`` to
* provide feedback to the client on how long to wait before retrying. If
* configured, this back-off strategy will be used instead of the
* default exponential back off strategy (configured using ``retry_back_off``)
* whenever a response includes the matching headers.
*
*
* .envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff rate_limited_retry_back_off = 11;
*/
public Builder mergeRateLimitedRetryBackOff(io.envoyproxy.envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff value) {
if (rateLimitedRetryBackOffBuilder_ == null) {
if (((bitField0_ & 0x00000400) != 0) &&
rateLimitedRetryBackOff_ != null &&
rateLimitedRetryBackOff_ != io.envoyproxy.envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff.getDefaultInstance()) {
getRateLimitedRetryBackOffBuilder().mergeFrom(value);
} else {
rateLimitedRetryBackOff_ = value;
}
} else {
rateLimitedRetryBackOffBuilder_.mergeFrom(value);
}
if (rateLimitedRetryBackOff_ != null) {
bitField0_ |= 0x00000400;
onChanged();
}
return this;
}
/**
*
* Specifies parameters that control a retry back-off strategy that is used
* when the request is rate limited by the upstream server. The server may
* return a response header like ``Retry-After`` or ``X-RateLimit-Reset`` to
* provide feedback to the client on how long to wait before retrying. If
* configured, this back-off strategy will be used instead of the
* default exponential back off strategy (configured using ``retry_back_off``)
* whenever a response includes the matching headers.
*
*
* .envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff rate_limited_retry_back_off = 11;
*/
public Builder clearRateLimitedRetryBackOff() {
bitField0_ = (bitField0_ & ~0x00000400);
rateLimitedRetryBackOff_ = null;
if (rateLimitedRetryBackOffBuilder_ != null) {
rateLimitedRetryBackOffBuilder_.dispose();
rateLimitedRetryBackOffBuilder_ = null;
}
onChanged();
return this;
}
/**
*
* Specifies parameters that control a retry back-off strategy that is used
* when the request is rate limited by the upstream server. The server may
* return a response header like ``Retry-After`` or ``X-RateLimit-Reset`` to
* provide feedback to the client on how long to wait before retrying. If
* configured, this back-off strategy will be used instead of the
* default exponential back off strategy (configured using ``retry_back_off``)
* whenever a response includes the matching headers.
*
*
* .envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff rate_limited_retry_back_off = 11;
*/
public io.envoyproxy.envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff.Builder getRateLimitedRetryBackOffBuilder() {
bitField0_ |= 0x00000400;
onChanged();
return getRateLimitedRetryBackOffFieldBuilder().getBuilder();
}
/**
*
* Specifies parameters that control a retry back-off strategy that is used
* when the request is rate limited by the upstream server. The server may
* return a response header like ``Retry-After`` or ``X-RateLimit-Reset`` to
* provide feedback to the client on how long to wait before retrying. If
* configured, this back-off strategy will be used instead of the
* default exponential back off strategy (configured using ``retry_back_off``)
* whenever a response includes the matching headers.
*
*
* .envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff rate_limited_retry_back_off = 11;
*/
public io.envoyproxy.envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOffOrBuilder getRateLimitedRetryBackOffOrBuilder() {
if (rateLimitedRetryBackOffBuilder_ != null) {
return rateLimitedRetryBackOffBuilder_.getMessageOrBuilder();
} else {
return rateLimitedRetryBackOff_ == null ?
io.envoyproxy.envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff.getDefaultInstance() : rateLimitedRetryBackOff_;
}
}
/**
*
* Specifies parameters that control a retry back-off strategy that is used
* when the request is rate limited by the upstream server. The server may
* return a response header like ``Retry-After`` or ``X-RateLimit-Reset`` to
* provide feedback to the client on how long to wait before retrying. If
* configured, this back-off strategy will be used instead of the
* default exponential back off strategy (configured using ``retry_back_off``)
* whenever a response includes the matching headers.
*
*
* .envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff rate_limited_retry_back_off = 11;
*/
private com.google.protobuf.SingleFieldBuilderV3<
io.envoyproxy.envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff, io.envoyproxy.envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff.Builder, io.envoyproxy.envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOffOrBuilder>
getRateLimitedRetryBackOffFieldBuilder() {
if (rateLimitedRetryBackOffBuilder_ == null) {
rateLimitedRetryBackOffBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
io.envoyproxy.envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff, io.envoyproxy.envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOff.Builder, io.envoyproxy.envoy.config.route.v3.RetryPolicy.RateLimitedRetryBackOffOrBuilder>(
getRateLimitedRetryBackOff(),
getParentForChildren(),
isClean());
rateLimitedRetryBackOff_ = null;
}
return rateLimitedRetryBackOffBuilder_;
}
private java.util.List retriableHeaders_ =
java.util.Collections.emptyList();
private void ensureRetriableHeadersIsMutable() {
if (!((bitField0_ & 0x00000800) != 0)) {
retriableHeaders_ = new java.util.ArrayList(retriableHeaders_);
bitField0_ |= 0x00000800;
}
}
private com.google.protobuf.RepeatedFieldBuilderV3<
io.envoyproxy.envoy.config.route.v3.HeaderMatcher, io.envoyproxy.envoy.config.route.v3.HeaderMatcher.Builder, io.envoyproxy.envoy.config.route.v3.HeaderMatcherOrBuilder> retriableHeadersBuilder_;
/**
*
* HTTP response headers that trigger a retry if present in the response. A retry will be
* triggered if any of the header matches match the upstream response headers.
* The field is only consulted if 'retriable-headers' retry policy is active.
*
*
* repeated .envoy.config.route.v3.HeaderMatcher retriable_headers = 9;
*/
public java.util.List getRetriableHeadersList() {
if (retriableHeadersBuilder_ == null) {
return java.util.Collections.unmodifiableList(retriableHeaders_);
} else {
return retriableHeadersBuilder_.getMessageList();
}
}
/**
*
* HTTP response headers that trigger a retry if present in the response. A retry will be
* triggered if any of the header matches match the upstream response headers.
* The field is only consulted if 'retriable-headers' retry policy is active.
*
*
* repeated .envoy.config.route.v3.HeaderMatcher retriable_headers = 9;
*/
public int getRetriableHeadersCount() {
if (retriableHeadersBuilder_ == null) {
return retriableHeaders_.size();
} else {
return retriableHeadersBuilder_.getCount();
}
}
/**
*
* HTTP response headers that trigger a retry if present in the response. A retry will be
* triggered if any of the header matches match the upstream response headers.
* The field is only consulted if 'retriable-headers' retry policy is active.
*
*
* repeated .envoy.config.route.v3.HeaderMatcher retriable_headers = 9;
*/
public io.envoyproxy.envoy.config.route.v3.HeaderMatcher getRetriableHeaders(int index) {
if (retriableHeadersBuilder_ == null) {
return retriableHeaders_.get(index);
} else {
return retriableHeadersBuilder_.getMessage(index);
}
}
/**
*
* HTTP response headers that trigger a retry if present in the response. A retry will be
* triggered if any of the header matches match the upstream response headers.
* The field is only consulted if 'retriable-headers' retry policy is active.
*
*
* repeated .envoy.config.route.v3.HeaderMatcher retriable_headers = 9;
*/
public Builder setRetriableHeaders(
int index, io.envoyproxy.envoy.config.route.v3.HeaderMatcher value) {
if (retriableHeadersBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureRetriableHeadersIsMutable();
retriableHeaders_.set(index, value);
onChanged();
} else {
retriableHeadersBuilder_.setMessage(index, value);
}
return this;
}
/**
*
* HTTP response headers that trigger a retry if present in the response. A retry will be
* triggered if any of the header matches match the upstream response headers.
* The field is only consulted if 'retriable-headers' retry policy is active.
*
*
* repeated .envoy.config.route.v3.HeaderMatcher retriable_headers = 9;
*/
public Builder setRetriableHeaders(
int index, io.envoyproxy.envoy.config.route.v3.HeaderMatcher.Builder builderForValue) {
if (retriableHeadersBuilder_ == null) {
ensureRetriableHeadersIsMutable();
retriableHeaders_.set(index, builderForValue.build());
onChanged();
} else {
retriableHeadersBuilder_.setMessage(index, builderForValue.build());
}
return this;
}
/**
*
* HTTP response headers that trigger a retry if present in the response. A retry will be
* triggered if any of the header matches match the upstream response headers.
* The field is only consulted if 'retriable-headers' retry policy is active.
*
*
* repeated .envoy.config.route.v3.HeaderMatcher retriable_headers = 9;
*/
public Builder addRetriableHeaders(io.envoyproxy.envoy.config.route.v3.HeaderMatcher value) {
if (retriableHeadersBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureRetriableHeadersIsMutable();
retriableHeaders_.add(value);
onChanged();
} else {
retriableHeadersBuilder_.addMessage(value);
}
return this;
}
/**
*
* HTTP response headers that trigger a retry if present in the response. A retry will be
* triggered if any of the header matches match the upstream response headers.
* The field is only consulted if 'retriable-headers' retry policy is active.
*
*
* repeated .envoy.config.route.v3.HeaderMatcher retriable_headers = 9;
*/
public Builder addRetriableHeaders(
int index, io.envoyproxy.envoy.config.route.v3.HeaderMatcher value) {
if (retriableHeadersBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureRetriableHeadersIsMutable();
retriableHeaders_.add(index, value);
onChanged();
} else {
retriableHeadersBuilder_.addMessage(index, value);
}
return this;
}
/**
*
* HTTP response headers that trigger a retry if present in the response. A retry will be
* triggered if any of the header matches match the upstream response headers.
* The field is only consulted if 'retriable-headers' retry policy is active.
*
*
* repeated .envoy.config.route.v3.HeaderMatcher retriable_headers = 9;
*/
public Builder addRetriableHeaders(
io.envoyproxy.envoy.config.route.v3.HeaderMatcher.Builder builderForValue) {
if (retriableHeadersBuilder_ == null) {
ensureRetriableHeadersIsMutable();
retriableHeaders_.add(builderForValue.build());
onChanged();
} else {
retriableHeadersBuilder_.addMessage(builderForValue.build());
}
return this;
}
/**
*
* HTTP response headers that trigger a retry if present in the response. A retry will be
* triggered if any of the header matches match the upstream response headers.
* The field is only consulted if 'retriable-headers' retry policy is active.
*
*
* repeated .envoy.config.route.v3.HeaderMatcher retriable_headers = 9;
*/
public Builder addRetriableHeaders(
int index, io.envoyproxy.envoy.config.route.v3.HeaderMatcher.Builder builderForValue) {
if (retriableHeadersBuilder_ == null) {
ensureRetriableHeadersIsMutable();
retriableHeaders_.add(index, builderForValue.build());
onChanged();
} else {
retriableHeadersBuilder_.addMessage(index, builderForValue.build());
}
return this;
}
/**
*
* HTTP response headers that trigger a retry if present in the response. A retry will be
* triggered if any of the header matches match the upstream response headers.
* The field is only consulted if 'retriable-headers' retry policy is active.
*
*
* repeated .envoy.config.route.v3.HeaderMatcher retriable_headers = 9;
*/
public Builder addAllRetriableHeaders(
java.lang.Iterable extends io.envoyproxy.envoy.config.route.v3.HeaderMatcher> values) {
if (retriableHeadersBuilder_ == null) {
ensureRetriableHeadersIsMutable();
com.google.protobuf.AbstractMessageLite.Builder.addAll(
values, retriableHeaders_);
onChanged();
} else {
retriableHeadersBuilder_.addAllMessages(values);
}
return this;
}
/**
*
* HTTP response headers that trigger a retry if present in the response. A retry will be
* triggered if any of the header matches match the upstream response headers.
* The field is only consulted if 'retriable-headers' retry policy is active.
*
*
* repeated .envoy.config.route.v3.HeaderMatcher retriable_headers = 9;
*/
public Builder clearRetriableHeaders() {
if (retriableHeadersBuilder_ == null) {
retriableHeaders_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000800);
onChanged();
} else {
retriableHeadersBuilder_.clear();
}
return this;
}
/**
*
* HTTP response headers that trigger a retry if present in the response. A retry will be
* triggered if any of the header matches match the upstream response headers.
* The field is only consulted if 'retriable-headers' retry policy is active.
*
*
* repeated .envoy.config.route.v3.HeaderMatcher retriable_headers = 9;
*/
public Builder removeRetriableHeaders(int index) {
if (retriableHeadersBuilder_ == null) {
ensureRetriableHeadersIsMutable();
retriableHeaders_.remove(index);
onChanged();
} else {
retriableHeadersBuilder_.remove(index);
}
return this;
}
/**
*
* HTTP response headers that trigger a retry if present in the response. A retry will be
* triggered if any of the header matches match the upstream response headers.
* The field is only consulted if 'retriable-headers' retry policy is active.
*
*
* repeated .envoy.config.route.v3.HeaderMatcher retriable_headers = 9;
*/
public io.envoyproxy.envoy.config.route.v3.HeaderMatcher.Builder getRetriableHeadersBuilder(
int index) {
return getRetriableHeadersFieldBuilder().getBuilder(index);
}
/**
*
* HTTP response headers that trigger a retry if present in the response. A retry will be
* triggered if any of the header matches match the upstream response headers.
* The field is only consulted if 'retriable-headers' retry policy is active.
*
*
* repeated .envoy.config.route.v3.HeaderMatcher retriable_headers = 9;
*/
public io.envoyproxy.envoy.config.route.v3.HeaderMatcherOrBuilder getRetriableHeadersOrBuilder(
int index) {
if (retriableHeadersBuilder_ == null) {
return retriableHeaders_.get(index); } else {
return retriableHeadersBuilder_.getMessageOrBuilder(index);
}
}
/**
*
* HTTP response headers that trigger a retry if present in the response. A retry will be
* triggered if any of the header matches match the upstream response headers.
* The field is only consulted if 'retriable-headers' retry policy is active.
*
*
* repeated .envoy.config.route.v3.HeaderMatcher retriable_headers = 9;
*/
public java.util.List extends io.envoyproxy.envoy.config.route.v3.HeaderMatcherOrBuilder>
getRetriableHeadersOrBuilderList() {
if (retriableHeadersBuilder_ != null) {
return retriableHeadersBuilder_.getMessageOrBuilderList();
} else {
return java.util.Collections.unmodifiableList(retriableHeaders_);
}
}
/**
*
* HTTP response headers that trigger a retry if present in the response. A retry will be
* triggered if any of the header matches match the upstream response headers.
* The field is only consulted if 'retriable-headers' retry policy is active.
*
*
* repeated .envoy.config.route.v3.HeaderMatcher retriable_headers = 9;
*/
public io.envoyproxy.envoy.config.route.v3.HeaderMatcher.Builder addRetriableHeadersBuilder() {
return getRetriableHeadersFieldBuilder().addBuilder(
io.envoyproxy.envoy.config.route.v3.HeaderMatcher.getDefaultInstance());
}
/**
*
* HTTP response headers that trigger a retry if present in the response. A retry will be
* triggered if any of the header matches match the upstream response headers.
* The field is only consulted if 'retriable-headers' retry policy is active.
*
*
* repeated .envoy.config.route.v3.HeaderMatcher retriable_headers = 9;
*/
public io.envoyproxy.envoy.config.route.v3.HeaderMatcher.Builder addRetriableHeadersBuilder(
int index) {
return getRetriableHeadersFieldBuilder().addBuilder(
index, io.envoyproxy.envoy.config.route.v3.HeaderMatcher.getDefaultInstance());
}
/**
*
* HTTP response headers that trigger a retry if present in the response. A retry will be
* triggered if any of the header matches match the upstream response headers.
* The field is only consulted if 'retriable-headers' retry policy is active.
*
*
* repeated .envoy.config.route.v3.HeaderMatcher retriable_headers = 9;
*/
public java.util.List
getRetriableHeadersBuilderList() {
return getRetriableHeadersFieldBuilder().getBuilderList();
}
private com.google.protobuf.RepeatedFieldBuilderV3<
io.envoyproxy.envoy.config.route.v3.HeaderMatcher, io.envoyproxy.envoy.config.route.v3.HeaderMatcher.Builder, io.envoyproxy.envoy.config.route.v3.HeaderMatcherOrBuilder>
getRetriableHeadersFieldBuilder() {
if (retriableHeadersBuilder_ == null) {
retriableHeadersBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3<
io.envoyproxy.envoy.config.route.v3.HeaderMatcher, io.envoyproxy.envoy.config.route.v3.HeaderMatcher.Builder, io.envoyproxy.envoy.config.route.v3.HeaderMatcherOrBuilder>(
retriableHeaders_,
((bitField0_ & 0x00000800) != 0),
getParentForChildren(),
isClean());
retriableHeaders_ = null;
}
return retriableHeadersBuilder_;
}
private java.util.List retriableRequestHeaders_ =
java.util.Collections.emptyList();
private void ensureRetriableRequestHeadersIsMutable() {
if (!((bitField0_ & 0x00001000) != 0)) {
retriableRequestHeaders_ = new java.util.ArrayList(retriableRequestHeaders_);
bitField0_ |= 0x00001000;
}
}
private com.google.protobuf.RepeatedFieldBuilderV3<
io.envoyproxy.envoy.config.route.v3.HeaderMatcher, io.envoyproxy.envoy.config.route.v3.HeaderMatcher.Builder, io.envoyproxy.envoy.config.route.v3.HeaderMatcherOrBuilder> retriableRequestHeadersBuilder_;
/**
*
* HTTP headers which must be present in the request for retries to be attempted.
*
*
* repeated .envoy.config.route.v3.HeaderMatcher retriable_request_headers = 10;
*/
public java.util.List getRetriableRequestHeadersList() {
if (retriableRequestHeadersBuilder_ == null) {
return java.util.Collections.unmodifiableList(retriableRequestHeaders_);
} else {
return retriableRequestHeadersBuilder_.getMessageList();
}
}
/**
*
* HTTP headers which must be present in the request for retries to be attempted.
*
*
* repeated .envoy.config.route.v3.HeaderMatcher retriable_request_headers = 10;
*/
public int getRetriableRequestHeadersCount() {
if (retriableRequestHeadersBuilder_ == null) {
return retriableRequestHeaders_.size();
} else {
return retriableRequestHeadersBuilder_.getCount();
}
}
/**
*
* HTTP headers which must be present in the request for retries to be attempted.
*
*
* repeated .envoy.config.route.v3.HeaderMatcher retriable_request_headers = 10;
*/
public io.envoyproxy.envoy.config.route.v3.HeaderMatcher getRetriableRequestHeaders(int index) {
if (retriableRequestHeadersBuilder_ == null) {
return retriableRequestHeaders_.get(index);
} else {
return retriableRequestHeadersBuilder_.getMessage(index);
}
}
/**
*
* HTTP headers which must be present in the request for retries to be attempted.
*
*
* repeated .envoy.config.route.v3.HeaderMatcher retriable_request_headers = 10;
*/
public Builder setRetriableRequestHeaders(
int index, io.envoyproxy.envoy.config.route.v3.HeaderMatcher value) {
if (retriableRequestHeadersBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureRetriableRequestHeadersIsMutable();
retriableRequestHeaders_.set(index, value);
onChanged();
} else {
retriableRequestHeadersBuilder_.setMessage(index, value);
}
return this;
}
/**
*
* HTTP headers which must be present in the request for retries to be attempted.
*
*
* repeated .envoy.config.route.v3.HeaderMatcher retriable_request_headers = 10;
*/
public Builder setRetriableRequestHeaders(
int index, io.envoyproxy.envoy.config.route.v3.HeaderMatcher.Builder builderForValue) {
if (retriableRequestHeadersBuilder_ == null) {
ensureRetriableRequestHeadersIsMutable();
retriableRequestHeaders_.set(index, builderForValue.build());
onChanged();
} else {
retriableRequestHeadersBuilder_.setMessage(index, builderForValue.build());
}
return this;
}
/**
*
* HTTP headers which must be present in the request for retries to be attempted.
*
*
* repeated .envoy.config.route.v3.HeaderMatcher retriable_request_headers = 10;
*/
public Builder addRetriableRequestHeaders(io.envoyproxy.envoy.config.route.v3.HeaderMatcher value) {
if (retriableRequestHeadersBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureRetriableRequestHeadersIsMutable();
retriableRequestHeaders_.add(value);
onChanged();
} else {
retriableRequestHeadersBuilder_.addMessage(value);
}
return this;
}
/**
*
* HTTP headers which must be present in the request for retries to be attempted.
*
*
* repeated .envoy.config.route.v3.HeaderMatcher retriable_request_headers = 10;
*/
public Builder addRetriableRequestHeaders(
int index, io.envoyproxy.envoy.config.route.v3.HeaderMatcher value) {
if (retriableRequestHeadersBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureRetriableRequestHeadersIsMutable();
retriableRequestHeaders_.add(index, value);
onChanged();
} else {
retriableRequestHeadersBuilder_.addMessage(index, value);
}
return this;
}
/**
*
* HTTP headers which must be present in the request for retries to be attempted.
*
*
* repeated .envoy.config.route.v3.HeaderMatcher retriable_request_headers = 10;
*/
public Builder addRetriableRequestHeaders(
io.envoyproxy.envoy.config.route.v3.HeaderMatcher.Builder builderForValue) {
if (retriableRequestHeadersBuilder_ == null) {
ensureRetriableRequestHeadersIsMutable();
retriableRequestHeaders_.add(builderForValue.build());
onChanged();
} else {
retriableRequestHeadersBuilder_.addMessage(builderForValue.build());
}
return this;
}
/**
*
* HTTP headers which must be present in the request for retries to be attempted.
*
*
* repeated .envoy.config.route.v3.HeaderMatcher retriable_request_headers = 10;
*/
public Builder addRetriableRequestHeaders(
int index, io.envoyproxy.envoy.config.route.v3.HeaderMatcher.Builder builderForValue) {
if (retriableRequestHeadersBuilder_ == null) {
ensureRetriableRequestHeadersIsMutable();
retriableRequestHeaders_.add(index, builderForValue.build());
onChanged();
} else {
retriableRequestHeadersBuilder_.addMessage(index, builderForValue.build());
}
return this;
}
/**
*
* HTTP headers which must be present in the request for retries to be attempted.
*
*
* repeated .envoy.config.route.v3.HeaderMatcher retriable_request_headers = 10;
*/
public Builder addAllRetriableRequestHeaders(
java.lang.Iterable extends io.envoyproxy.envoy.config.route.v3.HeaderMatcher> values) {
if (retriableRequestHeadersBuilder_ == null) {
ensureRetriableRequestHeadersIsMutable();
com.google.protobuf.AbstractMessageLite.Builder.addAll(
values, retriableRequestHeaders_);
onChanged();
} else {
retriableRequestHeadersBuilder_.addAllMessages(values);
}
return this;
}
/**
*
* HTTP headers which must be present in the request for retries to be attempted.
*
*
* repeated .envoy.config.route.v3.HeaderMatcher retriable_request_headers = 10;
*/
public Builder clearRetriableRequestHeaders() {
if (retriableRequestHeadersBuilder_ == null) {
retriableRequestHeaders_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00001000);
onChanged();
} else {
retriableRequestHeadersBuilder_.clear();
}
return this;
}
/**
*
* HTTP headers which must be present in the request for retries to be attempted.
*
*
* repeated .envoy.config.route.v3.HeaderMatcher retriable_request_headers = 10;
*/
public Builder removeRetriableRequestHeaders(int index) {
if (retriableRequestHeadersBuilder_ == null) {
ensureRetriableRequestHeadersIsMutable();
retriableRequestHeaders_.remove(index);
onChanged();
} else {
retriableRequestHeadersBuilder_.remove(index);
}
return this;
}
/**
*
* HTTP headers which must be present in the request for retries to be attempted.
*
*
* repeated .envoy.config.route.v3.HeaderMatcher retriable_request_headers = 10;
*/
public io.envoyproxy.envoy.config.route.v3.HeaderMatcher.Builder getRetriableRequestHeadersBuilder(
int index) {
return getRetriableRequestHeadersFieldBuilder().getBuilder(index);
}
/**
*
* HTTP headers which must be present in the request for retries to be attempted.
*
*
* repeated .envoy.config.route.v3.HeaderMatcher retriable_request_headers = 10;
*/
public io.envoyproxy.envoy.config.route.v3.HeaderMatcherOrBuilder getRetriableRequestHeadersOrBuilder(
int index) {
if (retriableRequestHeadersBuilder_ == null) {
return retriableRequestHeaders_.get(index); } else {
return retriableRequestHeadersBuilder_.getMessageOrBuilder(index);
}
}
/**
*
* HTTP headers which must be present in the request for retries to be attempted.
*
*
* repeated .envoy.config.route.v3.HeaderMatcher retriable_request_headers = 10;
*/
public java.util.List extends io.envoyproxy.envoy.config.route.v3.HeaderMatcherOrBuilder>
getRetriableRequestHeadersOrBuilderList() {
if (retriableRequestHeadersBuilder_ != null) {
return retriableRequestHeadersBuilder_.getMessageOrBuilderList();
} else {
return java.util.Collections.unmodifiableList(retriableRequestHeaders_);
}
}
/**
*
* HTTP headers which must be present in the request for retries to be attempted.
*
*
* repeated .envoy.config.route.v3.HeaderMatcher retriable_request_headers = 10;
*/
public io.envoyproxy.envoy.config.route.v3.HeaderMatcher.Builder addRetriableRequestHeadersBuilder() {
return getRetriableRequestHeadersFieldBuilder().addBuilder(
io.envoyproxy.envoy.config.route.v3.HeaderMatcher.getDefaultInstance());
}
/**
*
* HTTP headers which must be present in the request for retries to be attempted.
*
*
* repeated .envoy.config.route.v3.HeaderMatcher retriable_request_headers = 10;
*/
public io.envoyproxy.envoy.config.route.v3.HeaderMatcher.Builder addRetriableRequestHeadersBuilder(
int index) {
return getRetriableRequestHeadersFieldBuilder().addBuilder(
index, io.envoyproxy.envoy.config.route.v3.HeaderMatcher.getDefaultInstance());
}
/**
*
* HTTP headers which must be present in the request for retries to be attempted.
*
*
* repeated .envoy.config.route.v3.HeaderMatcher retriable_request_headers = 10;
*/
public java.util.List
getRetriableRequestHeadersBuilderList() {
return getRetriableRequestHeadersFieldBuilder().getBuilderList();
}
private com.google.protobuf.RepeatedFieldBuilderV3<
io.envoyproxy.envoy.config.route.v3.HeaderMatcher, io.envoyproxy.envoy.config.route.v3.HeaderMatcher.Builder, io.envoyproxy.envoy.config.route.v3.HeaderMatcherOrBuilder>
getRetriableRequestHeadersFieldBuilder() {
if (retriableRequestHeadersBuilder_ == null) {
retriableRequestHeadersBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3<
io.envoyproxy.envoy.config.route.v3.HeaderMatcher, io.envoyproxy.envoy.config.route.v3.HeaderMatcher.Builder, io.envoyproxy.envoy.config.route.v3.HeaderMatcherOrBuilder>(
retriableRequestHeaders_,
((bitField0_ & 0x00001000) != 0),
getParentForChildren(),
isClean());
retriableRequestHeaders_ = null;
}
return retriableRequestHeadersBuilder_;
}
@java.lang.Override
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFields(unknownFields);
}
@java.lang.Override
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.mergeUnknownFields(unknownFields);
}
// @@protoc_insertion_point(builder_scope:envoy.config.route.v3.RetryPolicy)
}
// @@protoc_insertion_point(class_scope:envoy.config.route.v3.RetryPolicy)
private static final io.envoyproxy.envoy.config.route.v3.RetryPolicy DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new io.envoyproxy.envoy.config.route.v3.RetryPolicy();
}
public static io.envoyproxy.envoy.config.route.v3.RetryPolicy getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public RetryPolicy parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
@java.lang.Override
public io.envoyproxy.envoy.config.route.v3.RetryPolicy getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy