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) {
}
}
@java.lang.Override
public Builder clear() {
super.clear();
if (clusterRefreshRateBuilder_ == null) {
clusterRefreshRate_ = null;
} else {
clusterRefreshRate_ = null;
clusterRefreshRateBuilder_ = null;
}
if (clusterRefreshTimeoutBuilder_ == null) {
clusterRefreshTimeout_ = null;
} else {
clusterRefreshTimeout_ = null;
clusterRefreshTimeoutBuilder_ = null;
}
if (redirectRefreshIntervalBuilder_ == null) {
redirectRefreshInterval_ = null;
} else {
redirectRefreshInterval_ = null;
redirectRefreshIntervalBuilder_ = null;
}
if (redirectRefreshThresholdBuilder_ == null) {
redirectRefreshThreshold_ = null;
} else {
redirectRefreshThreshold_ = null;
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 (clusterRefreshRateBuilder_ == null) {
result.clusterRefreshRate_ = clusterRefreshRate_;
} else {
result.clusterRefreshRate_ = clusterRefreshRateBuilder_.build();
}
if (clusterRefreshTimeoutBuilder_ == null) {
result.clusterRefreshTimeout_ = clusterRefreshTimeout_;
} else {
result.clusterRefreshTimeout_ = clusterRefreshTimeoutBuilder_.build();
}
if (redirectRefreshIntervalBuilder_ == null) {
result.redirectRefreshInterval_ = redirectRefreshInterval_;
} else {
result.redirectRefreshInterval_ = redirectRefreshIntervalBuilder_.build();
}
if (redirectRefreshThresholdBuilder_ == null) {
result.redirectRefreshThreshold_ = redirectRefreshThreshold_;
} else {
result.redirectRefreshThreshold_ = redirectRefreshThresholdBuilder_.build();
}
result.failureRefreshThreshold_ = failureRefreshThreshold_;
result.hostDegradedRefreshThreshold_ = hostDegradedRefreshThreshold_;
onBuilt();
return result;
}
@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.unknownFields);
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 {
io.envoyproxy.envoy.extensions.clusters.redis.v3.RedisClusterConfig parsedMessage = null;
try {
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
parsedMessage = (io.envoyproxy.envoy.extensions.clusters.redis.v3.RedisClusterConfig) e.getUnfinishedMessage();
throw e.unwrapIOException();
} finally {
if (parsedMessage != null) {
mergeFrom(parsedMessage);
}
}
return this;
}
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 clusterRefreshRateBuilder_ != null || clusterRefreshRate_ != null;
}
/**
*
* 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;
onChanged();
} else {
clusterRefreshRateBuilder_.setMessage(value);
}
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();
onChanged();
} else {
clusterRefreshRateBuilder_.setMessage(builderForValue.build());
}
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 (clusterRefreshRate_ != null) {
clusterRefreshRate_ =
com.google.protobuf.Duration.newBuilder(clusterRefreshRate_).mergeFrom(value).buildPartial();
} else {
clusterRefreshRate_ = value;
}
onChanged();
} else {
clusterRefreshRateBuilder_.mergeFrom(value);
}
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() {
if (clusterRefreshRateBuilder_ == null) {
clusterRefreshRate_ = null;
onChanged();
} else {
clusterRefreshRate_ = null;
clusterRefreshRateBuilder_ = null;
}
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() {
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 clusterRefreshTimeoutBuilder_ != null || clusterRefreshTimeout_ != null;
}
/**
*
* 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;
onChanged();
} else {
clusterRefreshTimeoutBuilder_.setMessage(value);
}
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();
onChanged();
} else {
clusterRefreshTimeoutBuilder_.setMessage(builderForValue.build());
}
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 (clusterRefreshTimeout_ != null) {
clusterRefreshTimeout_ =
com.google.protobuf.Duration.newBuilder(clusterRefreshTimeout_).mergeFrom(value).buildPartial();
} else {
clusterRefreshTimeout_ = value;
}
onChanged();
} else {
clusterRefreshTimeoutBuilder_.mergeFrom(value);
}
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() {
if (clusterRefreshTimeoutBuilder_ == null) {
clusterRefreshTimeout_ = null;
onChanged();
} else {
clusterRefreshTimeout_ = null;
clusterRefreshTimeoutBuilder_ = null;
}
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() {
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 redirectRefreshIntervalBuilder_ != null || redirectRefreshInterval_ != null;
}
/**
*
* 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;
onChanged();
} else {
redirectRefreshIntervalBuilder_.setMessage(value);
}
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();
onChanged();
} else {
redirectRefreshIntervalBuilder_.setMessage(builderForValue.build());
}
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 (redirectRefreshInterval_ != null) {
redirectRefreshInterval_ =
com.google.protobuf.Duration.newBuilder(redirectRefreshInterval_).mergeFrom(value).buildPartial();
} else {
redirectRefreshInterval_ = value;
}
onChanged();
} else {
redirectRefreshIntervalBuilder_.mergeFrom(value);
}
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() {
if (redirectRefreshIntervalBuilder_ == null) {
redirectRefreshInterval_ = null;
onChanged();
} else {
redirectRefreshInterval_ = null;
redirectRefreshIntervalBuilder_ = null;
}
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() {
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 redirectRefreshThresholdBuilder_ != null || redirectRefreshThreshold_ != null;
}
/**
*
* 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;
onChanged();
} else {
redirectRefreshThresholdBuilder_.setMessage(value);
}
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();
onChanged();
} else {
redirectRefreshThresholdBuilder_.setMessage(builderForValue.build());
}
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 (redirectRefreshThreshold_ != null) {
redirectRefreshThreshold_ =
com.google.protobuf.UInt32Value.newBuilder(redirectRefreshThreshold_).mergeFrom(value).buildPartial();
} else {
redirectRefreshThreshold_ = value;
}
onChanged();
} else {
redirectRefreshThresholdBuilder_.mergeFrom(value);
}
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() {
if (redirectRefreshThresholdBuilder_ == null) {
redirectRefreshThreshold_ = null;
onChanged();
} else {
redirectRefreshThreshold_ = null;
redirectRefreshThresholdBuilder_ = null;
}
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() {
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;
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() {
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;
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() {
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 {
return new RedisClusterConfig(input, extensionRegistry);
}
};
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;
}
}