Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/lib/peek
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2021-10-20 11:43:02 +0300
committerGitLab Bot <gitlab-bot@gitlab.com>2021-10-20 11:43:02 +0300
commitd9ab72d6080f594d0b3cae15f14b3ef2c6c638cb (patch)
tree2341ef426af70ad1e289c38036737e04b0aa5007 /lib/peek
parentd6e514dd13db8947884cd58fe2a9c2a063400a9b (diff)
Add latest changes from gitlab-org/gitlab@14-4-stable-eev14.4.0-rc42
Diffstat (limited to 'lib/peek')
-rw-r--r--lib/peek/views/active_record.rb8
1 files changed, 2 insertions, 6 deletions
diff --git a/lib/peek/views/active_record.rb b/lib/peek/views/active_record.rb
index a3fe206c86f..6a41de8f0b0 100644
--- a/lib/peek/views/active_record.rb
+++ b/lib/peek/views/active_record.rb
@@ -44,10 +44,8 @@ module Peek
count[item[:transaction]] += 1
end
- if ::Gitlab::Database::LoadBalancing.enable?
- count[item[:db_role]] ||= 0
- count[item[:db_role]] += 1
- end
+ count[item[:db_role]] ||= 0
+ count[item[:db_role]] += 1
end
def setup_subscribers
@@ -72,8 +70,6 @@ module Peek
end
def db_role(data)
- return unless ::Gitlab::Database::LoadBalancing.enable?
-
role = ::Gitlab::Database::LoadBalancing.db_role_for_connection(data[:connection]) ||
::Gitlab::Database::LoadBalancing::ROLE_UNKNOWN