target.apidocs.com.google.api.services.pubsub.model.RetryPolicy.html Maven / Gradle / Ivy
RetryPolicy (Cloud Pub/Sub API v1-rev20240918-2.0.0)
com.google.api.services.pubsub.model
Class RetryPolicy
- java.lang.Object
-
- java.util.AbstractMap<String,Object>
-
- com.google.api.client.util.GenericData
-
- com.google.api.client.json.GenericJson
-
- com.google.api.services.pubsub.model.RetryPolicy
-
public final class RetryPolicy
extends com.google.api.client.json.GenericJson
A policy that specifies how Pub/Sub retries message delivery. Retry delay will be exponential
based on provided minimum and maximum backoffs.
https://en.wikipedia.org/wiki/Exponential_backoff. RetryPolicy will be triggered on NACKs or
acknowledgement deadline exceeded events for a given message. Retry Policy is implemented on a
best effort basis. At times, the delay between consecutive deliveries may not match the
configuration. That is, delay can be more or less than configured backoff.
This is the Java data model class that specifies how to parse/serialize into the JSON that is
transmitted over HTTP when working with the Cloud Pub/Sub API. For a detailed explanation see:
https://developers.google.com/api-client-library/java/google-http-java-client/json
- Author:
- Google, Inc.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class com.google.api.client.util.GenericData
com.google.api.client.util.GenericData.Flags
-
Nested classes/interfaces inherited from class java.util.AbstractMap
AbstractMap.SimpleEntry<K,V>, AbstractMap.SimpleImmutableEntry<K,V>
-
Constructor Summary
Constructors
Constructor and Description
RetryPolicy()
-
Method Summary
All Methods Instance Methods Concrete Methods
Modifier and Type
Method and Description
RetryPolicy
clone()
String
getMaximumBackoff()
Optional.
String
getMinimumBackoff()
Optional.
RetryPolicy
set(String fieldName,
Object value)
RetryPolicy
setMaximumBackoff(String maximumBackoff)
Optional.
RetryPolicy
setMinimumBackoff(String minimumBackoff)
Optional.
-
Methods inherited from class com.google.api.client.json.GenericJson
getFactory, setFactory, toPrettyString, toString
-
Methods inherited from class com.google.api.client.util.GenericData
entrySet, equals, get, getClassInfo, getUnknownKeys, hashCode, put, putAll, remove, setUnknownKeys
-
Methods inherited from class java.util.AbstractMap
clear, containsKey, containsValue, isEmpty, keySet, size, values
-
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface java.util.Map
compute, computeIfAbsent, computeIfPresent, forEach, getOrDefault, merge, putIfAbsent, remove, replace, replace, replaceAll
-
-
Method Detail
-
getMaximumBackoff
public String getMaximumBackoff()
Optional. The maximum delay between consecutive deliveries of a given message. Value should be
between 0 and 600 seconds. Defaults to 600 seconds.
- Returns:
- value or
null
for none
-
setMaximumBackoff
public RetryPolicy setMaximumBackoff(String maximumBackoff)
Optional. The maximum delay between consecutive deliveries of a given message. Value should be
between 0 and 600 seconds. Defaults to 600 seconds.
- Parameters:
maximumBackoff
- maximumBackoff or null
for none
-
getMinimumBackoff
public String getMinimumBackoff()
Optional. The minimum delay between consecutive deliveries of a given message. Value should be
between 0 and 600 seconds. Defaults to 10 seconds.
- Returns:
- value or
null
for none
-
setMinimumBackoff
public RetryPolicy setMinimumBackoff(String minimumBackoff)
Optional. The minimum delay between consecutive deliveries of a given message. Value should be
between 0 and 600 seconds. Defaults to 10 seconds.
- Parameters:
minimumBackoff
- minimumBackoff or null
for none
-
set
public RetryPolicy set(String fieldName,
Object value)
- Overrides:
set
in class com.google.api.client.json.GenericJson
-
clone
public RetryPolicy clone()
- Overrides:
clone
in class com.google.api.client.json.GenericJson
Copyright © 2011–2024 Google. All rights reserved.