Commit 9b73fa03 authored by Stan Hu's avatar Stan Hu

Merge branch 'ab/partition-creator-kwargs' into 'master'

Further remove deprecation warning around WithLockRetries usage

See merge request gitlab-org/gitlab!43108
parents ad0e25bf b2c36f31
...@@ -72,10 +72,10 @@ module Gitlab ...@@ -72,10 +72,10 @@ module Gitlab
end end
def with_lock_retries(&block) def with_lock_retries(&block)
Gitlab::Database::WithLockRetries.new(**{ Gitlab::Database::WithLockRetries.new(
klass: self.class, klass: self.class,
logger: Gitlab::AppLogger logger: Gitlab::AppLogger
}).run(&block) ).run(&block)
end end
def connection def connection
......
...@@ -99,7 +99,7 @@ module Gitlab ...@@ -99,7 +99,7 @@ module Gitlab
def with_lock_retries(&block) def with_lock_retries(&block)
arguments = { klass: self.class, logger: logger } arguments = { klass: self.class, logger: logger }
Gitlab::Database::WithLockRetries.new(arguments).run(raise_on_exhaustion: true, &block) Gitlab::Database::WithLockRetries.new(**arguments).run(raise_on_exhaustion: true, &block)
end end
delegate :execute, to: :connection delegate :execute, to: :connection
......
...@@ -68,10 +68,10 @@ module Gitlab ...@@ -68,10 +68,10 @@ module Gitlab
end end
def with_lock_retries(&block) def with_lock_retries(&block)
Gitlab::Database::WithLockRetries.new({ Gitlab::Database::WithLockRetries.new(
klass: self.class, klass: self.class,
logger: Gitlab::BackgroundMigration::Logger logger: Gitlab::BackgroundMigration::Logger
}).run(&block) ).run(&block)
end end
def assert_not_in_transaction_block(scope:) def assert_not_in_transaction_block(scope:)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment