Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: cockroachdb/cockroach-go
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: v2.4.2
Choose a base ref
...
head repository: cockroachdb/cockroach-go
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: v2.4.3
Choose a head ref
  • 2 commits
  • 8 files changed
  • 4 contributors

Commits on Dec 4, 2025

  1. Add flexible retry backoff policies with configurable delays(#182)

    Introduce a new retry policy system that allows configurable backoff strategies
    for transaction retries. Add RetryPolicy interface and RetryFunc type to
    support pluggable retry strategies with customizable delays between attempts.
    
    Implement LimitBackoffRetryPolicy for fixed-delay retries and
    ExpBackoffRetryPolicy for exponential backoff with optional maximum delay caps.
    Add ExternalBackoffPolicy to integrate third-party backoff libraries (e.g.,
    github.com/sethvargo/go-retry) without creating direct dependencies.
    
    Define UnlimitedRetries (0) and NoRetries (-1) sentinel constants for clearer
    retry limit semantics. Both retry policies consistently handle RetryLimit:
    positive values limit retries, 0 enables unlimited retries, and negative values
    disable retries entirely.
    
    Add context-based retry policy configuration via WithRetryPolicy,
    WithMaxRetries, and WithNoRetries. Optimize transaction retry implementation to
    avoid unnecessary SAVEPOINTs when using backoff policies.
    ---------
    
    Co-authored-by: Matt Whelan <[email protected]>
    Co-authored-by: Silvano Ravotto <[email protected]>
    3 people authored Dec 4, 2025
    Configuration menu
    Copy the full SHA
    319b7f9 View commit details
    Browse the repository at this point in the history
  2. Add README for crdb retry wrapper

    Include basic usage instructions and information about allowed options.
    rafiss committed Dec 4, 2025
    Configuration menu
    Copy the full SHA
    87b1387 View commit details
    Browse the repository at this point in the history
Loading