Skip to content

Instantly share code, notes, and snippets.

@rShetty rShetty/retry.go
Created Mar 15, 2018

Embed
What would you like to do?
Retries
backoff := heimdall.NewConstantBackoff(500)
retrier := heimdall.NewRetrier(backoff)
httpClient := heimdall.NewHTTPClient(1 * time.Millisecond)
httpClient.SetRetrier(retrier)
httpClient.SetRetryCount(3)
httpClient.Get(“https://gojek.com/drivers", http.Header{})
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.