diff options
author | Thong Kuah <tkuah@gitlab.com> | 2019-03-12 09:29:08 +0000 |
---|---|---|
committer | Thong Kuah <tkuah@gitlab.com> | 2019-03-12 09:29:08 +0000 |
commit | de54e4f9c7b7babf09fdc3451f17c18fa5fef445 (patch) | |
tree | 78264e10172bbcec5e69f9e0e48f65cd3cde93c5 | |
parent | 32056fc7b282d1fd14e62939e721c7935492ec8f (diff) | |
download | gitlab-ce-de54e4f9c7b7babf09fdc3451f17c18fa5fef445.tar.gz |
Revert "Merge branch 'check_pg_stat_activity' into 'master'"
This reverts merge request !25723
-rw-r--r-- | spec/support/pg_stat_activity.rb | 19 |
1 files changed, 0 insertions, 19 deletions
diff --git a/spec/support/pg_stat_activity.rb b/spec/support/pg_stat_activity.rb deleted file mode 100644 index f93fba08a19..00000000000 --- a/spec/support/pg_stat_activity.rb +++ /dev/null @@ -1,19 +0,0 @@ -# frozen_string_literal: true - -RSpec.configure do |config| - config.before do - if Gitlab::Database.postgresql? && ENV['PG_STAT_WARNING_THRESHOLD'] - warning_threshold = ENV['PG_STAT_WARNING_THRESHOLD'].to_i - results = ActiveRecord::Base.connection.execute('SELECT * FROM pg_stat_activity') - ntuples = results.ntuples - - warn("pg_stat_activity count: #{ntuples}") - - if ntuples > warning_threshold - results.each do |result| - warn result.inspect - end - end - end - end -end |