From 3d98f31c650fe780b3c1b307c680aaf2b0d72169 Mon Sep 17 00:00:00 2001 From: Claire Date: Mon, 13 Sep 2021 18:59:56 +0200 Subject: [PATCH] Fix some Rails frameworks being unnecessarily loaded (#16725) Saves about 10MiB of memory usage at boot --- config/application.rb | 17 ++++++++++++++++- 1 file changed, 16 insertions(+), 1 deletion(-) diff --git a/config/application.rb b/config/application.rb index 749b8aa5898..1761bdc2e61 100644 --- a/config/application.rb +++ b/config/application.rb @@ -1,6 +1,21 @@ require_relative 'boot' -require 'rails/all' +require 'rails' + +require 'active_record/railtie' +#require 'active_storage/engine' +require 'action_controller/railtie' +require 'action_view/railtie' +require 'action_mailer/railtie' +require 'active_job/railtie' +#require 'action_cable/engine' +#require 'action_mailbox/engine' +#require 'action_text/engine' +#require 'rails/test_unit/railtie' +require 'sprockets/railtie' + +# Used to be implicitly required in action_mailbox/engine +require 'mail' # Require the gems listed in Gemfile, including any gems # you've limited to :test, :development, or :production.