Class GrpcRoute.RetryPolicy.Builder (0.15.0)

public static final class GrpcRoute.RetryPolicy.Builder extends GeneratedMessageV3.Builder<GrpcRoute.RetryPolicy.Builder> implements GrpcRoute.RetryPolicyOrBuilder

The specifications for retries.

Protobuf type google.events.cloud.networkservices.v1.GrpcRoute.RetryPolicy

Static Methods

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
TypeDescription
Descriptor

Methods

addAllRetryConditions(Iterable<String> values)

public GrpcRoute.RetryPolicy.Builder addAllRetryConditions(Iterable<String> values)
  • connect-failure: Router will retry on failures connecting to Backend Services, for example due to connection timeouts.
  • refused-stream: Router will retry if the backend service resets the stream with a REFUSED_STREAM error code. This reset type indicates that it is safe to retry.
  • cancelled: Router will retry if the gRPC status code in the response header is set to cancelled
  • deadline-exceeded: Router will retry if the gRPC status code in the response header is set to deadline-exceeded
  • resource-exhausted: Router will retry if the gRPC status code in the response header is set to resource-exhausted
  • unavailable: Router will retry if the gRPC status code in the response header is set to unavailable

repeated string retry_conditions = 1;

Parameter
NameDescription
valuesIterable<String>

The retryConditions to add.

Returns
TypeDescription
GrpcRoute.RetryPolicy.Builder

This builder for chaining.

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

public GrpcRoute.RetryPolicy.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
NameDescription
fieldFieldDescriptor
valueObject
Returns
TypeDescription
GrpcRoute.RetryPolicy.Builder
Overrides

addRetryConditions(String value)

public GrpcRoute.RetryPolicy.Builder addRetryConditions(String value)
  • connect-failure: Router will retry on failures connecting to Backend Services, for example due to connection timeouts.
  • refused-stream: Router will retry if the backend service resets the stream with a REFUSED_STREAM error code. This reset type indicates that it is safe to retry.
  • cancelled: Router will retry if the gRPC status code in the response header is set to cancelled
  • deadline-exceeded: Router will retry if the gRPC status code in the response header is set to deadline-exceeded
  • resource-exhausted: Router will retry if the gRPC status code in the response header is set to resource-exhausted
  • unavailable: Router will retry if the gRPC status code in the response header is set to unavailable

repeated string retry_conditions = 1;

Parameter
NameDescription
valueString

The retryConditions to add.

Returns
TypeDescription
GrpcRoute.RetryPolicy.Builder

This builder for chaining.

addRetryConditionsBytes(ByteString value)

public GrpcRoute.RetryPolicy.Builder addRetryConditionsBytes(ByteString value)
  • connect-failure: Router will retry on failures connecting to Backend Services, for example due to connection timeouts.
  • refused-stream: Router will retry if the backend service resets the stream with a REFUSED_STREAM error code. This reset type indicates that it is safe to retry.
  • cancelled: Router will retry if the gRPC status code in the response header is set to cancelled
  • deadline-exceeded: Router will retry if the gRPC status code in the response header is set to deadline-exceeded
  • resource-exhausted: Router will retry if the gRPC status code in the response header is set to resource-exhausted
  • unavailable: Router will retry if the gRPC status code in the response header is set to unavailable

repeated string retry_conditions = 1;

Parameter
NameDescription
valueByteString

The bytes of the retryConditions to add.

Returns
TypeDescription
GrpcRoute.RetryPolicy.Builder

This builder for chaining.

build()

public GrpcRoute.RetryPolicy build()
Returns
TypeDescription
GrpcRoute.RetryPolicy

buildPartial()

public GrpcRoute.RetryPolicy buildPartial()
Returns
TypeDescription
GrpcRoute.RetryPolicy

clear()

public GrpcRoute.RetryPolicy.Builder clear()
Returns
TypeDescription
GrpcRoute.RetryPolicy.Builder
Overrides

clearField(Descriptors.FieldDescriptor field)

public GrpcRoute.RetryPolicy.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
NameDescription
fieldFieldDescriptor
Returns
TypeDescription
GrpcRoute.RetryPolicy.Builder
Overrides

