summaryrefslogtreecommitdiff
path: root/db
diff options
context:
space:
mode:
authorMayra Cabrera <mcabrera@gitlab.com>2019-07-10 19:26:47 +0000
committerStan Hu <stanhu@gmail.com>2019-07-10 19:26:47 +0000
commit0ab89d8e36ba58a95244b4c6dd49d53fac7a699f (patch)
tree40707956c6a5942b6301b18b2e85e5336fa590c3 /db
parent82503745143faf2b71185c9f392dbfd00d6d587e (diff)
downloadgitlab-ce-0ab89d8e36ba58a95244b4c6dd49d53fac7a699f.tar.gz
Add a rubocop for Rails.logger
Suggests to use a JSON structured log instead Related to https://gitlab.com/gitlab-org/gitlab-ce/issues/54102
Diffstat (limited to 'db')
-rw-r--r--db/post_migrate/20180223124427_build_user_interacted_projects_table.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/db/post_migrate/20180223124427_build_user_interacted_projects_table.rb b/db/post_migrate/20180223124427_build_user_interacted_projects_table.rb
index fa332fd5c70..325895a5ddb 100644
--- a/db/post_migrate/20180223124427_build_user_interacted_projects_table.rb
+++ b/db/post_migrate/20180223124427_build_user_interacted_projects_table.rb
@@ -82,7 +82,7 @@ class BuildUserInteractedProjectsTable < ActiveRecord::Migration[4.2]
iteration = 0
records = 0
begin
- Rails.logger.info "Building user_interacted_projects table, batch ##{iteration}"
+ Rails.logger.info "Building user_interacted_projects table, batch ##{iteration}" # rubocop:disable Gitlab/RailsLogger
result = execute <<~SQL
INSERT INTO user_interacted_projects (user_id, project_id)
SELECT e.user_id, e.project_id
@@ -93,7 +93,7 @@ class BuildUserInteractedProjectsTable < ActiveRecord::Migration[4.2]
SQL
iteration += 1
records += result.cmd_tuples
- Rails.logger.info "Building user_interacted_projects table, batch ##{iteration} complete, created #{records} overall"
+ Rails.logger.info "Building user_interacted_projects table, batch ##{iteration} complete, created #{records} overall" # rubocop:disable Gitlab/RailsLogger
Kernel.sleep(SLEEP_TIME) if result.cmd_tuples > 0
end while result.cmd_tuples > 0
end