public static final class MethodConfig.HedgingPolicy extends com.google.protobuf.GeneratedMessageV3 implements MethodConfig.HedgingPolicyOrBuilder
The hedging policy for outgoing RPCs. Hedged RPCs may execute more than once on the server, so only idempotent methods should specify a hedging policy.Protobuf type
grpc.service_config.MethodConfig.HedgingPolicy| Modifier and Type | Class and Description |
|---|---|
static class |
MethodConfig.HedgingPolicy.Builder
The hedging policy for outgoing RPCs.
|
com.google.protobuf.GeneratedMessageV3.BuilderParent, com.google.protobuf.GeneratedMessageV3.ExtendableBuilder<MessageType extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage,BuilderType extends com.google.protobuf.GeneratedMessageV3.ExtendableBuilder<MessageType,BuilderType>>, com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageType extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage>, com.google.protobuf.GeneratedMessageV3.ExtendableMessageOrBuilder<MessageType extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage>, com.google.protobuf.GeneratedMessageV3.FieldAccessorTable, com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter| Modifier and Type | Field and Description |
|---|---|
static int |
HEDGING_DELAY_FIELD_NUMBER |
static int |
MAX_ATTEMPTS_FIELD_NUMBER |
static int |
NON_FATAL_STATUS_CODES_FIELD_NUMBER |
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(Object obj) |
static MethodConfig.HedgingPolicy |
getDefaultInstance() |
MethodConfig.HedgingPolicy |
getDefaultInstanceForType() |
static com.google.protobuf.Descriptors.Descriptor |
getDescriptor() |
com.google.protobuf.Duration |
getHedgingDelay()
The first RPC will be sent immediately, but the max_requests-1 subsequent
hedged RPCs will be sent at intervals of every hedging_delay.
|
com.google.protobuf.DurationOrBuilder |
getHedgingDelayOrBuilder()
The first RPC will be sent immediately, but the max_requests-1 subsequent
hedged RPCs will be sent at intervals of every hedging_delay.
|
int |
getMaxAttempts()
The hedging policy will send up to max_requests RPCs.
|
com.google.rpc.Code |
getNonFatalStatusCodes(int index)
The set of status codes which indicate other hedged RPCs may still
succeed.
|
int |
getNonFatalStatusCodesCount()
The set of status codes which indicate other hedged RPCs may still
succeed.
|
List<com.google.rpc.Code> |
getNonFatalStatusCodesList()
The set of status codes which indicate other hedged RPCs may still
succeed.
|
int |
getNonFatalStatusCodesValue(int index)
The set of status codes which indicate other hedged RPCs may still
succeed.
|
List<Integer> |
getNonFatalStatusCodesValueList()
The set of status codes which indicate other hedged RPCs may still
succeed.
|
com.google.protobuf.Parser<MethodConfig.HedgingPolicy> |
getParserForType() |
int |
getSerializedSize() |
com.google.protobuf.UnknownFieldSet |
getUnknownFields() |
int |
hashCode() |
boolean |
hasHedgingDelay()
The first RPC will be sent immediately, but the max_requests-1 subsequent
hedged RPCs will be sent at intervals of every hedging_delay.
|
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable |
internalGetFieldAccessorTable() |
boolean |
isInitialized() |
static MethodConfig.HedgingPolicy.Builder |
newBuilder() |
static MethodConfig.HedgingPolicy.Builder |
newBuilder(MethodConfig.HedgingPolicy prototype) |
MethodConfig.HedgingPolicy.Builder |
newBuilderForType() |
protected MethodConfig.HedgingPolicy.Builder |
newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) |
protected Object |
newInstance(com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter unused) |
static MethodConfig.HedgingPolicy |
parseDelimitedFrom(InputStream input) |
static MethodConfig.HedgingPolicy |
parseDelimitedFrom(InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static MethodConfig.HedgingPolicy |
parseFrom(byte[] data) |
static MethodConfig.HedgingPolicy |
parseFrom(byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static MethodConfig.HedgingPolicy |
parseFrom(ByteBuffer data) |
static MethodConfig.HedgingPolicy |
parseFrom(ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static MethodConfig.HedgingPolicy |
parseFrom(com.google.protobuf.ByteString data) |
static MethodConfig.HedgingPolicy |
parseFrom(com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static MethodConfig.HedgingPolicy |
parseFrom(com.google.protobuf.CodedInputStream input) |
static MethodConfig.HedgingPolicy |
parseFrom(com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static MethodConfig.HedgingPolicy |
parseFrom(InputStream input) |
static MethodConfig.HedgingPolicy |
parseFrom(InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static com.google.protobuf.Parser<MethodConfig.HedgingPolicy> |
parser() |
MethodConfig.HedgingPolicy.Builder |
toBuilder() |
void |
writeTo(com.google.protobuf.CodedOutputStream output) |
canUseUnsafe, computeStringSize, computeStringSizeNoTag, emptyBooleanList, emptyDoubleList, emptyFloatList, emptyIntList, emptyLongList, getAllFields, getDescriptorForType, getField, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, hasField, hasOneof, internalGetMapField, isStringEmpty, makeExtensionsImmutable, mergeFromAndMakeImmutableInternal, mutableCopy, mutableCopy, mutableCopy, mutableCopy, mutableCopy, newBooleanList, newBuilderForType, newDoubleList, newFloatList, newIntList, newLongList, parseDelimitedWithIOException, parseDelimitedWithIOException, parseUnknownField, parseUnknownFieldProto3, parseWithIOException, parseWithIOException, parseWithIOException, parseWithIOException, serializeBooleanMapTo, serializeIntegerMapTo, serializeLongMapTo, serializeStringMapTo, writeReplace, writeString, writeStringNoTagfindInitializationErrors, getInitializationErrorString, hashBoolean, hashEnum, hashEnumList, hashFields, hashLong, toStringaddAll, addAll, checkByteStringIsUtf8, toByteArray, toByteString, writeDelimitedTo, writeToclone, finalize, getClass, notify, notifyAll, wait, wait, waitpublic static final int MAX_ATTEMPTS_FIELD_NUMBER
public static final int HEDGING_DELAY_FIELD_NUMBER
public static final int NON_FATAL_STATUS_CODES_FIELD_NUMBER
protected Object newInstance(com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter unused)
newInstance in class com.google.protobuf.GeneratedMessageV3public final com.google.protobuf.UnknownFieldSet getUnknownFields()
getUnknownFields in interface com.google.protobuf.MessageOrBuildergetUnknownFields in class com.google.protobuf.GeneratedMessageV3public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessageV3public int getMaxAttempts()
The hedging policy will send up to max_requests RPCs. This number represents the total number of all attempts, including the original attempt. This field is required and must be greater than 1. Any value greater than 5 will be treated as if it were 5.
uint32 max_attempts = 1;getMaxAttempts in interface MethodConfig.HedgingPolicyOrBuilderpublic boolean hasHedgingDelay()
The first RPC will be sent immediately, but the max_requests-1 subsequent hedged RPCs will be sent at intervals of every hedging_delay. Set this to 0 to immediately send all max_requests RPCs.
.google.protobuf.Duration hedging_delay = 2;hasHedgingDelay in interface MethodConfig.HedgingPolicyOrBuilderpublic com.google.protobuf.Duration getHedgingDelay()
The first RPC will be sent immediately, but the max_requests-1 subsequent hedged RPCs will be sent at intervals of every hedging_delay. Set this to 0 to immediately send all max_requests RPCs.
.google.protobuf.Duration hedging_delay = 2;getHedgingDelay in interface MethodConfig.HedgingPolicyOrBuilderpublic com.google.protobuf.DurationOrBuilder getHedgingDelayOrBuilder()
The first RPC will be sent immediately, but the max_requests-1 subsequent hedged RPCs will be sent at intervals of every hedging_delay. Set this to 0 to immediately send all max_requests RPCs.
.google.protobuf.Duration hedging_delay = 2;getHedgingDelayOrBuilder in interface MethodConfig.HedgingPolicyOrBuilderpublic List<com.google.rpc.Code> getNonFatalStatusCodesList()
The set of status codes which indicate other hedged RPCs may still succeed. If a non-fatal status code is returned by the server, hedged RPCs will continue. Otherwise, outstanding requests will be canceled and the error returned to the client application layer. This field is optional.
repeated .google.rpc.Code non_fatal_status_codes = 3;getNonFatalStatusCodesList in interface MethodConfig.HedgingPolicyOrBuilderpublic int getNonFatalStatusCodesCount()
The set of status codes which indicate other hedged RPCs may still succeed. If a non-fatal status code is returned by the server, hedged RPCs will continue. Otherwise, outstanding requests will be canceled and the error returned to the client application layer. This field is optional.
repeated .google.rpc.Code non_fatal_status_codes = 3;getNonFatalStatusCodesCount in interface MethodConfig.HedgingPolicyOrBuilderpublic com.google.rpc.Code getNonFatalStatusCodes(int index)
The set of status codes which indicate other hedged RPCs may still succeed. If a non-fatal status code is returned by the server, hedged RPCs will continue. Otherwise, outstanding requests will be canceled and the error returned to the client application layer. This field is optional.
repeated .google.rpc.Code non_fatal_status_codes = 3;getNonFatalStatusCodes in interface MethodConfig.HedgingPolicyOrBuilderindex - The index of the element to return.public List<Integer> getNonFatalStatusCodesValueList()
The set of status codes which indicate other hedged RPCs may still succeed. If a non-fatal status code is returned by the server, hedged RPCs will continue. Otherwise, outstanding requests will be canceled and the error returned to the client application layer. This field is optional.
repeated .google.rpc.Code non_fatal_status_codes = 3;getNonFatalStatusCodesValueList in interface MethodConfig.HedgingPolicyOrBuilderpublic int getNonFatalStatusCodesValue(int index)
The set of status codes which indicate other hedged RPCs may still succeed. If a non-fatal status code is returned by the server, hedged RPCs will continue. Otherwise, outstanding requests will be canceled and the error returned to the client application layer. This field is optional.
repeated .google.rpc.Code non_fatal_status_codes = 3;getNonFatalStatusCodesValue in interface MethodConfig.HedgingPolicyOrBuilderindex - The index of the value to return.public final boolean isInitialized()
isInitialized in interface com.google.protobuf.MessageLiteOrBuilderisInitialized in class com.google.protobuf.GeneratedMessageV3public void writeTo(com.google.protobuf.CodedOutputStream output)
throws IOException
writeTo in interface com.google.protobuf.MessageLitewriteTo in class com.google.protobuf.GeneratedMessageV3IOExceptionpublic int getSerializedSize()
getSerializedSize in interface com.google.protobuf.MessageLitegetSerializedSize in class com.google.protobuf.GeneratedMessageV3public boolean equals(Object obj)
equals in interface com.google.protobuf.Messageequals in class com.google.protobuf.AbstractMessagepublic int hashCode()
hashCode in interface com.google.protobuf.MessagehashCode in class com.google.protobuf.AbstractMessagepublic static MethodConfig.HedgingPolicy parseFrom(ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static MethodConfig.HedgingPolicy parseFrom(ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static MethodConfig.HedgingPolicy parseFrom(com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static MethodConfig.HedgingPolicy parseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static MethodConfig.HedgingPolicy parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static MethodConfig.HedgingPolicy parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static MethodConfig.HedgingPolicy parseFrom(InputStream input) throws IOException
IOExceptionpublic static MethodConfig.HedgingPolicy parseFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
IOExceptionpublic static MethodConfig.HedgingPolicy parseDelimitedFrom(InputStream input) throws IOException
IOExceptionpublic static MethodConfig.HedgingPolicy parseDelimitedFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
IOExceptionpublic static MethodConfig.HedgingPolicy parseFrom(com.google.protobuf.CodedInputStream input) throws IOException
IOExceptionpublic static MethodConfig.HedgingPolicy parseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
IOExceptionpublic MethodConfig.HedgingPolicy.Builder newBuilderForType()
newBuilderForType in interface com.google.protobuf.MessagenewBuilderForType in interface com.google.protobuf.MessageLitepublic static MethodConfig.HedgingPolicy.Builder newBuilder()
public static MethodConfig.HedgingPolicy.Builder newBuilder(MethodConfig.HedgingPolicy prototype)
public MethodConfig.HedgingPolicy.Builder toBuilder()
toBuilder in interface com.google.protobuf.MessagetoBuilder in interface com.google.protobuf.MessageLiteprotected MethodConfig.HedgingPolicy.Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent)
newBuilderForType in class com.google.protobuf.GeneratedMessageV3public static MethodConfig.HedgingPolicy getDefaultInstance()
public static com.google.protobuf.Parser<MethodConfig.HedgingPolicy> parser()
public com.google.protobuf.Parser<MethodConfig.HedgingPolicy> getParserForType()
getParserForType in interface com.google.protobuf.MessagegetParserForType in interface com.google.protobuf.MessageLitegetParserForType in class com.google.protobuf.GeneratedMessageV3public MethodConfig.HedgingPolicy getDefaultInstanceForType()
getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuildergetDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilderCopyright © 2022 Google LLC. All rights reserved.