clearNumRetries()

public GrpcRoute.RetryPolicy.Builder clearNumRetries()

Specifies the allowed number of retries. This number must be > 0. If not specified, default to 1.

uint32 num_retries = 2;

Returns
TypeDescription
GrpcRoute.RetryPolicy.Builder

This builder for chaining.

clearOneof(Descriptors.OneofDescriptor oneof)

public GrpcRoute.RetryPolicy.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
NameDescription
oneofOneofDescriptor
Returns
TypeDescription
GrpcRoute.RetryPolicy.Builder
Overrides

clearRetryConditions()

public GrpcRoute.RetryPolicy.Builder clearRetryConditions()
  • connect-failure: Router will retry on failures connecting to Backend Services, for example due to connection timeouts.
  • refused-stream: Router will retry if the backend service resets the stream with a REFUSED_STREAM error code. This reset type indicates that it is safe to retry.
  • cancelled: Router will retry if the gRPC status code in the response header is set to cancelled
  • deadline-exceeded: Router will retry if the gRPC status code in the response header is set to deadline-exceeded
  • resource-exhausted: Router will retry if the gRPC status code in the response header is set to resource-exhausted
  • unavailable: Router will retry if the gRPC status code in the response header is set to unavailable

repeated string retry_conditions = 1;

Returns
TypeDescription
GrpcRoute.RetryPolicy.Builder

This builder for chaining.

clone()

public GrpcRoute.RetryPolicy.Builder clone()
Returns
TypeDescription
GrpcRoute.RetryPolicy.Builder
Overrides

getDefaultInstanceForType()

public GrpcRoute.RetryPolicy getDefaultInstanceForType()
Returns
TypeDescription
GrpcRoute.RetryPolicy

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
TypeDescription
Descriptor
Overrides

getNumRetries()

public int getNumRetries()

Specifies the allowed number of retries. This number must be > 0. If not specified, default to 1.

uint32 num_retries = 2;

Returns
TypeDescription
int

The numRetries.

getRetryConditions(int index)

public String getRetryConditions(int index)
  • connect-failure: Router will retry on failures connecting to Backend Services, for example due to connection timeouts.
  • refused-stream: Router will retry if the backend service resets the stream with a REFUSED_STREAM error code. This reset type indicates that it is safe to retry.
  • cancelled: Router will retry if the gRPC status code in the response header is set to cancelled
  • deadline-exceeded: Router will retry if the gRPC status code in the response header is set to deadline-exceeded
  • resource-exhausted: Router will retry if the gRPC status code in the response header is set to resource-exhausted
  • unavailable: Router will retry if the gRPC status code in the response header is set to unavailable

repeated string retry_conditions = 1;

Parameter
NameDescription
indexint

The index of the element to return.

Returns
TypeDescription
String

The retryConditions at the given index.

getRetryConditionsBytes(int index)

public ByteString getRetryConditionsBytes(int index)
  • connect-failure: Router will retry on failures connecting to Backend Services, for example due to connection timeouts.
  • refused-stream: Router will retry if the backend service resets the stream with a REFUSED_STREAM error code. This reset type indicates that it is safe to retry.
  • cancelled: Router will retry if the gRPC status code in the response header is set to cancelled
  • deadline-exceeded: Router will retry if the gRPC status code in the response header is set to deadline-exceeded
  • resource-exhausted: Router will retry if the gRPC status code in the response header is set to resource-exhausted
  • unavailable: Router will retry if the gRPC status code in the response header is set to unavailable

repeated string retry_conditions = 1;

Parameter
NameDescription
indexint

The index of the value to return.

Returns
TypeDescription
ByteString

The bytes of the retryConditions at the given index.

getRetryConditionsCount()

public int getRetryConditionsCount()
  • connect-failure: Router will retry on failures connecting to Backend Services, for example due to connection timeouts.
  • refused-stream: Router will retry if the backend service resets the stream with a REFUSED_STREAM error code. This reset type indicates that it is safe to retry.
  • cancelled: Router will retry if the gRPC status code in the response header is set to cancelled
  • deadline-exceeded: Router will retry if the gRPC status code in the response header is set to deadline-exceeded
  • resource-exhausted: Router will retry if the gRPC status code in the response header is set to resource-exhausted
  • unavailable: Router will retry if the gRPC status code in the response header is set to unavailable

