diff --git a/gax/src/main/java/com/google/api/gax/retrying/RetryAlgorithm.java b/gax/src/main/java/com/google/api/gax/retrying/RetryAlgorithm.java index 057148752..d06c46039 100644 --- a/gax/src/main/java/com/google/api/gax/retrying/RetryAlgorithm.java +++ b/gax/src/main/java/com/google/api/gax/retrying/RetryAlgorithm.java @@ -31,6 +31,7 @@ import static com.google.common.base.Preconditions.checkNotNull; +import com.google.api.core.BetaApi; import java.util.concurrent.CancellationException; /** @@ -114,4 +115,14 @@ public boolean shouldRetry( && nextAttemptSettings != null && timedAlgorithm.shouldRetry(nextAttemptSettings); } + + @BetaApi("Surface for inspecting the a RetryAlgorithm is not yet stable") + public ResultRetryAlgorithm getResultAlgorithm() { + return resultAlgorithm; + } + + @BetaApi("Surface for inspecting the a RetryAlgorithm is not yet stable") + public TimedRetryAlgorithm getTimedAlgorithm() { + return timedAlgorithm; + } }