From 6eb5a7af48d04adc5625cbc8355e2556db4b992f Mon Sep 17 00:00:00 2001 From: Keuin Date: Fri, 7 Jul 2023 00:34:25 +0800 Subject: Refactor: move retry into single package. --- recording/task.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'recording/task.go') diff --git a/recording/task.go b/recording/task.go index 78be348..5c1f5ee 100644 --- a/recording/task.go +++ b/recording/task.go @@ -8,7 +8,7 @@ Concrete task works are done in the `runner.go` file. import ( "context" "fmt" - "github.com/keuin/slbr/common" + "github.com/keuin/slbr/common/retry" "github.com/keuin/slbr/logging" "time" ) @@ -90,7 +90,7 @@ func AutoRetryWithTask[T any]( t *RunningTask, supplier func() (T, error), ) (T, error) { - return common.AutoRetry[T]( + return retry.AutoRetry[T]( t.ctx, supplier, t.Transport.MaxRetryTimes, @@ -105,7 +105,7 @@ func AutoRetryWithConfig[T any]( t *TaskConfig, supplier func() (T, error), ) (T, error) { - return common.AutoRetry[T]( + return retry.AutoRetry[T]( ctx, supplier, t.Transport.MaxRetryTimes, -- cgit v1.2.3