repeated string retry_conditions = 1;

Returns
TypeDescription
int

The count of retryConditions.

getRetryConditionsList()

public ProtocolStringList getRetryConditionsList()
  • connect-failure: Router will retry on failures connecting to Backend Services, for example due to connection timeouts.
  • refused-stream: Router will retry if the backend service resets the stream with a REFUSED_STREAM error code. This reset type indicates that it is safe to retry.
  • cancelled: Router will retry if the gRPC status code in the response header is set to cancelled
  • deadline-exceeded: Router will retry if the gRPC status code in the response header is set to deadline-exceeded
  • resource-exhausted: Router will retry if the gRPC status code in the response header is set to resource-exhausted
  • unavailable: Router will retry if the gRPC status code in the response header is set to unavailable

repeated string retry_conditions = 1;

Returns
TypeDescription
ProtocolStringList

A list containing the retryConditions.

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
TypeDescription
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
TypeDescription
boolean
Overrides

mergeFrom(GrpcRoute.RetryPolicy other)

public GrpcRoute.RetryPolicy.Builder mergeFrom(GrpcRoute.RetryPolicy other)
Parameter
NameDescription
otherGrpcRoute.RetryPolicy
Returns
TypeDescription
GrpcRoute.RetryPolicy.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public GrpcRoute.RetryPolicy.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputCodedInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
GrpcRoute.RetryPolicy.Builder
Overrides
Exceptions
TypeDescription
IOException

mergeFrom(Message other)

public GrpcRoute.RetryPolicy.Builder mergeFrom(Message other)
Parameter
NameDescription
otherMessage
Returns
TypeDescription
GrpcRoute.RetryPolicy.Builder
Overrides

mergeUnknownFields(UnknownFieldSet unknownFields)

public final GrpcRoute.RetryPolicy.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
NameDescription
unknownFieldsUnknownFieldSet
Returns
TypeDescription
GrpcRoute.RetryPolicy.Builder
Overrides

setField(Descriptors.FieldDescriptor field, Object value)

public GrpcRoute.RetryPolicy.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
NameDescription
fieldFieldDescriptor
valueObject
Returns
TypeDescription
GrpcRoute.RetryPolicy.Builder
Overrides

setNumRetries(int value)

public GrpcRoute.RetryPolicy.Builder setNumRetries(int value)

Specifies the allowed number of retries. This number must be > 0. If not specified, default to 1.

uint32 num_retries = 2;

Parameter
NameDescription
valueint

The numRetries to set.

Returns
TypeDescription
GrpcRoute.RetryPolicy.Builder

This builder for chaining.

setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)

public GrpcRoute.RetryPolicy.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
NameDescription
fieldFieldDescriptor
indexint
valueObject
Returns
TypeDescription
GrpcRoute.RetryPolicy.Builder
Overrides

setRetryConditions(int index, String value)

public GrpcRoute.RetryPolicy.Builder setRetryConditions(int index, String value)
  • connect-failure: Router will retry on failures connecting to Backend Services, for example due to connection timeouts.
  • refused-stream: Router will retry if the backend service resets the stream with a REFUSED_STREAM error code. This reset type indicates that it is safe to retry.
  • cancelled: Router will retry if the gRPC status code in the response header is set to cancelled
  • deadline-exceeded: Router will retry if the gRPC status code in the response header is set to deadline-exceeded
  • resource-exhausted: Router will retry if the gRPC status code in the response header is set to resource-exhausted
  • unavailable: Router will retry if the gRPC status code in the response header is set to unavailable

repeated string retry_conditions = 1;

Parameters
NameDescription
indexint

The index to set the value at.

valueString

The retryConditions to set.

Returns
TypeDescription
GrpcRoute.RetryPolicy.Builder

This builder for chaining.

setUnknownFields(UnknownFieldSet unknownFields)

public final GrpcRoute.RetryPolicy.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
NameDescription
unknownFieldsUnknownFieldSet
Returns
TypeDescription
GrpcRoute.RetryPolicy.Builder
Overrides