
io.envoyproxy.envoy.extensions.clusters.redis.v3.RedisClusterConfig Maven / Gradle / Ivy
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: envoy/extensions/clusters/redis/v3/redis_cluster.proto
// Protobuf Java Version: 3.25.1
package io.envoyproxy.envoy.extensions.clusters.redis.v3;
/**
*
* [#next-free-field: 7]
*
*
* Protobuf type {@code envoy.extensions.clusters.redis.v3.RedisClusterConfig}
*/
public final class RedisClusterConfig extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:envoy.extensions.clusters.redis.v3.RedisClusterConfig)
RedisClusterConfigOrBuilder {
private static final long serialVersionUID = 0L;
// Use RedisClusterConfig.newBuilder() to construct.
private RedisClusterConfig(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private RedisClusterConfig() {
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new RedisClusterConfig();
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return io.envoyproxy.envoy.extensions.clusters.redis.v3.RedisClusterProto.internal_static_envoy_extensions_clusters_redis_v3_RedisClusterConfig_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return io.envoyproxy.envoy.extensions.clusters.redis.v3.RedisClusterProto.internal_static_envoy_extensions_clusters_redis_v3_RedisClusterConfig_fieldAccessorTable
.ensureFieldAccessorsInitialized(
io.envoyproxy.envoy.extensions.clusters.redis.v3.RedisClusterConfig.class, io.envoyproxy.envoy.extensions.clusters.redis.v3.RedisClusterConfig.Builder.class);
}
private int bitField0_;
public static final int CLUSTER_REFRESH_RATE_FIELD_NUMBER = 1;
private com.google.protobuf.Duration clusterRefreshRate_;
/**
*
* Interval between successive topology refresh requests. If not set, this defaults to 5s.
*
*
* .google.protobuf.Duration cluster_refresh_rate = 1 [(.validate.rules) = { ... }
* @return Whether the clusterRefreshRate field is set.
*/
@java.lang.Override
public boolean hasClusterRefreshRate() {
return ((bitField0_ & 0x00000001) != 0);
}
/**
*
* Interval between successive topology refresh requests. If not set, this defaults to 5s.
*
*
* .google.protobuf.Duration cluster_refresh_rate = 1 [(.validate.rules) = { ... }
* @return The clusterRefreshRate.
*/
@java.lang.Override
public com.google.protobuf.Duration getClusterRefreshRate() {
return clusterRefreshRate_ == null ? com.google.protobuf.Duration.getDefaultInstance() : clusterRefreshRate_;
}
/**
*
* Interval between successive topology refresh requests. If not set, this defaults to 5s.
*
*
* .google.protobuf.Duration cluster_refresh_rate = 1 [(.validate.rules) = { ... }
*/
@java.lang.Override
public com.google.protobuf.DurationOrBuilder getClusterRefreshRateOrBuilder() {
return clusterRefreshRate_ == null ? com.google.protobuf.Duration.getDefaultInstance() : clusterRefreshRate_;
}
public static final int CLUSTER_REFRESH_TIMEOUT_FIELD_NUMBER = 2;
private com.google.protobuf.Duration clusterRefreshTimeout_;
/**
*
* Timeout for topology refresh request. If not set, this defaults to 3s.
*
*
* .google.protobuf.Duration cluster_refresh_timeout = 2 [(.validate.rules) = { ... }
* @return Whether the clusterRefreshTimeout field is set.
*/
@java.lang.Override
public boolean hasClusterRefreshTimeout() {
return ((bitField0_ & 0x00000002) != 0);
}
/**
*
* Timeout for topology refresh request. If not set, this defaults to 3s.
*
*
* .google.protobuf.Duration cluster_refresh_timeout = 2 [(.validate.rules) = { ... }
* @return The clusterRefreshTimeout.
*/
@java.lang.Override
public com.google.protobuf.Duration getClusterRefreshTimeout() {
return clusterRefreshTimeout_ == null ? com.google.protobuf.Duration.getDefaultInstance() : clusterRefreshTimeout_;
}
/**
*
* Timeout for topology refresh request. If not set, this defaults to 3s.
*
*
* .google.protobuf.Duration cluster_refresh_timeout = 2 [(.validate.rules) = { ... }
*/
@java.lang.Override
public com.google.protobuf.DurationOrBuilder getClusterRefreshTimeoutOrBuilder() {
return clusterRefreshTimeout_ == null ? com.google.protobuf.Duration.getDefaultInstance() : clusterRefreshTimeout_;
}
public static final int REDIRECT_REFRESH_INTERVAL_FIELD_NUMBER = 3;
private com.google.protobuf.Duration redirectRefreshInterval_;
/**
*
* The minimum interval that must pass after triggering a topology refresh request before a new
* request can possibly be triggered again. Any errors received during one of these
* time intervals are ignored. If not set, this defaults to 5s.
*
*
* .google.protobuf.Duration redirect_refresh_interval = 3;
* @return Whether the redirectRefreshInterval field is set.
*/
@java.lang.Override
public boolean hasRedirectRefreshInterval() {
return ((bitField0_ & 0x00000004) != 0);
}
/**
*
* The minimum interval that must pass after triggering a topology refresh request before a new
* request can possibly be triggered again. Any errors received during one of these
* time intervals are ignored. If not set, this defaults to 5s.
*
*
* .google.protobuf.Duration redirect_refresh_interval = 3;
* @return The redirectRefreshInterval.
*/
@java.lang.Override
public com.google.protobuf.Duration getRedirectRefreshInterval() {
return redirectRefreshInterval_ == null ? com.google.protobuf.Duration.getDefaultInstance() : redirectRefreshInterval_;
}
/**
*
* The minimum interval that must pass after triggering a topology refresh request before a new
* request can possibly be triggered again. Any errors received during one of these
* time intervals are ignored. If not set, this defaults to 5s.
*
*
* .google.protobuf.Duration redirect_refresh_interval = 3;
*/
@java.lang.Override
public com.google.protobuf.DurationOrBuilder getRedirectRefreshIntervalOrBuilder() {
return redirectRefreshInterval_ == null ? com.google.protobuf.Duration.getDefaultInstance() : redirectRefreshInterval_;
}
public static final int REDIRECT_REFRESH_THRESHOLD_FIELD_NUMBER = 4;
private com.google.protobuf.UInt32Value redirectRefreshThreshold_;
/**
*
* The number of redirection errors that must be received before
* triggering a topology refresh request. If not set, this defaults to 5.
* If this is set to 0, topology refresh after redirect is disabled.
*
*
* .google.protobuf.UInt32Value redirect_refresh_threshold = 4;
* @return Whether the redirectRefreshThreshold field is set.
*/
@java.lang.Override
public boolean hasRedirectRefreshThreshold() {
return ((bitField0_ & 0x00000008) != 0);
}
/**
*
* The number of redirection errors that must be received before
* triggering a topology refresh request. If not set, this defaults to 5.
* If this is set to 0, topology refresh after redirect is disabled.
*
*
* .google.protobuf.UInt32Value redirect_refresh_threshold = 4;
* @return The redirectRefreshThreshold.
*/
@java.lang.Override
public com.google.protobuf.UInt32Value getRedirectRefreshThreshold() {
return redirectRefreshThreshold_ == null ? com.google.protobuf.UInt32Value.getDefaultInstance() : redirectRefreshThreshold_;
}
/**
*
* The number of redirection errors that must be received before
* triggering a topology refresh request. If not set, this defaults to 5.
* If this is set to 0, topology refresh after redirect is disabled.
*
*
* .google.protobuf.UInt32Value redirect_refresh_threshold = 4;
*/
@java.lang.Override
public com.google.protobuf.UInt32ValueOrBuilder getRedirectRefreshThresholdOrBuilder() {
return redirectRefreshThreshold_ == null ? com.google.protobuf.UInt32Value.getDefaultInstance() : redirectRefreshThreshold_;
}
public static final int FAILURE_REFRESH_THRESHOLD_FIELD_NUMBER = 5;
private int failureRefreshThreshold_ = 0;
/**
*
* The number of failures that must be received before triggering a topology refresh request.
* If not set, this defaults to 0, which disables the topology refresh due to failure.
*
*
* uint32 failure_refresh_threshold = 5;
* @return The failureRefreshThreshold.
*/
@java.lang.Override
public int getFailureRefreshThreshold() {
return failureRefreshThreshold_;
}
public static final int HOST_DEGRADED_REFRESH_THRESHOLD_FIELD_NUMBER = 6;
private int hostDegradedRefreshThreshold_ = 0;
/**
*
* The number of hosts became degraded or unhealthy before triggering a topology refresh request.
* If not set, this defaults to 0, which disables the topology refresh due to degraded or
* unhealthy host.
*
*
* uint32 host_degraded_refresh_threshold = 6;
* @return The hostDegradedRefreshThreshold.
*/
@java.lang.Override
public int getHostDegradedRefreshThreshold() {
return hostDegradedRefreshThreshold_;
}
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, getClusterRefreshRate());
}
if (((bitField0_ & 0x00000002) != 0)) {
output.writeMessage(2, getClusterRefreshTimeout());
}
if (((bitField0_ & 0x00000004) != 0)) {
output.writeMessage(3, getRedirectRefreshInterval());
}
if (((bitField0_ & 0x00000008) != 0)) {
output.writeMessage(4, getRedirectRefreshThreshold());
}
if (failureRefreshThreshold_ != 0) {
output.writeUInt32(5, failureRefreshThreshold_);
}
if (hostDegradedRefreshThreshold_ != 0) {
output.writeUInt32(6, hostDegradedRefreshThreshold_);
}
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, getClusterRefreshRate());
}
if (((bitField0_ & 0x00000002) != 0)) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(2, getClusterRefreshTimeout());
}
if (((bitField0_ & 0x00000004) != 0)) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(3, getRedirectRefreshInterval());
}
if (((bitField0_ & 0x00000008) != 0)) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(4, getRedirectRefreshThreshold());
}
if (failureRefreshThreshold_ != 0) {
size += com.google.protobuf.CodedOutputStream
.computeUInt32Size(5, failureRefreshThreshold_);
}
if (hostDegradedRefreshThreshold_ != 0) {
size += com.google.protobuf.CodedOutputStream
.computeUInt32Size(6, hostDegradedRefreshThreshold_);
}
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.extensions.clusters.redis.v3.RedisClusterConfig)) {
return super.equals(obj);
}
io.envoyproxy.envoy.extensions.clusters.redis.v3.RedisClusterConfig other = (io.envoyproxy.envoy.extensions.clusters.redis.v3.RedisClusterConfig) obj;
if (hasClusterRefreshRate() != other.hasClusterRefreshRate()) return false;
if (hasClusterRefreshRate()) {
if (!getClusterRefreshRate()
.equals(other.getClusterRefreshRate())) return false;
}
if (hasClusterRefreshTimeout() != other.hasClusterRefreshTimeout()) return false;
if (hasClusterRefreshTimeout()) {
if (!getClusterRefreshTimeout()
.equals(other.getClusterRefreshTimeout())) return false;
}
if (hasRedirectRefreshInterval() != other.hasRedirectRefreshInterval()) return false;
if (hasRedirectRefreshInterval()) {
if (!getRedirectRefreshInterval()
.equals(other.getRedirectRefreshInterval())) return false;
}
if (hasRedirectRefreshThreshold() != other.hasRedirectRefreshThreshold()) return false;
if (hasRedirectRefreshThreshold()) {
if (!getRedirectRefreshThreshold()
.equals(other.getRedirectRefreshThreshold())) return false;
}
if (getFailureRefreshThreshold()
!= other.getFailureRefreshThreshold()) return false;
if (getHostDegradedRefreshThreshold()
!= other.getHostDegradedRefreshThreshold()) 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 (hasClusterRefreshRate()) {
hash = (37 * hash) + CLUSTER_REFRESH_RATE_FIELD_NUMBER;
hash = (53 * hash) + getClusterRefreshRate().hashCode();
}
if (hasClusterRefreshTimeout()) {
hash = (37 * hash) + CLUSTER_REFRESH_TIMEOUT_FIELD_NUMBER;
hash = (53 * hash) + getClusterRefreshTimeout().hashCode();
}
if (hasRedirectRefreshInterval()) {
hash = (37 * hash) + REDIRECT_REFRESH_INTERVAL_FIELD_NUMBER;
hash = (53 * hash) + getRedirectRefreshInterval().hashCode();
}
if (hasRedirectRefreshThreshold()) {
hash = (37 * hash) + REDIRECT_REFRESH_THRESHOLD_FIELD_NUMBER;
hash = (53 * hash) + getRedirectRefreshThreshold().hashCode();
}
hash = (37 * hash) + FAILURE_REFRESH_THRESHOLD_FIELD_NUMBER;
hash = (53 * hash) + getFailureRefreshThreshold();
hash = (37 * hash) + HOST_DEGRADED_REFRESH_THRESHOLD_FIELD_NUMBER;
hash = (53 * hash) + getHostDegradedRefreshThreshold();
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static io.envoyproxy.envoy.extensions.clusters.redis.v3.RedisClusterConfig parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.envoyproxy.envoy.extensions.clusters.redis.v3.RedisClusterConfig 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.extensions.clusters.redis.v3.RedisClusterConfig parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.envoyproxy.envoy.extensions.clusters.redis.v3.RedisClusterConfig 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.extensions.clusters.redis.v3.RedisClusterConfig parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.envoyproxy.envoy.extensions.clusters.redis.v3.RedisClusterConfig parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.envoyproxy.envoy.extensions.clusters.redis.v3.RedisClusterConfig parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static io.envoyproxy.envoy.extensions.clusters.redis.v3.RedisClusterConfig 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.extensions.clusters.redis.v3.RedisClusterConfig parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static io.envoyproxy.envoy.extensions.clusters.redis.v3.RedisClusterConfig 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.extensions.clusters.redis.v3.RedisClusterConfig parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static io.envoyproxy.envoy.extensions.clusters.redis.v3.RedisClusterConfig 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.extensions.clusters.redis.v3.RedisClusterConfig 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;
}
/**
*
* [#next-free-field: 7]
*
*
* Protobuf type {@code envoy.extensions.clusters.redis.v3.RedisClusterConfig}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:envoy.extensions.clusters.redis.v3.RedisClusterConfig)
io.envoyproxy.envoy.extensions.clusters.redis.v3.RedisClusterConfigOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return io.envoyproxy.envoy.extensions.clusters.redis.v3.RedisClusterProto.internal_static_envoy_extensions_clusters_redis_v3_RedisClusterConfig_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return io.envoyproxy.envoy.extensions.clusters.redis.v3.RedisClusterProto.internal_static_envoy_extensions_clusters_redis_v3_RedisClusterConfig_fieldAccessorTable
.ensureFieldAccessorsInitialized(
io.envoyproxy.envoy.extensions.clusters.redis.v3.RedisClusterConfig.class, io.envoyproxy.envoy.extensions.clusters.redis.v3.RedisClusterConfig.Builder.class);
}
// Construct using io.envoyproxy.envoy.extensions.clusters.redis.v3.RedisClusterConfig.newBuilder()
private Builder() {
maybeForceBuilderInitialization();
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (com.google.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
getClusterRefreshRateFieldBuilder();
getClusterRefreshTimeoutFieldBuilder();
getRedirectRefreshIntervalFieldBuilder();
getRedirectRefreshThresholdFieldBuilder();
}
}
@java.lang.Override
public Builder clear() {
super.clear();
bitField0_ = 0;
clusterRefreshRate_ = null;
if (clusterRefreshRateBuilder_ != null) {
clusterRefreshRateBuilder_.dispose();
clusterRefreshRateBuilder_ = null;
}
clusterRefreshTimeout_ = null;
if (clusterRefreshTimeoutBuilder_ != null) {
clusterRefreshTimeoutBuilder_.dispose();
clusterRefreshTimeoutBuilder_ = null;
}
redirectRefreshInterval_ = null;
if (redirectRefreshIntervalBuilder_ != null) {
redirectRefreshIntervalBuilder_.dispose();
redirectRefreshIntervalBuilder_ = null;
}
redirectRefreshThreshold_ = null;
if (redirectRefreshThresholdBuilder_ != null) {
redirectRefreshThresholdBuilder_.dispose();
redirectRefreshThresholdBuilder_ = null;
}
failureRefreshThreshold_ = 0;
hostDegradedRefreshThreshold_ = 0;
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return io.envoyproxy.envoy.extensions.clusters.redis.v3.RedisClusterProto.internal_static_envoy_extensions_clusters_redis_v3_RedisClusterConfig_descriptor;
}
@java.lang.Override
public io.envoyproxy.envoy.extensions.clusters.redis.v3.RedisClusterConfig getDefaultInstanceForType() {
return io.envoyproxy.envoy.extensions.clusters.redis.v3.RedisClusterConfig.getDefaultInstance();
}
@java.lang.Override
public io.envoyproxy.envoy.extensions.clusters.redis.v3.RedisClusterConfig build() {
io.envoyproxy.envoy.extensions.clusters.redis.v3.RedisClusterConfig result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public io.envoyproxy.envoy.extensions.clusters.redis.v3.RedisClusterConfig buildPartial() {
io.envoyproxy.envoy.extensions.clusters.redis.v3.RedisClusterConfig result = new io.envoyproxy.envoy.extensions.clusters.redis.v3.RedisClusterConfig(this);
if (bitField0_ != 0) { buildPartial0(result); }
onBuilt();
return result;
}
private void buildPartial0(io.envoyproxy.envoy.extensions.clusters.redis.v3.RedisClusterConfig result) {
int from_bitField0_ = bitField0_;
int to_bitField0_ = 0;
if (((from_bitField0_ & 0x00000001) != 0)) {
result.clusterRefreshRate_ = clusterRefreshRateBuilder_ == null
? clusterRefreshRate_
: clusterRefreshRateBuilder_.build();
to_bitField0_ |= 0x00000001;
}
if (((from_bitField0_ & 0x00000002) != 0)) {
result.clusterRefreshTimeout_ = clusterRefreshTimeoutBuilder_ == null
? clusterRefreshTimeout_
: clusterRefreshTimeoutBuilder_.build();
to_bitField0_ |= 0x00000002;
}
if (((from_bitField0_ & 0x00000004) != 0)) {
result.redirectRefreshInterval_ = redirectRefreshIntervalBuilder_ == null
? redirectRefreshInterval_
: redirectRefreshIntervalBuilder_.build();
to_bitField0_ |= 0x00000004;
}
if (((from_bitField0_ & 0x00000008) != 0)) {
result.redirectRefreshThreshold_ = redirectRefreshThresholdBuilder_ == null
? redirectRefreshThreshold_
: redirectRefreshThresholdBuilder_.build();
to_bitField0_ |= 0x00000008;
}
if (((from_bitField0_ & 0x00000010) != 0)) {
result.failureRefreshThreshold_ = failureRefreshThreshold_;
}
if (((from_bitField0_ & 0x00000020) != 0)) {
result.hostDegradedRefreshThreshold_ = hostDegradedRefreshThreshold_;
}
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.extensions.clusters.redis.v3.RedisClusterConfig) {
return mergeFrom((io.envoyproxy.envoy.extensions.clusters.redis.v3.RedisClusterConfig)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(io.envoyproxy.envoy.extensions.clusters.redis.v3.RedisClusterConfig other) {
if (other == io.envoyproxy.envoy.extensions.clusters.redis.v3.RedisClusterConfig.getDefaultInstance()) return this;
if (other.hasClusterRefreshRate()) {
mergeClusterRefreshRate(other.getClusterRefreshRate());
}
if (other.hasClusterRefreshTimeout()) {
mergeClusterRefreshTimeout(other.getClusterRefreshTimeout());
}
if (other.hasRedirectRefreshInterval()) {
mergeRedirectRefreshInterval(other.getRedirectRefreshInterval());
}
if (other.hasRedirectRefreshThreshold()) {
mergeRedirectRefreshThreshold(other.getRedirectRefreshThreshold());
}
if (other.getFailureRefreshThreshold() != 0) {
setFailureRefreshThreshold(other.getFailureRefreshThreshold());
}
if (other.getHostDegradedRefreshThreshold() != 0) {
setHostDegradedRefreshThreshold(other.getHostDegradedRefreshThreshold());
}
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(
getClusterRefreshRateFieldBuilder().getBuilder(),
extensionRegistry);
bitField0_ |= 0x00000001;
break;
} // case 10
case 18: {
input.readMessage(
getClusterRefreshTimeoutFieldBuilder().getBuilder(),
extensionRegistry);
bitField0_ |= 0x00000002;
break;
} // case 18
case 26: {
input.readMessage(
getRedirectRefreshIntervalFieldBuilder().getBuilder(),
extensionRegistry);
bitField0_ |= 0x00000004;
break;
} // case 26
case 34: {
input.readMessage(
getRedirectRefreshThresholdFieldBuilder().getBuilder(),
extensionRegistry);
bitField0_ |= 0x00000008;
break;
} // case 34
case 40: {
failureRefreshThreshold_ = input.readUInt32();
bitField0_ |= 0x00000010;
break;
} // case 40
case 48: {
hostDegradedRefreshThreshold_ = input.readUInt32();
bitField0_ |= 0x00000020;
break;
} // case 48
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 clusterRefreshRate_;
private com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Duration, com.google.protobuf.Duration.Builder, com.google.protobuf.DurationOrBuilder> clusterRefreshRateBuilder_;
/**
*
* Interval between successive topology refresh requests. If not set, this defaults to 5s.
*
*
* .google.protobuf.Duration cluster_refresh_rate = 1 [(.validate.rules) = { ... }
* @return Whether the clusterRefreshRate field is set.
*/
public boolean hasClusterRefreshRate() {
return ((bitField0_ & 0x00000001) != 0);
}
/**
*
* Interval between successive topology refresh requests. If not set, this defaults to 5s.
*
*
* .google.protobuf.Duration cluster_refresh_rate = 1 [(.validate.rules) = { ... }
* @return The clusterRefreshRate.
*/
public com.google.protobuf.Duration getClusterRefreshRate() {
if (clusterRefreshRateBuilder_ == null) {
return clusterRefreshRate_ == null ? com.google.protobuf.Duration.getDefaultInstance() : clusterRefreshRate_;
} else {
return clusterRefreshRateBuilder_.getMessage();
}
}
/**
*
* Interval between successive topology refresh requests. If not set, this defaults to 5s.
*
*
* .google.protobuf.Duration cluster_refresh_rate = 1 [(.validate.rules) = { ... }
*/
public Builder setClusterRefreshRate(com.google.protobuf.Duration value) {
if (clusterRefreshRateBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
clusterRefreshRate_ = value;
} else {
clusterRefreshRateBuilder_.setMessage(value);
}
bitField0_ |= 0x00000001;
onChanged();
return this;
}
/**
*
* Interval between successive topology refresh requests. If not set, this defaults to 5s.
*
*
* .google.protobuf.Duration cluster_refresh_rate = 1 [(.validate.rules) = { ... }
*/
public Builder setClusterRefreshRate(
com.google.protobuf.Duration.Builder builderForValue) {
if (clusterRefreshRateBuilder_ == null) {
clusterRefreshRate_ = builderForValue.build();
} else {
clusterRefreshRateBuilder_.setMessage(builderForValue.build());
}
bitField0_ |= 0x00000001;
onChanged();
return this;
}
/**
*
* Interval between successive topology refresh requests. If not set, this defaults to 5s.
*
*
* .google.protobuf.Duration cluster_refresh_rate = 1 [(.validate.rules) = { ... }
*/
public Builder mergeClusterRefreshRate(com.google.protobuf.Duration value) {
if (clusterRefreshRateBuilder_ == null) {
if (((bitField0_ & 0x00000001) != 0) &&
clusterRefreshRate_ != null &&
clusterRefreshRate_ != com.google.protobuf.Duration.getDefaultInstance()) {
getClusterRefreshRateBuilder().mergeFrom(value);
} else {
clusterRefreshRate_ = value;
}
} else {
clusterRefreshRateBuilder_.mergeFrom(value);
}
if (clusterRefreshRate_ != null) {
bitField0_ |= 0x00000001;
onChanged();
}
return this;
}
/**
*
* Interval between successive topology refresh requests. If not set, this defaults to 5s.
*
*
* .google.protobuf.Duration cluster_refresh_rate = 1 [(.validate.rules) = { ... }
*/
public Builder clearClusterRefreshRate() {
bitField0_ = (bitField0_ & ~0x00000001);
clusterRefreshRate_ = null;
if (clusterRefreshRateBuilder_ != null) {
clusterRefreshRateBuilder_.dispose();
clusterRefreshRateBuilder_ = null;
}
onChanged();
return this;
}
/**
*
* Interval between successive topology refresh requests. If not set, this defaults to 5s.
*
*
* .google.protobuf.Duration cluster_refresh_rate = 1 [(.validate.rules) = { ... }
*/
public com.google.protobuf.Duration.Builder getClusterRefreshRateBuilder() {
bitField0_ |= 0x00000001;
onChanged();
return getClusterRefreshRateFieldBuilder().getBuilder();
}
/**
*
* Interval between successive topology refresh requests. If not set, this defaults to 5s.
*
*
* .google.protobuf.Duration cluster_refresh_rate = 1 [(.validate.rules) = { ... }
*/
public com.google.protobuf.DurationOrBuilder getClusterRefreshRateOrBuilder() {
if (clusterRefreshRateBuilder_ != null) {
return clusterRefreshRateBuilder_.getMessageOrBuilder();
} else {
return clusterRefreshRate_ == null ?
com.google.protobuf.Duration.getDefaultInstance() : clusterRefreshRate_;
}
}
/**
*
* Interval between successive topology refresh requests. If not set, this defaults to 5s.
*
*
* .google.protobuf.Duration cluster_refresh_rate = 1 [(.validate.rules) = { ... }
*/
private com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Duration, com.google.protobuf.Duration.Builder, com.google.protobuf.DurationOrBuilder>
getClusterRefreshRateFieldBuilder() {
if (clusterRefreshRateBuilder_ == null) {
clusterRefreshRateBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Duration, com.google.protobuf.Duration.Builder, com.google.protobuf.DurationOrBuilder>(
getClusterRefreshRate(),
getParentForChildren(),
isClean());
clusterRefreshRate_ = null;
}
return clusterRefreshRateBuilder_;
}
private com.google.protobuf.Duration clusterRefreshTimeout_;
private com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Duration, com.google.protobuf.Duration.Builder, com.google.protobuf.DurationOrBuilder> clusterRefreshTimeoutBuilder_;
/**
*
* Timeout for topology refresh request. If not set, this defaults to 3s.
*
*
* .google.protobuf.Duration cluster_refresh_timeout = 2 [(.validate.rules) = { ... }
* @return Whether the clusterRefreshTimeout field is set.
*/
public boolean hasClusterRefreshTimeout() {
return ((bitField0_ & 0x00000002) != 0);
}
/**
*
* Timeout for topology refresh request. If not set, this defaults to 3s.
*
*
* .google.protobuf.Duration cluster_refresh_timeout = 2 [(.validate.rules) = { ... }
* @return The clusterRefreshTimeout.
*/
public com.google.protobuf.Duration getClusterRefreshTimeout() {
if (clusterRefreshTimeoutBuilder_ == null) {
return clusterRefreshTimeout_ == null ? com.google.protobuf.Duration.getDefaultInstance() : clusterRefreshTimeout_;
} else {
return clusterRefreshTimeoutBuilder_.getMessage();
}
}
/**
*
* Timeout for topology refresh request. If not set, this defaults to 3s.
*
*
* .google.protobuf.Duration cluster_refresh_timeout = 2 [(.validate.rules) = { ... }
*/
public Builder setClusterRefreshTimeout(com.google.protobuf.Duration value) {
if (clusterRefreshTimeoutBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
clusterRefreshTimeout_ = value;
} else {
clusterRefreshTimeoutBuilder_.setMessage(value);
}
bitField0_ |= 0x00000002;
onChanged();
return this;
}
/**
*
* Timeout for topology refresh request. If not set, this defaults to 3s.
*
*
* .google.protobuf.Duration cluster_refresh_timeout = 2 [(.validate.rules) = { ... }
*/
public Builder setClusterRefreshTimeout(
com.google.protobuf.Duration.Builder builderForValue) {
if (clusterRefreshTimeoutBuilder_ == null) {
clusterRefreshTimeout_ = builderForValue.build();
} else {
clusterRefreshTimeoutBuilder_.setMessage(builderForValue.build());
}
bitField0_ |= 0x00000002;
onChanged();
return this;
}
/**
*
* Timeout for topology refresh request. If not set, this defaults to 3s.
*
*
* .google.protobuf.Duration cluster_refresh_timeout = 2 [(.validate.rules) = { ... }
*/
public Builder mergeClusterRefreshTimeout(com.google.protobuf.Duration value) {
if (clusterRefreshTimeoutBuilder_ == null) {
if (((bitField0_ & 0x00000002) != 0) &&
clusterRefreshTimeout_ != null &&
clusterRefreshTimeout_ != com.google.protobuf.Duration.getDefaultInstance()) {
getClusterRefreshTimeoutBuilder().mergeFrom(value);
} else {
clusterRefreshTimeout_ = value;
}
} else {
clusterRefreshTimeoutBuilder_.mergeFrom(value);
}
if (clusterRefreshTimeout_ != null) {
bitField0_ |= 0x00000002;
onChanged();
}
return this;
}
/**
*
* Timeout for topology refresh request. If not set, this defaults to 3s.
*
*
* .google.protobuf.Duration cluster_refresh_timeout = 2 [(.validate.rules) = { ... }
*/
public Builder clearClusterRefreshTimeout() {
bitField0_ = (bitField0_ & ~0x00000002);
clusterRefreshTimeout_ = null;
if (clusterRefreshTimeoutBuilder_ != null) {
clusterRefreshTimeoutBuilder_.dispose();
clusterRefreshTimeoutBuilder_ = null;
}
onChanged();
return this;
}
/**
*
* Timeout for topology refresh request. If not set, this defaults to 3s.
*
*
* .google.protobuf.Duration cluster_refresh_timeout = 2 [(.validate.rules) = { ... }
*/
public com.google.protobuf.Duration.Builder getClusterRefreshTimeoutBuilder() {
bitField0_ |= 0x00000002;
onChanged();
return getClusterRefreshTimeoutFieldBuilder().getBuilder();
}
/**
*
* Timeout for topology refresh request. If not set, this defaults to 3s.
*
*
* .google.protobuf.Duration cluster_refresh_timeout = 2 [(.validate.rules) = { ... }
*/
public com.google.protobuf.DurationOrBuilder getClusterRefreshTimeoutOrBuilder() {
if (clusterRefreshTimeoutBuilder_ != null) {
return clusterRefreshTimeoutBuilder_.getMessageOrBuilder();
} else {
return clusterRefreshTimeout_ == null ?
com.google.protobuf.Duration.getDefaultInstance() : clusterRefreshTimeout_;
}
}
/**
*
* Timeout for topology refresh request. If not set, this defaults to 3s.
*
*
* .google.protobuf.Duration cluster_refresh_timeout = 2 [(.validate.rules) = { ... }
*/
private com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Duration, com.google.protobuf.Duration.Builder, com.google.protobuf.DurationOrBuilder>
getClusterRefreshTimeoutFieldBuilder() {
if (clusterRefreshTimeoutBuilder_ == null) {
clusterRefreshTimeoutBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Duration, com.google.protobuf.Duration.Builder, com.google.protobuf.DurationOrBuilder>(
getClusterRefreshTimeout(),
getParentForChildren(),
isClean());
clusterRefreshTimeout_ = null;
}
return clusterRefreshTimeoutBuilder_;
}
private com.google.protobuf.Duration redirectRefreshInterval_;
private com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Duration, com.google.protobuf.Duration.Builder, com.google.protobuf.DurationOrBuilder> redirectRefreshIntervalBuilder_;
/**
*
* The minimum interval that must pass after triggering a topology refresh request before a new
* request can possibly be triggered again. Any errors received during one of these
* time intervals are ignored. If not set, this defaults to 5s.
*
*
* .google.protobuf.Duration redirect_refresh_interval = 3;
* @return Whether the redirectRefreshInterval field is set.
*/
public boolean hasRedirectRefreshInterval() {
return ((bitField0_ & 0x00000004) != 0);
}
/**
*
* The minimum interval that must pass after triggering a topology refresh request before a new
* request can possibly be triggered again. Any errors received during one of these
* time intervals are ignored. If not set, this defaults to 5s.
*
*
* .google.protobuf.Duration redirect_refresh_interval = 3;
* @return The redirectRefreshInterval.
*/
public com.google.protobuf.Duration getRedirectRefreshInterval() {
if (redirectRefreshIntervalBuilder_ == null) {
return redirectRefreshInterval_ == null ? com.google.protobuf.Duration.getDefaultInstance() : redirectRefreshInterval_;
} else {
return redirectRefreshIntervalBuilder_.getMessage();
}
}
/**
*
* The minimum interval that must pass after triggering a topology refresh request before a new
* request can possibly be triggered again. Any errors received during one of these
* time intervals are ignored. If not set, this defaults to 5s.
*
*
* .google.protobuf.Duration redirect_refresh_interval = 3;
*/
public Builder setRedirectRefreshInterval(com.google.protobuf.Duration value) {
if (redirectRefreshIntervalBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
redirectRefreshInterval_ = value;
} else {
redirectRefreshIntervalBuilder_.setMessage(value);
}
bitField0_ |= 0x00000004;
onChanged();
return this;
}
/**
*
* The minimum interval that must pass after triggering a topology refresh request before a new
* request can possibly be triggered again. Any errors received during one of these
* time intervals are ignored. If not set, this defaults to 5s.
*
*
* .google.protobuf.Duration redirect_refresh_interval = 3;
*/
public Builder setRedirectRefreshInterval(
com.google.protobuf.Duration.Builder builderForValue) {
if (redirectRefreshIntervalBuilder_ == null) {
redirectRefreshInterval_ = builderForValue.build();
} else {
redirectRefreshIntervalBuilder_.setMessage(builderForValue.build());
}
bitField0_ |= 0x00000004;
onChanged();
return this;
}
/**
*
* The minimum interval that must pass after triggering a topology refresh request before a new
* request can possibly be triggered again. Any errors received during one of these
* time intervals are ignored. If not set, this defaults to 5s.
*
*
* .google.protobuf.Duration redirect_refresh_interval = 3;
*/
public Builder mergeRedirectRefreshInterval(com.google.protobuf.Duration value) {
if (redirectRefreshIntervalBuilder_ == null) {
if (((bitField0_ & 0x00000004) != 0) &&
redirectRefreshInterval_ != null &&
redirectRefreshInterval_ != com.google.protobuf.Duration.getDefaultInstance()) {
getRedirectRefreshIntervalBuilder().mergeFrom(value);
} else {
redirectRefreshInterval_ = value;
}
} else {
redirectRefreshIntervalBuilder_.mergeFrom(value);
}
if (redirectRefreshInterval_ != null) {
bitField0_ |= 0x00000004;
onChanged();
}
return this;
}
/**
*
* The minimum interval that must pass after triggering a topology refresh request before a new
* request can possibly be triggered again. Any errors received during one of these
* time intervals are ignored. If not set, this defaults to 5s.
*
*
* .google.protobuf.Duration redirect_refresh_interval = 3;
*/
public Builder clearRedirectRefreshInterval() {
bitField0_ = (bitField0_ & ~0x00000004);
redirectRefreshInterval_ = null;
if (redirectRefreshIntervalBuilder_ != null) {
redirectRefreshIntervalBuilder_.dispose();
redirectRefreshIntervalBuilder_ = null;
}
onChanged();
return this;
}
/**
*
* The minimum interval that must pass after triggering a topology refresh request before a new
* request can possibly be triggered again. Any errors received during one of these
* time intervals are ignored. If not set, this defaults to 5s.
*
*
* .google.protobuf.Duration redirect_refresh_interval = 3;
*/
public com.google.protobuf.Duration.Builder getRedirectRefreshIntervalBuilder() {
bitField0_ |= 0x00000004;
onChanged();
return getRedirectRefreshIntervalFieldBuilder().getBuilder();
}
/**
*
* The minimum interval that must pass after triggering a topology refresh request before a new
* request can possibly be triggered again. Any errors received during one of these
* time intervals are ignored. If not set, this defaults to 5s.
*
*
* .google.protobuf.Duration redirect_refresh_interval = 3;
*/
public com.google.protobuf.DurationOrBuilder getRedirectRefreshIntervalOrBuilder() {
if (redirectRefreshIntervalBuilder_ != null) {
return redirectRefreshIntervalBuilder_.getMessageOrBuilder();
} else {
return redirectRefreshInterval_ == null ?
com.google.protobuf.Duration.getDefaultInstance() : redirectRefreshInterval_;
}
}
/**
*
* The minimum interval that must pass after triggering a topology refresh request before a new
* request can possibly be triggered again. Any errors received during one of these
* time intervals are ignored. If not set, this defaults to 5s.
*
*
* .google.protobuf.Duration redirect_refresh_interval = 3;
*/
private com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Duration, com.google.protobuf.Duration.Builder, com.google.protobuf.DurationOrBuilder>
getRedirectRefreshIntervalFieldBuilder() {
if (redirectRefreshIntervalBuilder_ == null) {
redirectRefreshIntervalBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Duration, com.google.protobuf.Duration.Builder, com.google.protobuf.DurationOrBuilder>(
getRedirectRefreshInterval(),
getParentForChildren(),
isClean());
redirectRefreshInterval_ = null;
}
return redirectRefreshIntervalBuilder_;
}
private com.google.protobuf.UInt32Value redirectRefreshThreshold_;
private com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.UInt32Value, com.google.protobuf.UInt32Value.Builder, com.google.protobuf.UInt32ValueOrBuilder> redirectRefreshThresholdBuilder_;
/**
*
* The number of redirection errors that must be received before
* triggering a topology refresh request. If not set, this defaults to 5.
* If this is set to 0, topology refresh after redirect is disabled.
*
*
* .google.protobuf.UInt32Value redirect_refresh_threshold = 4;
* @return Whether the redirectRefreshThreshold field is set.
*/
public boolean hasRedirectRefreshThreshold() {
return ((bitField0_ & 0x00000008) != 0);
}
/**
*
* The number of redirection errors that must be received before
* triggering a topology refresh request. If not set, this defaults to 5.
* If this is set to 0, topology refresh after redirect is disabled.
*
*
* .google.protobuf.UInt32Value redirect_refresh_threshold = 4;
* @return The redirectRefreshThreshold.
*/
public com.google.protobuf.UInt32Value getRedirectRefreshThreshold() {
if (redirectRefreshThresholdBuilder_ == null) {
return redirectRefreshThreshold_ == null ? com.google.protobuf.UInt32Value.getDefaultInstance() : redirectRefreshThreshold_;
} else {
return redirectRefreshThresholdBuilder_.getMessage();
}
}
/**
*
* The number of redirection errors that must be received before
* triggering a topology refresh request. If not set, this defaults to 5.
* If this is set to 0, topology refresh after redirect is disabled.
*
*
* .google.protobuf.UInt32Value redirect_refresh_threshold = 4;
*/
public Builder setRedirectRefreshThreshold(com.google.protobuf.UInt32Value value) {
if (redirectRefreshThresholdBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
redirectRefreshThreshold_ = value;
} else {
redirectRefreshThresholdBuilder_.setMessage(value);
}
bitField0_ |= 0x00000008;
onChanged();
return this;
}
/**
*
* The number of redirection errors that must be received before
* triggering a topology refresh request. If not set, this defaults to 5.
* If this is set to 0, topology refresh after redirect is disabled.
*
*
* .google.protobuf.UInt32Value redirect_refresh_threshold = 4;
*/
public Builder setRedirectRefreshThreshold(
com.google.protobuf.UInt32Value.Builder builderForValue) {
if (redirectRefreshThresholdBuilder_ == null) {
redirectRefreshThreshold_ = builderForValue.build();
} else {
redirectRefreshThresholdBuilder_.setMessage(builderForValue.build());
}
bitField0_ |= 0x00000008;
onChanged();
return this;
}
/**
*
* The number of redirection errors that must be received before
* triggering a topology refresh request. If not set, this defaults to 5.
* If this is set to 0, topology refresh after redirect is disabled.
*
*
* .google.protobuf.UInt32Value redirect_refresh_threshold = 4;
*/
public Builder mergeRedirectRefreshThreshold(com.google.protobuf.UInt32Value value) {
if (redirectRefreshThresholdBuilder_ == null) {
if (((bitField0_ & 0x00000008) != 0) &&
redirectRefreshThreshold_ != null &&
redirectRefreshThreshold_ != com.google.protobuf.UInt32Value.getDefaultInstance()) {
getRedirectRefreshThresholdBuilder().mergeFrom(value);
} else {
redirectRefreshThreshold_ = value;
}
} else {
redirectRefreshThresholdBuilder_.mergeFrom(value);
}
if (redirectRefreshThreshold_ != null) {
bitField0_ |= 0x00000008;
onChanged();
}
return this;
}
/**
*
* The number of redirection errors that must be received before
* triggering a topology refresh request. If not set, this defaults to 5.
* If this is set to 0, topology refresh after redirect is disabled.
*
*
* .google.protobuf.UInt32Value redirect_refresh_threshold = 4;
*/
public Builder clearRedirectRefreshThreshold() {
bitField0_ = (bitField0_ & ~0x00000008);
redirectRefreshThreshold_ = null;
if (redirectRefreshThresholdBuilder_ != null) {
redirectRefreshThresholdBuilder_.dispose();
redirectRefreshThresholdBuilder_ = null;
}
onChanged();
return this;
}
/**
*
* The number of redirection errors that must be received before
* triggering a topology refresh request. If not set, this defaults to 5.
* If this is set to 0, topology refresh after redirect is disabled.
*
*
* .google.protobuf.UInt32Value redirect_refresh_threshold = 4;
*/
public com.google.protobuf.UInt32Value.Builder getRedirectRefreshThresholdBuilder() {
bitField0_ |= 0x00000008;
onChanged();
return getRedirectRefreshThresholdFieldBuilder().getBuilder();
}
/**
*
* The number of redirection errors that must be received before
* triggering a topology refresh request. If not set, this defaults to 5.
* If this is set to 0, topology refresh after redirect is disabled.
*
*
* .google.protobuf.UInt32Value redirect_refresh_threshold = 4;
*/
public com.google.protobuf.UInt32ValueOrBuilder getRedirectRefreshThresholdOrBuilder() {
if (redirectRefreshThresholdBuilder_ != null) {
return redirectRefreshThresholdBuilder_.getMessageOrBuilder();
} else {
return redirectRefreshThreshold_ == null ?
com.google.protobuf.UInt32Value.getDefaultInstance() : redirectRefreshThreshold_;
}
}
/**
*
* The number of redirection errors that must be received before
* triggering a topology refresh request. If not set, this defaults to 5.
* If this is set to 0, topology refresh after redirect is disabled.
*
*
* .google.protobuf.UInt32Value redirect_refresh_threshold = 4;
*/
private com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.UInt32Value, com.google.protobuf.UInt32Value.Builder, com.google.protobuf.UInt32ValueOrBuilder>
getRedirectRefreshThresholdFieldBuilder() {
if (redirectRefreshThresholdBuilder_ == null) {
redirectRefreshThresholdBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.UInt32Value, com.google.protobuf.UInt32Value.Builder, com.google.protobuf.UInt32ValueOrBuilder>(
getRedirectRefreshThreshold(),
getParentForChildren(),
isClean());
redirectRefreshThreshold_ = null;
}
return redirectRefreshThresholdBuilder_;
}
private int failureRefreshThreshold_ ;
/**
*
* The number of failures that must be received before triggering a topology refresh request.
* If not set, this defaults to 0, which disables the topology refresh due to failure.
*
*
* uint32 failure_refresh_threshold = 5;
* @return The failureRefreshThreshold.
*/
@java.lang.Override
public int getFailureRefreshThreshold() {
return failureRefreshThreshold_;
}
/**
*
* The number of failures that must be received before triggering a topology refresh request.
* If not set, this defaults to 0, which disables the topology refresh due to failure.
*
*
* uint32 failure_refresh_threshold = 5;
* @param value The failureRefreshThreshold to set.
* @return This builder for chaining.
*/
public Builder setFailureRefreshThreshold(int value) {
failureRefreshThreshold_ = value;
bitField0_ |= 0x00000010;
onChanged();
return this;
}
/**
*
* The number of failures that must be received before triggering a topology refresh request.
* If not set, this defaults to 0, which disables the topology refresh due to failure.
*
*
* uint32 failure_refresh_threshold = 5;
* @return This builder for chaining.
*/
public Builder clearFailureRefreshThreshold() {
bitField0_ = (bitField0_ & ~0x00000010);
failureRefreshThreshold_ = 0;
onChanged();
return this;
}
private int hostDegradedRefreshThreshold_ ;
/**
*
* The number of hosts became degraded or unhealthy before triggering a topology refresh request.
* If not set, this defaults to 0, which disables the topology refresh due to degraded or
* unhealthy host.
*
*
* uint32 host_degraded_refresh_threshold = 6;
* @return The hostDegradedRefreshThreshold.
*/
@java.lang.Override
public int getHostDegradedRefreshThreshold() {
return hostDegradedRefreshThreshold_;
}
/**
*
* The number of hosts became degraded or unhealthy before triggering a topology refresh request.
* If not set, this defaults to 0, which disables the topology refresh due to degraded or
* unhealthy host.
*
*
* uint32 host_degraded_refresh_threshold = 6;
* @param value The hostDegradedRefreshThreshold to set.
* @return This builder for chaining.
*/
public Builder setHostDegradedRefreshThreshold(int value) {
hostDegradedRefreshThreshold_ = value;
bitField0_ |= 0x00000020;
onChanged();
return this;
}
/**
*
* The number of hosts became degraded or unhealthy before triggering a topology refresh request.
* If not set, this defaults to 0, which disables the topology refresh due to degraded or
* unhealthy host.
*
*
* uint32 host_degraded_refresh_threshold = 6;
* @return This builder for chaining.
*/
public Builder clearHostDegradedRefreshThreshold() {
bitField0_ = (bitField0_ & ~0x00000020);
hostDegradedRefreshThreshold_ = 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.extensions.clusters.redis.v3.RedisClusterConfig)
}
// @@protoc_insertion_point(class_scope:envoy.extensions.clusters.redis.v3.RedisClusterConfig)
private static final io.envoyproxy.envoy.extensions.clusters.redis.v3.RedisClusterConfig DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new io.envoyproxy.envoy.extensions.clusters.redis.v3.RedisClusterConfig();
}
public static io.envoyproxy.envoy.extensions.clusters.redis.v3.RedisClusterConfig getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public RedisClusterConfig 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.extensions.clusters.redis.v3.RedisClusterConfig getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy