From d325010d6483b4a0ccb386255d86c88d90ad7e38 Mon Sep 17 00:00:00 2001 From: Go MAEDA Date: Thu, 10 Apr 2025 11:05:01 +0000 Subject: [PATCH] Adds the Bullet gem to detect query problems such as N+1 and improve performance (#42555). Patch by Katsuya HIDAKA (user:hidakatsuya). git-svn-id: https://svn.redmine.org/redmine/trunk@23621 e93f8b46-1217-0410-a6f0-8f06a7374b81 --- Gemfile | 1 + config/environments/development.rb | 6 ++++++ 2 files changed, 7 insertions(+) diff --git a/Gemfile b/Gemfile index 90426b64c..00d583f91 100644 --- a/Gemfile +++ b/Gemfile @@ -98,6 +98,7 @@ group :development do gem 'listen', '~> 3.3' gem 'yard', require: false gem 'svg_sprite', require: false + gem 'bullet' end group :test do diff --git a/config/environments/development.rb b/config/environments/development.rb index 5b3ff43dc..d41e817f3 100644 --- a/config/environments/development.rb +++ b/config/environments/development.rb @@ -59,4 +59,10 @@ Rails.application.configure do # Uncomment if you wish to allow Action Cable access from any origin. # config.action_cable.disable_request_forgery_protection = true + + config.after_initialize do + Bullet.enable = true + Bullet.rails_logger = true + Bullet.skip_user_in_notification = true + end end