Class Pipeline.RetryPolicy.Builder (1.54.0)

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

The retry policy configuration for the Pipeline. The pipeline exponentially backs off in case the destination is non responsive or returns a retryable error code. The default semantics are as follows: The backoff starts with a 5 second delay and doubles the delay after each failed attempt (10 seconds, 20 seconds, 40 seconds, etc.). The delay is capped at 60 seconds by default. Please note that if you set the min_retry_delay and max_retry_delay fields to the same value this will make the duration between retries constant.

Protobuf type google.cloud.eventarc.v1.Pipeline.RetryPolicy

Static Methods

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
Type Description
Descriptor

Methods

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

public Pipeline.RetryPolicy.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
Name Description
field FieldDescriptor
value Object
Returns
Type Description
Pipeline.RetryPolicy.Builder
Overrides

build()

public Pipeline.RetryPolicy build()
Returns
Type Description
Pipeline.RetryPolicy

buildPartial()

public Pipeline.RetryPolicy buildPartial()
Returns
Type Description
Pipeline.RetryPolicy

clear()

public Pipeline.RetryPolicy.Builder clear()
Returns
Type Description
Pipeline.RetryPolicy.Builder
Overrides

clearField(Descriptors.FieldDescriptor field)

public Pipeline.RetryPolicy.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
Name Description
field FieldDescriptor
Returns
Type Description
Pipeline.RetryPolicy.Builder
Overrides

clearMaxAttempts()

public Pipeline.RetryPolicy.Builder clearMaxAttempts()

Optional. The maximum number of delivery attempts for any message. The value must be between 1 and 100. The default value for this field is 5.

int32 max_attempts = 1 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
Pipeline.RetryPolicy.Builder

This builder for chaining.

clearMaxRetryDelay()

public Pipeline.RetryPolicy.Builder clearMaxRetryDelay()

Optional. The maximum amount of seconds to wait between retry attempts. The value must be between 1 and 600. The default value for this field is 60.

.google.protobuf.Duration max_retry_delay = 3 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
Pipeline.RetryPolicy.Builder

clearMinRetryDelay()

public Pipeline.RetryPolicy.Builder clearMinRetryDelay()

Optional. The minimum amount of seconds to wait between retry attempts. The value must be between 1 and 600. The default value for this field is 5.

.google.protobuf.Duration min_retry_delay = 2 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
Pipeline.RetryPolicy.Builder

clearOneof(Descriptors.OneofDescriptor oneof)

public Pipeline.RetryPolicy.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
Name Description
oneof OneofDescriptor
Returns
Type Description
Pipeline.RetryPolicy.Builder
Overrides

clone()

public Pipeline.RetryPolicy.Builder clone()
Returns
Type Description
Pipeline.RetryPolicy.Builder
Overrides

getDefaultInstanceForType()

public Pipeline.RetryPolicy getDefaultInstanceForType()
Returns
Type Description
Pipeline.RetryPolicy

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
Type Description
Descriptor
Overrides

getMaxAttempts()

public int getMaxAttempts()

Optional. The maximum number of delivery attempts for any message. The value must be between 1 and 100. The default value for this field is 5.

int32 max_attempts = 1 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
int

The maxAttempts.

getMaxRetryDelay()

public Duration getMaxRetryDelay()

Optional. The maximum amount of seconds to wait between retry attempts. The value must be between 1 and 600. The default value for this field is 60.

.google.protobuf.Duration max_retry_delay = 3 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
Duration

The maxRetryDelay.

getMaxRetryDelayBuilder()

public Duration.Builder getMaxRetryDelayBuilder()

Optional. The maximum amount of seconds to wait between retry attempts. The value must be between 1 and 600. The default value for this field is 60.

.google.protobuf.Duration max_retry_delay = 3 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
Builder

getMaxRetryDelayOrBuilder()

public DurationOrBuilder getMaxRetryDelayOrBuilder()

Optional. The maximum amount of seconds to wait between retry attempts. The value must be between 1 and 600. The default value for this field is 60.

.google.protobuf.Duration max_retry_delay = 3 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
DurationOrBuilder

getMinRetryDelay()

public Duration getMinRetryDelay()

Optional. The minimum amount of seconds to wait between retry attempts. The value must be between 1 and 600. The default value for this field is 5.

.google.protobuf.Duration min_retry_delay = 2 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
Duration

The minRetryDelay.

getMinRetryDelayBuilder()

public Duration.Builder getMinRetryDelayBuilder()

Optional. The minimum amount of seconds to wait between retry attempts. The value must be between 1 and 600. The default value for this field is 5.

.google.protobuf.Duration min_retry_delay = 2 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
Builder

getMinRetryDelayOrBuilder()

public DurationOrBuilder getMinRetryDelayOrBuilder()

Optional. The minimum amount of seconds to wait between retry attempts. The value must be between 1 and 600. The default value for this field is 5.

.google.protobuf.Duration min_retry_delay = 2 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
DurationOrBuilder

hasMaxRetryDelay()

