diff --git a/pkg/icingadb/driver.go b/pkg/icingadb/driver.go index ac5af7e1d..abb6ed713 100644 --- a/pkg/icingadb/driver.go +++ b/pkg/icingadb/driver.go @@ -52,7 +52,7 @@ func (c RetryConnector) Connect(ctx context.Context) (driver.Conn, error) { return }, - shouldRetry, + retry.Retryable, backoff.NewExponentialWithJitter(time.Millisecond*128, time.Minute*1), retry.Settings{ Timeout: retry.DefaultTimeout, @@ -88,11 +88,3 @@ type MysqlFuncLogger func(v ...interface{}) func (log MysqlFuncLogger) Print(v ...interface{}) { log(v) } - -func shouldRetry(err error) bool { - if errors.Is(err, driver.ErrBadConn) { - return true - } - - return retry.Retryable(err) -}