debian-mirror-gitlab/lib/gitlab/database/load_balancing/active_record_proxy.rb
2021-10-27 15:23:28 +05:30

16 lines
335 B
Ruby

# frozen_string_literal: true
module Gitlab
module Database
module LoadBalancing
# Module injected into ActiveRecord::Base to allow hijacking of the
# "connection" method.
module ActiveRecordProxy
def connection
::Gitlab::Database::LoadBalancing.proxy
end
end
end
end
end