Class TaskRetryPolicy.Builder (0.16.1)

public static final class TaskRetryPolicy.Builder extends GeneratedMessageV3.Builder<TaskRetryPolicy.Builder> implements TaskRetryPolicyOrBuilder

Task Retry Policy is implemented on a best-effort basis. Retry delay will be exponential based on provided minimum and maximum backoffs. https://en.wikipedia.org/wiki/Exponential_backoff. Note that the delay between consecutive task restarts may not always precisely match the configured settings. This can happen when the ConnectCluster is in rebalancing state or if the ConnectCluster is unresponsive etc.

Protobuf type google.cloud.managedkafka.v1.TaskRetryPolicy

Static Methods

getDescriptor()

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

Methods

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

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

build()

public TaskRetryPolicy build()
Returns
Type Description
TaskRetryPolicy

buildPartial()

public TaskRetryPolicy buildPartial()
Returns
Type Description
TaskRetryPolicy

clear()

public TaskRetryPolicy.Builder clear()
Returns
Type Description
TaskRetryPolicy.Builder
Overrides

clearField(Descriptors.FieldDescriptor field)

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

clearMaximumBackoff()

public TaskRetryPolicy.Builder clearMaximumBackoff()

Optional. The maximum amount of time to wait before retrying a failed task. This sets an upper bound for the backoff delay.

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

Returns
Type Description
TaskRetryPolicy.Builder

clearMinimumBackoff()

public TaskRetryPolicy.Builder clearMinimumBackoff()

Optional. The minimum amount of time to wait before retrying a failed task. This sets a lower bound for the backoff delay.

.google.protobuf.Duration minimum_backoff = 1 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
TaskRetryPolicy.Builder

clearOneof(Descriptors.OneofDescriptor oneof)

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

clone()

public TaskRetryPolicy.Builder clone()
Returns
Type Description
TaskRetryPolicy.Builder
Overrides

getDefaultInstanceForType()

public TaskRetryPolicy getDefaultInstanceForType()
Returns
Type Description
TaskRetryPolicy

getDescriptorForType()

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

getMaximumBackoff()

public Duration getMaximumBackoff()

Optional. The maximum amount of time to wait before retrying a failed task. This sets an upper bound for the backoff delay.

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

Returns
Type Description
Duration

The maximumBackoff.

getMaximumBackoffBuilder()

public Duration.Builder getMaximumBackoffBuilder()

Optional. The maximum amount of time to wait before retrying a failed task. This sets an upper bound for the backoff delay.

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

Returns
Type Description
Builder

getMaximumBackoffOrBuilder()

public DurationOrBuilder getMaximumBackoffOrBuilder()

Optional. The maximum amount of time to wait before retrying a failed task. This sets an upper bound for the backoff delay.

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

Returns
Type Description
DurationOrBuilder

getMinimumBackoff()

public Duration getMinimumBackoff()

Optional. The minimum amount of time to wait before retrying a failed task. This sets a lower bound for the backoff delay.

.google.protobuf.Duration minimum_backoff = 1 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
Duration

The minimumBackoff.

getMinimumBackoffBuilder()

public Duration.Builder getMinimumBackoffBuilder()

Optional. The minimum amount of time to wait before retrying a failed task. This sets a lower bound for the backoff delay.

.google.protobuf.Duration minimum_backoff = 1 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
Builder

getMinimumBackoffOrBuilder()

public DurationOrBuilder getMinimumBackoffOrBuilder()

Optional. The minimum amount of time to wait before retrying a failed task. This sets a lower bound for the backoff delay.

.google.protobuf.Duration minimum_backoff = 1 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
DurationOrBuilder

hasMaximumBackoff()

public boolean hasMaximumBackoff()

Optional. The maximum amount of time to wait before retrying a failed task. This sets an upper bound for the backoff delay.

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

Returns
Type Description
boolean

Whether the maximumBackoff field is set.

hasMinimumBackoff()

public boolean hasMinimumBackoff()

Optional. The minimum amount of time to wait before retrying a failed task. This sets a lower bound for the backoff delay.

.google.protobuf.Duration minimum_backoff = 1 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
boolean

Whether the minimumBackoff field is set.

internalGetFieldAccessorTable()

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

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

mergeFrom(TaskRetryPolicy other)

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

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

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

mergeFrom(Message other)

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

mergeMaximumBackoff(Duration value)

public TaskRetryPolicy.Builder mergeMaximumBackoff(Duration value)

Optional. The maximum amount of time to wait before retrying a failed task. This sets an upper bound for the backoff delay.

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

Parameter
Name Description
value Duration
Returns
Type Description
TaskRetryPolicy.Builder

mergeMinimumBackoff(Duration value)

public TaskRetryPolicy.Builder mergeMinimumBackoff(Duration value)

Optional. The minimum amount of time to wait before retrying a failed task. This sets a lower bound for the backoff delay.

.google.protobuf.Duration minimum_backoff = 1 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value Duration
Returns
Type Description
TaskRetryPolicy.Builder

mergeUnknownFields(UnknownFieldSet unknownFields)

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

setField(Descriptors.FieldDescriptor field, Object value)

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

setMaximumBackoff(Duration value)

public TaskRetryPolicy.Builder setMaximumBackoff(Duration value)

Optional. The maximum amount of time to wait before retrying a failed task. This sets an upper bound for the backoff delay.

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

Parameter
Name Description
value Duration
Returns
Type Description
TaskRetryPolicy.Builder

setMaximumBackoff(Duration.Builder builderForValue)

public TaskRetryPolicy.Builder setMaximumBackoff(Duration.Builder builderForValue)

Optional. The maximum amount of time to wait before retrying a failed task. This sets an upper bound for the backoff delay.

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

Parameter
Name Description
builderForValue Builder
Returns
Type Description
TaskRetryPolicy.Builder

setMinimumBackoff(Duration value)

public TaskRetryPolicy.Builder setMinimumBackoff(Duration value)

Optional. The minimum amount of time to wait before retrying a failed task. This sets a lower bound for the backoff delay.

.google.protobuf.Duration minimum_backoff = 1 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value Duration
Returns
Type Description
TaskRetryPolicy.Builder

setMinimumBackoff(Duration.Builder builderForValue)

public TaskRetryPolicy.Builder setMinimumBackoff(Duration.Builder builderForValue)

Optional. The minimum amount of time to wait before retrying a failed task. This sets a lower bound for the backoff delay.

.google.protobuf.Duration minimum_backoff = 1 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
builderForValue Builder
Returns
Type Description
TaskRetryPolicy.Builder

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

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

setUnknownFields(UnknownFieldSet unknownFields)

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