RetryPolicy
Defines a retry strategy for failed message sends.
Use with MessageHandle to implement structured retry behavior:
val policy = RetryPolicy.ExponentialBackoff()
val handle = client.sendText("hello")
handle.retryWith(policy) // suspends until success, non-retryable failure, or max attempts exhaustedContent copied to clipboard
Inheritors
Types
Link copied to clipboard
data class ExponentialBackoff(val maxAttempts: Int = 5, val initialDelay: Duration = 2.seconds, val maxDelay: Duration = 60.seconds, val multiplier: Double = 2.0, val jitterFactor: Double = 0.2) : RetryPolicy
Retry with exponential backoff and optional jitter.
Link copied to clipboard
Retry with fixed delay between attempts.
Link copied to clipboard
No retries — fail immediately on first failure.