Class RetryPolicy
- java.lang.Object
-
- com.google.protobuf.AbstractMessageLite
-
- com.google.protobuf.AbstractMessage
-
- com.google.protobuf.GeneratedMessage
-
- io.envoyproxy.envoy.config.route.v3.RetryPolicy
-
- All Implemented Interfaces:
com.google.protobuf.Message
,com.google.protobuf.MessageLite
,com.google.protobuf.MessageLiteOrBuilder
,com.google.protobuf.MessageOrBuilder
,RetryPolicyOrBuilder
,java.io.Serializable
public final class RetryPolicy extends com.google.protobuf.GeneratedMessage implements RetryPolicyOrBuilder
HTTP retry :ref:`architecture overview <arch_overview_http_routing_retry>`. [#next-free-field: 14]
Protobuf typeenvoy.config.route.v3.RetryPolicy
- See Also:
- Serialized Form
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
RetryPolicy.Builder
HTTP retry :ref:`architecture overview <arch_overview_http_routing_retry>`.static class
RetryPolicy.RateLimitedRetryBackOff
A retry back-off strategy that applies when the upstream server rate limits the request.static interface
RetryPolicy.RateLimitedRetryBackOffOrBuilder
static class
RetryPolicy.ResetHeader
Protobuf typeenvoy.config.route.v3.RetryPolicy.ResetHeader
static class
RetryPolicy.ResetHeaderFormat
Protobuf enumenvoy.config.route.v3.RetryPolicy.ResetHeaderFormat
static interface
RetryPolicy.ResetHeaderOrBuilder
static class
RetryPolicy.RetryBackOff
Protobuf typeenvoy.config.route.v3.RetryPolicy.RetryBackOff
static interface
RetryPolicy.RetryBackOffOrBuilder
static class
RetryPolicy.RetryHostPredicate
Protobuf typeenvoy.config.route.v3.RetryPolicy.RetryHostPredicate
static interface
RetryPolicy.RetryHostPredicateOrBuilder
static class
RetryPolicy.RetryPriority
Protobuf typeenvoy.config.route.v3.RetryPolicy.RetryPriority
static interface
RetryPolicy.RetryPriorityOrBuilder
-
Nested classes/interfaces inherited from class com.google.protobuf.GeneratedMessage
com.google.protobuf.GeneratedMessage.ExtendableBuilder<MessageT extends com.google.protobuf.GeneratedMessage.ExtendableMessage<MessageT>,BuilderT extends com.google.protobuf.GeneratedMessage.ExtendableBuilder<MessageT,BuilderT>>, com.google.protobuf.GeneratedMessage.ExtendableMessage<MessageT extends com.google.protobuf.GeneratedMessage.ExtendableMessage<MessageT>>, com.google.protobuf.GeneratedMessage.ExtendableMessageOrBuilder<MessageT extends com.google.protobuf.GeneratedMessage.ExtendableMessage<MessageT>>, com.google.protobuf.GeneratedMessage.FieldAccessorTable, com.google.protobuf.GeneratedMessage.GeneratedExtension<ContainingT extends com.google.protobuf.Message,T extends java.lang.Object>, com.google.protobuf.GeneratedMessage.UnusedPrivateParameter
-
-
Field Summary
-
Constructor Summary
Constructors Modifier Constructor Description private
RetryPolicy()
private
RetryPolicy(com.google.protobuf.GeneratedMessage.Builder<?> builder)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
equals(java.lang.Object obj)
static RetryPolicy
getDefaultInstance()
RetryPolicy
getDefaultInstanceForType()
static com.google.protobuf.Descriptors.Descriptor
getDescriptor()
long
getHostSelectionRetryMaxAttempts()
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.com.google.protobuf.UInt32Value
getNumRetries()
Specifies the allowed number of retries.com.google.protobuf.UInt32ValueOrBuilder
getNumRetriesOrBuilder()
Specifies the allowed number of retries.com.google.protobuf.Parser<RetryPolicy>
getParserForType()
com.google.protobuf.Duration
getPerTryIdleTimeout()
Specifies an upstream idle timeout per retry attempt (including the initial attempt).com.google.protobuf.DurationOrBuilder
getPerTryIdleTimeoutOrBuilder()
Specifies an upstream idle timeout per retry attempt (including the initial attempt).com.google.protobuf.Duration
getPerTryTimeout()
Specifies a non-zero upstream timeout per retry attempt (including the initial attempt).com.google.protobuf.DurationOrBuilder
getPerTryTimeoutOrBuilder()
Specifies a non-zero upstream timeout per retry attempt (including the initial attempt).RetryPolicy.RateLimitedRetryBackOff
getRateLimitedRetryBackOff()
Specifies parameters that control a retry back-off strategy that is used when the request is rate limited by the upstream server.RetryPolicy.RateLimitedRetryBackOffOrBuilder
getRateLimitedRetryBackOffOrBuilder()
Specifies parameters that control a retry back-off strategy that is used when the request is rate limited by the upstream server.HeaderMatcher
getRetriableHeaders(int index)
HTTP response headers that trigger a retry if present in the response.int
getRetriableHeadersCount()
HTTP response headers that trigger a retry if present in the response.java.util.List<HeaderMatcher>
getRetriableHeadersList()
HTTP response headers that trigger a retry if present in the response.HeaderMatcherOrBuilder
getRetriableHeadersOrBuilder(int index)
HTTP response headers that trigger a retry if present in the response.java.util.List<? extends HeaderMatcherOrBuilder>
getRetriableHeadersOrBuilderList()
HTTP response headers that trigger a retry if present in the response.HeaderMatcher
getRetriableRequestHeaders(int index)
HTTP headers which must be present in the request for retries to be attempted.int
getRetriableRequestHeadersCount()
HTTP headers which must be present in the request for retries to be attempted.java.util.List<HeaderMatcher>
getRetriableRequestHeadersList()
HTTP headers which must be present in the request for retries to be attempted.HeaderMatcherOrBuilder
getRetriableRequestHeadersOrBuilder(int index)
HTTP headers which must be present in the request for retries to be attempted.java.util.List<? extends HeaderMatcherOrBuilder>
getRetriableRequestHeadersOrBuilderList()
HTTP headers which must be present in the request for retries to be attempted.int
getRetriableStatusCodes(int index)
HTTP status codes that should trigger a retry in addition to those specified by retry_on.int
getRetriableStatusCodesCount()
HTTP status codes that should trigger a retry in addition to those specified by retry_on.java.util.List<java.lang.Integer>
getRetriableStatusCodesList()
HTTP status codes that should trigger a retry in addition to those specified by retry_on.RetryPolicy.RetryBackOff
getRetryBackOff()
Specifies parameters that control exponential retry back off.RetryPolicy.RetryBackOffOrBuilder
getRetryBackOffOrBuilder()
Specifies parameters that control exponential retry back off.RetryPolicy.RetryHostPredicate
getRetryHostPredicate(int index)
Specifies a collection of RetryHostPredicates that will be consulted when selecting a host for retries.int
getRetryHostPredicateCount()
Specifies a collection of RetryHostPredicates that will be consulted when selecting a host for retries.java.util.List<RetryPolicy.RetryHostPredicate>
getRetryHostPredicateList()
Specifies a collection of RetryHostPredicates that will be consulted when selecting a host for retries.RetryPolicy.RetryHostPredicateOrBuilder
getRetryHostPredicateOrBuilder(int index)
Specifies a collection of RetryHostPredicates that will be consulted when selecting a host for retries.java.util.List<? extends RetryPolicy.RetryHostPredicateOrBuilder>
getRetryHostPredicateOrBuilderList()
Specifies a collection of RetryHostPredicates that will be consulted when selecting a host for retries.java.lang.String
getRetryOn()
Specifies the conditions under which retry takes place.com.google.protobuf.ByteString
getRetryOnBytes()
Specifies the conditions under which retry takes place.TypedExtensionConfig
getRetryOptionsPredicates(int index)
Retry options predicates that will be applied prior to retrying a request.int
getRetryOptionsPredicatesCount()
Retry options predicates that will be applied prior to retrying a request.java.util.List<TypedExtensionConfig>
getRetryOptionsPredicatesList()
Retry options predicates that will be applied prior to retrying a request.TypedExtensionConfigOrBuilder
getRetryOptionsPredicatesOrBuilder(int index)
Retry options predicates that will be applied prior to retrying a request.java.util.List<? extends TypedExtensionConfigOrBuilder>
getRetryOptionsPredicatesOrBuilderList()
Retry options predicates that will be applied prior to retrying a request.RetryPolicy.RetryPriority
getRetryPriority()
Specifies an implementation of a RetryPriority which is used to determine the distribution of load across priorities used for retries.RetryPolicy.RetryPriorityOrBuilder
getRetryPriorityOrBuilder()
Specifies an implementation of a RetryPriority which is used to determine the distribution of load across priorities used for retries.int
getSerializedSize()
int
hashCode()
boolean
hasNumRetries()
Specifies the allowed number of retries.boolean
hasPerTryIdleTimeout()
Specifies an upstream idle timeout per retry attempt (including the initial attempt).boolean
hasPerTryTimeout()
Specifies a non-zero upstream timeout per retry attempt (including the initial attempt).boolean
hasRateLimitedRetryBackOff()
Specifies parameters that control a retry back-off strategy that is used when the request is rate limited by the upstream server.boolean
hasRetryBackOff()
Specifies parameters that control exponential retry back off.boolean
hasRetryPriority()
Specifies an implementation of a RetryPriority which is used to determine the distribution of load across priorities used for retries.protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
internalGetFieldAccessorTable()
boolean
isInitialized()
static RetryPolicy.Builder
newBuilder()
static RetryPolicy.Builder
newBuilder(RetryPolicy prototype)
RetryPolicy.Builder
newBuilderForType()
protected RetryPolicy.Builder
newBuilderForType(com.google.protobuf.AbstractMessage.BuilderParent parent)
static RetryPolicy
parseDelimitedFrom(java.io.InputStream input)
static RetryPolicy
parseDelimitedFrom(java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
static RetryPolicy
parseFrom(byte[] data)
static RetryPolicy
parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
static RetryPolicy
parseFrom(com.google.protobuf.ByteString data)
static RetryPolicy
parseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
static RetryPolicy
parseFrom(com.google.protobuf.CodedInputStream input)
static RetryPolicy
parseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
static RetryPolicy
parseFrom(java.io.InputStream input)
static RetryPolicy
parseFrom(java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
static RetryPolicy
parseFrom(java.nio.ByteBuffer data)
static RetryPolicy
parseFrom(java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
static com.google.protobuf.Parser<RetryPolicy>
parser()
RetryPolicy.Builder
toBuilder()
void
writeTo(com.google.protobuf.CodedOutputStream output)
-
Methods inherited from class com.google.protobuf.GeneratedMessage
canUseUnsafe, computeStringSize, computeStringSizeNoTag, emptyBooleanList, emptyDoubleList, emptyFloatList, emptyIntList, emptyList, emptyLongList, getAllFields, getDescriptorForType, getField, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof, internalGetMapField, internalGetMapFieldReflection, isStringEmpty, makeMutableCopy, makeMutableCopy, mergeFromAndMakeImmutableInternal, newFileScopedGeneratedExtension, newInstance, newMessageScopedGeneratedExtension, parseDelimitedWithIOException, parseDelimitedWithIOException, parseUnknownField, parseUnknownFieldProto3, parseWithIOException, parseWithIOException, parseWithIOException, parseWithIOException, serializeBooleanMapTo, serializeIntegerMapTo, serializeLongMapTo, serializeStringMapTo, writeReplace, writeString, writeStringNoTag
-
Methods inherited from class com.google.protobuf.AbstractMessage
findInitializationErrors, getInitializationErrorString, hashFields, toString
-
Methods inherited from class com.google.protobuf.AbstractMessageLite
addAll, checkByteStringIsUtf8, toByteArray, toByteString, writeDelimitedTo, writeTo
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
-
-
-
Field Detail
-
serialVersionUID
private static final long serialVersionUID
- See Also:
- Constant Field Values
-
bitField0_
private int bitField0_
-
RETRY_ON_FIELD_NUMBER
public static final int RETRY_ON_FIELD_NUMBER
- See Also:
- Constant Field Values
-
retryOn_
private volatile java.lang.Object retryOn_
-
NUM_RETRIES_FIELD_NUMBER
public static final int NUM_RETRIES_FIELD_NUMBER
- See Also:
- Constant Field Values
-
numRetries_
private com.google.protobuf.UInt32Value numRetries_
-
PER_TRY_TIMEOUT_FIELD_NUMBER
public static final int PER_TRY_TIMEOUT_FIELD_NUMBER
- See Also:
- Constant Field Values
-
perTryTimeout_
private com.google.protobuf.Duration perTryTimeout_
-
PER_TRY_IDLE_TIMEOUT_FIELD_NUMBER
public static final int PER_TRY_IDLE_TIMEOUT_FIELD_NUMBER
- See Also:
- Constant Field Values
-
perTryIdleTimeout_
private com.google.protobuf.Duration perTryIdleTimeout_
-
RETRY_PRIORITY_FIELD_NUMBER
public static final int RETRY_PRIORITY_FIELD_NUMBER
- See Also:
- Constant Field Values
-
retryPriority_
private RetryPolicy.RetryPriority retryPriority_
-
RETRY_HOST_PREDICATE_FIELD_NUMBER
public static final int RETRY_HOST_PREDICATE_FIELD_NUMBER
- See Also:
- Constant Field Values
-
retryHostPredicate_
private java.util.List<RetryPolicy.RetryHostPredicate> retryHostPredicate_
-
RETRY_OPTIONS_PREDICATES_FIELD_NUMBER
public static final int RETRY_OPTIONS_PREDICATES_FIELD_NUMBER
- See Also:
- Constant Field Values
-
retryOptionsPredicates_
private java.util.List<TypedExtensionConfig> retryOptionsPredicates_
-
HOST_SELECTION_RETRY_MAX_ATTEMPTS_FIELD_NUMBER
public static final int HOST_SELECTION_RETRY_MAX_ATTEMPTS_FIELD_NUMBER
- See Also:
- Constant Field Values
-
hostSelectionRetryMaxAttempts_
private long hostSelectionRetryMaxAttempts_
-
RETRIABLE_STATUS_CODES_FIELD_NUMBER
public static final int RETRIABLE_STATUS_CODES_FIELD_NUMBER
- See Also:
- Constant Field Values
-
retriableStatusCodes_
private com.google.protobuf.Internal.IntList retriableStatusCodes_
-
retriableStatusCodesMemoizedSerializedSize
private int retriableStatusCodesMemoizedSerializedSize
-
RETRY_BACK_OFF_FIELD_NUMBER
public static final int RETRY_BACK_OFF_FIELD_NUMBER
- See Also:
- Constant Field Values
-
retryBackOff_
private RetryPolicy.RetryBackOff retryBackOff_
-
RATE_LIMITED_RETRY_BACK_OFF_FIELD_NUMBER
public static final int RATE_LIMITED_RETRY_BACK_OFF_FIELD_NUMBER
- See Also:
- Constant Field Values
-
rateLimitedRetryBackOff_
private RetryPolicy.RateLimitedRetryBackOff rateLimitedRetryBackOff_
-
RETRIABLE_HEADERS_FIELD_NUMBER
public static final int RETRIABLE_HEADERS_FIELD_NUMBER
- See Also:
- Constant Field Values
-
retriableHeaders_
private java.util.List<HeaderMatcher> retriableHeaders_
-
RETRIABLE_REQUEST_HEADERS_FIELD_NUMBER
public static final int RETRIABLE_REQUEST_HEADERS_FIELD_NUMBER
- See Also:
- Constant Field Values
-
retriableRequestHeaders_
private java.util.List<HeaderMatcher> retriableRequestHeaders_
-
memoizedIsInitialized
private byte memoizedIsInitialized
-
DEFAULT_INSTANCE
private static final RetryPolicy DEFAULT_INSTANCE
-
PARSER
private static final com.google.protobuf.Parser<RetryPolicy> PARSER
-
-
Method Detail
-
getDescriptor
public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
-
internalGetFieldAccessorTable
protected com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()
- Specified by:
internalGetFieldAccessorTable
in classcom.google.protobuf.GeneratedMessage
-
getRetryOn
public java.lang.String getRetryOn()
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;
- Specified by:
getRetryOn
in interfaceRetryPolicyOrBuilder
- Returns:
- The retryOn.
-
getRetryOnBytes
public com.google.protobuf.ByteString getRetryOnBytes()
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;
- Specified by:
getRetryOnBytes
in interfaceRetryPolicyOrBuilder
- Returns:
- The bytes for retryOn.
-
hasNumRetries
public boolean hasNumRetries()
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) = { ... }
- Specified by:
hasNumRetries
in interfaceRetryPolicyOrBuilder
- Returns:
- Whether the numRetries field is set.
-
getNumRetries
public com.google.protobuf.UInt32Value getNumRetries()
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) = { ... }
- Specified by:
getNumRetries
in interfaceRetryPolicyOrBuilder
- Returns:
- The numRetries.
-
getNumRetriesOrBuilder
public com.google.protobuf.UInt32ValueOrBuilder getNumRetriesOrBuilder()
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) = { ... }
- Specified by:
getNumRetriesOrBuilder
in interfaceRetryPolicyOrBuilder
-
hasPerTryTimeout
public boolean hasPerTryTimeout()
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;
- Specified by:
hasPerTryTimeout
in interfaceRetryPolicyOrBuilder
- Returns:
- Whether the perTryTimeout field is set.
-
getPerTryTimeout
public com.google.protobuf.Duration getPerTryTimeout()
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;
- Specified by:
getPerTryTimeout
in interfaceRetryPolicyOrBuilder
- Returns:
- The perTryTimeout.
-
getPerTryTimeoutOrBuilder
public com.google.protobuf.DurationOrBuilder getPerTryTimeoutOrBuilder()
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;
- Specified by:
getPerTryTimeoutOrBuilder
in interfaceRetryPolicyOrBuilder
-
hasPerTryIdleTimeout
public boolean hasPerTryIdleTimeout()
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;
- Specified by:
hasPerTryIdleTimeout
in interfaceRetryPolicyOrBuilder
- Returns:
- Whether the perTryIdleTimeout field is set.
-
getPerTryIdleTimeout
public com.google.protobuf.Duration getPerTryIdleTimeout()
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;
- Specified by:
getPerTryIdleTimeout
in interfaceRetryPolicyOrBuilder
- Returns:
- The perTryIdleTimeout.
-
getPerTryIdleTimeoutOrBuilder
public com.google.protobuf.DurationOrBuilder getPerTryIdleTimeoutOrBuilder()
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;
- Specified by:
getPerTryIdleTimeoutOrBuilder
in interfaceRetryPolicyOrBuilder
-
hasRetryPriority
public boolean hasRetryPriority()
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;
- Specified by:
hasRetryPriority
in interfaceRetryPolicyOrBuilder
- Returns:
- Whether the retryPriority field is set.
-
getRetryPriority
public RetryPolicy.RetryPriority getRetryPriority()
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;
- Specified by:
getRetryPriority
in interfaceRetryPolicyOrBuilder
- Returns:
- The retryPriority.
-
getRetryPriorityOrBuilder
public RetryPolicy.RetryPriorityOrBuilder getRetryPriorityOrBuilder()
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;
- Specified by:
getRetryPriorityOrBuilder
in interfaceRetryPolicyOrBuilder
-
getRetryHostPredicateList
public java.util.List<RetryPolicy.RetryHostPredicate> getRetryHostPredicateList()
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;
- Specified by:
getRetryHostPredicateList
in interfaceRetryPolicyOrBuilder
-
getRetryHostPredicateOrBuilderList
public java.util.List<? extends RetryPolicy.RetryHostPredicateOrBuilder> getRetryHostPredicateOrBuilderList()
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;
- Specified by:
getRetryHostPredicateOrBuilderList
in interfaceRetryPolicyOrBuilder
-
getRetryHostPredicateCount
public int getRetryHostPredicateCount()
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;
- Specified by:
getRetryHostPredicateCount
in interfaceRetryPolicyOrBuilder
-
getRetryHostPredicate
public RetryPolicy.RetryHostPredicate getRetryHostPredicate(int 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;
- Specified by:
getRetryHostPredicate
in interfaceRetryPolicyOrBuilder
-
getRetryHostPredicateOrBuilder
public RetryPolicy.RetryHostPredicateOrBuilder getRetryHostPredicateOrBuilder(int 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;
- Specified by:
getRetryHostPredicateOrBuilder
in interfaceRetryPolicyOrBuilder
-
getRetryOptionsPredicatesList
public java.util.List<TypedExtensionConfig> getRetryOptionsPredicatesList()
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;
- Specified by:
getRetryOptionsPredicatesList
in interfaceRetryPolicyOrBuilder
-
getRetryOptionsPredicatesOrBuilderList
public java.util.List<? extends TypedExtensionConfigOrBuilder> getRetryOptionsPredicatesOrBuilderList()
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;
- Specified by:
getRetryOptionsPredicatesOrBuilderList
in interfaceRetryPolicyOrBuilder
-
getRetryOptionsPredicatesCount
public int getRetryOptionsPredicatesCount()
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;
- Specified by:
getRetryOptionsPredicatesCount
in interfaceRetryPolicyOrBuilder
-
getRetryOptionsPredicates
public TypedExtensionConfig getRetryOptionsPredicates(int 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;
- Specified by:
getRetryOptionsPredicates
in interfaceRetryPolicyOrBuilder
-
getRetryOptionsPredicatesOrBuilder
public TypedExtensionConfigOrBuilder getRetryOptionsPredicatesOrBuilder(int 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;
- Specified by:
getRetryOptionsPredicatesOrBuilder
in interfaceRetryPolicyOrBuilder
-
getHostSelectionRetryMaxAttempts
public long getHostSelectionRetryMaxAttempts()
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;
- Specified by:
getHostSelectionRetryMaxAttempts
in interfaceRetryPolicyOrBuilder
- Returns:
- The hostSelectionRetryMaxAttempts.
-
getRetriableStatusCodesList
public java.util.List<java.lang.Integer> getRetriableStatusCodesList()
HTTP status codes that should trigger a retry in addition to those specified by retry_on.
repeated uint32 retriable_status_codes = 7;
- Specified by:
getRetriableStatusCodesList
in interfaceRetryPolicyOrBuilder
- Returns:
- A list containing the retriableStatusCodes.
-
getRetriableStatusCodesCount
public int getRetriableStatusCodesCount()
HTTP status codes that should trigger a retry in addition to those specified by retry_on.
repeated uint32 retriable_status_codes = 7;
- Specified by:
getRetriableStatusCodesCount
in interfaceRetryPolicyOrBuilder
- Returns:
- The count of retriableStatusCodes.
-
getRetriableStatusCodes
public int getRetriableStatusCodes(int index)
HTTP status codes that should trigger a retry in addition to those specified by retry_on.
repeated uint32 retriable_status_codes = 7;
- Specified by:
getRetriableStatusCodes
in interfaceRetryPolicyOrBuilder
- Parameters:
index
- The index of the element to return.- Returns:
- The retriableStatusCodes at the given index.
-
hasRetryBackOff
public boolean hasRetryBackOff()
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;
- Specified by:
hasRetryBackOff
in interfaceRetryPolicyOrBuilder
- Returns:
- Whether the retryBackOff field is set.
-
getRetryBackOff
public RetryPolicy.RetryBackOff getRetryBackOff()
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;
- Specified by:
getRetryBackOff
in interfaceRetryPolicyOrBuilder
- Returns:
- The retryBackOff.
-
getRetryBackOffOrBuilder
public RetryPolicy.RetryBackOffOrBuilder getRetryBackOffOrBuilder()
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;
- Specified by:
getRetryBackOffOrBuilder
in interfaceRetryPolicyOrBuilder
-
hasRateLimitedRetryBackOff
public boolean hasRateLimitedRetryBackOff()
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;
- Specified by:
hasRateLimitedRetryBackOff
in interfaceRetryPolicyOrBuilder
- Returns:
- Whether the rateLimitedRetryBackOff field is set.
-
getRateLimitedRetryBackOff
public RetryPolicy.RateLimitedRetryBackOff getRateLimitedRetryBackOff()
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;
- Specified by:
getRateLimitedRetryBackOff
in interfaceRetryPolicyOrBuilder
- Returns:
- The rateLimitedRetryBackOff.
-
getRateLimitedRetryBackOffOrBuilder
public RetryPolicy.RateLimitedRetryBackOffOrBuilder getRateLimitedRetryBackOffOrBuilder()
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;
- Specified by:
getRateLimitedRetryBackOffOrBuilder
in interfaceRetryPolicyOrBuilder
-
getRetriableHeadersList
public java.util.List<HeaderMatcher> getRetriableHeadersList()
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;
- Specified by:
getRetriableHeadersList
in interfaceRetryPolicyOrBuilder
-
getRetriableHeadersOrBuilderList
public java.util.List<? extends HeaderMatcherOrBuilder> getRetriableHeadersOrBuilderList()
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;
- Specified by:
getRetriableHeadersOrBuilderList
in interfaceRetryPolicyOrBuilder
-
getRetriableHeadersCount
public int getRetriableHeadersCount()
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;
- Specified by:
getRetriableHeadersCount
in interfaceRetryPolicyOrBuilder
-
getRetriableHeaders
public HeaderMatcher getRetriableHeaders(int 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;
- Specified by:
getRetriableHeaders
in interfaceRetryPolicyOrBuilder
-
getRetriableHeadersOrBuilder
public HeaderMatcherOrBuilder getRetriableHeadersOrBuilder(int 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;
- Specified by:
getRetriableHeadersOrBuilder
in interfaceRetryPolicyOrBuilder
-
getRetriableRequestHeadersList
public java.util.List<HeaderMatcher> getRetriableRequestHeadersList()
HTTP headers which must be present in the request for retries to be attempted.
repeated .envoy.config.route.v3.HeaderMatcher retriable_request_headers = 10;
- Specified by:
getRetriableRequestHeadersList
in interfaceRetryPolicyOrBuilder
-
getRetriableRequestHeadersOrBuilderList
public java.util.List<? extends HeaderMatcherOrBuilder> getRetriableRequestHeadersOrBuilderList()
HTTP headers which must be present in the request for retries to be attempted.
repeated .envoy.config.route.v3.HeaderMatcher retriable_request_headers = 10;
- Specified by:
getRetriableRequestHeadersOrBuilderList
in interfaceRetryPolicyOrBuilder
-
getRetriableRequestHeadersCount
public int getRetriableRequestHeadersCount()
HTTP headers which must be present in the request for retries to be attempted.
repeated .envoy.config.route.v3.HeaderMatcher retriable_request_headers = 10;
- Specified by:
getRetriableRequestHeadersCount
in interfaceRetryPolicyOrBuilder
-
getRetriableRequestHeaders
public HeaderMatcher getRetriableRequestHeaders(int 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;
- Specified by:
getRetriableRequestHeaders
in interfaceRetryPolicyOrBuilder
-
getRetriableRequestHeadersOrBuilder
public HeaderMatcherOrBuilder getRetriableRequestHeadersOrBuilder(int 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;
- Specified by:
getRetriableRequestHeadersOrBuilder
in interfaceRetryPolicyOrBuilder
-
isInitialized
public final boolean isInitialized()
- Specified by:
isInitialized
in interfacecom.google.protobuf.MessageLiteOrBuilder
- Overrides:
isInitialized
in classcom.google.protobuf.GeneratedMessage
-
writeTo
public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException
- Specified by:
writeTo
in interfacecom.google.protobuf.MessageLite
- Overrides:
writeTo
in classcom.google.protobuf.GeneratedMessage
- Throws:
java.io.IOException
-
getSerializedSize
public int getSerializedSize()
- Specified by:
getSerializedSize
in interfacecom.google.protobuf.MessageLite
- Overrides:
getSerializedSize
in classcom.google.protobuf.GeneratedMessage
-
equals
public boolean equals(java.lang.Object obj)
- Specified by:
equals
in interfacecom.google.protobuf.Message
- Overrides:
equals
in classcom.google.protobuf.AbstractMessage
-
hashCode
public int hashCode()
- Specified by:
hashCode
in interfacecom.google.protobuf.Message
- Overrides:
hashCode
in classcom.google.protobuf.AbstractMessage
-
parseFrom
public static RetryPolicy parseFrom(java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException
- Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static RetryPolicy parseFrom(java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
- Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static RetryPolicy parseFrom(com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException
- Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static RetryPolicy parseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
- Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static RetryPolicy parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException
- Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static RetryPolicy parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
- Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static RetryPolicy parseFrom(java.io.InputStream input) throws java.io.IOException
- Throws:
java.io.IOException
-
parseFrom
public static RetryPolicy parseFrom(java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException
- Throws:
java.io.IOException
-
parseDelimitedFrom
public static RetryPolicy parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException
- Throws:
java.io.IOException
-
parseDelimitedFrom
public static RetryPolicy parseDelimitedFrom(java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException
- Throws:
java.io.IOException
-
parseFrom
public static RetryPolicy parseFrom(com.google.protobuf.CodedInputStream input) throws java.io.IOException
- Throws:
java.io.IOException
-
parseFrom
public static RetryPolicy parseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException
- Throws:
java.io.IOException
-
newBuilderForType
public RetryPolicy.Builder newBuilderForType()
- Specified by:
newBuilderForType
in interfacecom.google.protobuf.Message
- Specified by:
newBuilderForType
in interfacecom.google.protobuf.MessageLite
-
newBuilder
public static RetryPolicy.Builder newBuilder()
-
newBuilder
public static RetryPolicy.Builder newBuilder(RetryPolicy prototype)
-
toBuilder
public RetryPolicy.Builder toBuilder()
- Specified by:
toBuilder
in interfacecom.google.protobuf.Message
- Specified by:
toBuilder
in interfacecom.google.protobuf.MessageLite
-
newBuilderForType
protected RetryPolicy.Builder newBuilderForType(com.google.protobuf.AbstractMessage.BuilderParent parent)
- Overrides:
newBuilderForType
in classcom.google.protobuf.AbstractMessage
-
getDefaultInstance
public static RetryPolicy getDefaultInstance()
-
parser
public static com.google.protobuf.Parser<RetryPolicy> parser()
-
getParserForType
public com.google.protobuf.Parser<RetryPolicy> getParserForType()
- Specified by:
getParserForType
in interfacecom.google.protobuf.Message
- Specified by:
getParserForType
in interfacecom.google.protobuf.MessageLite
- Overrides:
getParserForType
in classcom.google.protobuf.GeneratedMessage
-
getDefaultInstanceForType
public RetryPolicy getDefaultInstanceForType()
- Specified by:
getDefaultInstanceForType
in interfacecom.google.protobuf.MessageLiteOrBuilder
- Specified by:
getDefaultInstanceForType
in interfacecom.google.protobuf.MessageOrBuilder
-
-