Skip to content

Commit

Permalink
[#25] - Retrier now sleeps correctly given the user provided time.Dur…
Browse files Browse the repository at this point in the history
…ation
  • Loading branch information
J7mbo committed Apr 20, 2019
1 parent 77ca82c commit 19676bb
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion MethodCallRetrier.go
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,7 @@ func objectIsAPointer(object interface{}) bool {

/* sleepAndIncrementRetries sleeps for the given wait time and increments the retry count by 1. */
func (r *MethodCallRetrier) sleepAndIncrementRetries() {
time.Sleep(calculateJitter(time.Duration(r.waitTime) * time.Second))
time.Sleep(calculateJitter(r.waitTime))

r.waitTime = time.Duration(int64(r.waitTime) * r.exponent)

Expand Down

0 comments on commit 19676bb

Please sign in to comment.