Skip to content

Commit

Permalink
Apply suggestions from code review
Browse files Browse the repository at this point in the history
Co-authored-by: Ben Tranter <[email protected]>
  • Loading branch information
danaelhe and bentranter authored Aug 14, 2023
1 parent b99dc7b commit c4dca37
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -157,11 +157,11 @@ func ListRepositoriesV2(ctx context.Context, client *godo.Client, registryName s

### Automatic Retries and Exponential Backoff

The Godo client can be configured to use automatic retries and exponentional backoff for requests that fail with 429 or 500-level response codes via the [go-retryablehttp](https://github.com/hashicorp/go-retryablehttp) package. To configure the Godo client to enable usage of the go-retryablehttp, the `RetryConfig.RetryMax` must be set to enable this behavior:
The Godo client can be configured to use automatic retries and exponentional backoff for requests that fail with 429 or 500-level response codes via [go-retryablehttp](https://github.com/hashicorp/go-retryablehttp). To configure Godo to enable usage of go-retryablehttp, the `RetryConfig.RetryMax` must be set.

```
```go
tokenSrc := oauth2.StaticTokenSource(&oauth2.Token{
AccessToken: "new_token",
AccessToken: "dop_v1_xxxxxx",
})

oauth_client := oauth2.NewClient(oauth2.NoContext, tokenSrc)
Expand Down

0 comments on commit c4dca37

Please sign in to comment.