public boolean hasMaxRetryDelay()

Optional. The maximum amount of seconds to wait between retry attempts. The value must be between 1 and 600. The default value for this field is 60.

.google.protobuf.Duration max_retry_delay = 3 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
boolean

Whether the maxRetryDelay field is set.

hasMinRetryDelay()

public boolean hasMinRetryDelay()

Optional. The minimum amount of seconds to wait between retry attempts. The value must be between 1 and 600. The default value for this field is 5.

.google.protobuf.Duration min_retry_delay = 2 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
boolean

Whether the minRetryDelay field is set.

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
Type Description
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

mergeFrom(Pipeline.RetryPolicy other)

public Pipeline.RetryPolicy.Builder mergeFrom(Pipeline.RetryPolicy other)
Parameter
Name Description
other Pipeline.RetryPolicy
Returns
Type Description
Pipeline.RetryPolicy.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public Pipeline.RetryPolicy.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
input CodedInputStream
extensionRegistry ExtensionRegistryLite
Returns
Type Description
Pipeline.RetryPolicy.Builder
Overrides
Exceptions
Type Description
IOException

mergeFrom(Message other)

public Pipeline.RetryPolicy.Builder mergeFrom(Message other)
Parameter
Name Description
other Message
Returns
Type Description
Pipeline.RetryPolicy.Builder
Overrides

mergeMaxRetryDelay(Duration value)

public Pipeline.RetryPolicy.Builder mergeMaxRetryDelay(Duration value)

Optional. The maximum amount of seconds to wait between retry attempts. The value must be between 1 and 600. The default value for this field is 60.

.google.protobuf.Duration max_retry_delay = 3 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value Duration
Returns
Type Description
Pipeline.RetryPolicy.Builder

mergeMinRetryDelay(Duration value)

public Pipeline.RetryPolicy.Builder mergeMinRetryDelay(Duration value)

Optional. The minimum amount of seconds to wait between retry attempts. The value must be between 1 and 600. The default value for this field is 5.

.google.protobuf.Duration min_retry_delay = 2 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value Duration
Returns
Type Description
Pipeline.RetryPolicy.Builder

mergeUnknownFields(UnknownFieldSet unknownFields)

public final Pipeline.RetryPolicy.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
Name Description
unknownFields UnknownFieldSet
Returns
Type Description
Pipeline.RetryPolicy.Builder
Overrides

setField(Descriptors.FieldDescriptor field, Object value)

public Pipeline.RetryPolicy.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
Name Description
field FieldDescriptor
value Object
Returns
Type Description
Pipeline.RetryPolicy.Builder
Overrides

setMaxAttempts(int value)

public Pipeline.RetryPolicy.Builder setMaxAttempts(int value)

Optional. The maximum number of delivery attempts for any message. The value must be between 1 and 100. The default value for this field is 5.

int32 max_attempts = 1 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value int

The maxAttempts to set.

Returns
Type Description
Pipeline.RetryPolicy.Builder

This builder for chaining.

setMaxRetryDelay(Duration value)

public Pipeline.RetryPolicy.Builder setMaxRetryDelay(Duration value)

Optional. The maximum amount of seconds to wait between retry attempts. The value must be between 1 and 600. The default value for this field is 60.

.google.protobuf.Duration max_retry_delay = 3 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value Duration
Returns
Type Description
Pipeline.RetryPolicy.Builder

setMaxRetryDelay(Duration.Builder builderForValue)

public Pipeline.RetryPolicy.Builder setMaxRetryDelay(Duration.Builder builderForValue)

Optional. The maximum amount of seconds to wait between retry attempts. The value must be between 1 and 600. The default value for this field is 60.

.google.protobuf.Duration max_retry_delay = 3 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
builderForValue Builder
Returns
Type Description
Pipeline.RetryPolicy.Builder

setMinRetryDelay(Duration value)

public Pipeline.RetryPolicy.Builder setMinRetryDelay(Duration value)

Optional. The minimum amount of seconds to wait between retry attempts. The value must be between 1 and 600. The default value for this field is 5.

.google.protobuf.Duration min_retry_delay = 2 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value Duration
Returns
Type Description
Pipeline.RetryPolicy.Builder

setMinRetryDelay(Duration.Builder builderForValue)

public Pipeline.RetryPolicy.Builder setMinRetryDelay(Duration.Builder builderForValue)

Optional. The minimum amount of seconds to wait between retry attempts. The value must be between 1 and 600. The default value for this field is 5.

.google.protobuf.Duration min_retry_delay = 2 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
builderForValue Builder
Returns
Type Description
Pipeline.RetryPolicy.Builder

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

public Pipeline.RetryPolicy.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
Name Description
field FieldDescriptor
index int
value Object
Returns
Type Description
Pipeline.RetryPolicy.Builder
Overrides

setUnknownFields(UnknownFieldSet unknownFields)

public final Pipeline.RetryPolicy.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
Name Description
unknownFields UnknownFieldSet
Returns
Type Description
Pipeline.RetryPolicy.Builder
Overrides