Skip to content

Commit 546ca13

Browse files
committed
Change all the Rails configs to the 7.1 defaults
1 parent 69a3002 commit 546ca13

File tree

2 files changed

+4
-18
lines changed

2 files changed

+4
-18
lines changed

config/application.rb

+1
Original file line numberDiff line numberDiff line change
@@ -41,5 +41,6 @@ class Application < Rails::Application
4141
# config.eager_load_paths << Rails.root.join("extras")
4242

4343
config.add_autoload_paths_to_load_path = false
44+
config.active_support.cache_format_version = 7.1
4445
end
4546
end

config/initializers/new_framework_defaults_7_1.rb

+3-18
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,7 @@
105105
# servers, first deploy without changing the serializer, then set the serializer
106106
# in a subsequent deploy.
107107
#++
108-
# Rails.application.config.active_support.message_serializer = :json_allow_marshal
108+
Rails.application.config.active_support.message_serializer = :json_allow_marshal
109109

110110
###
111111
# Enable a performance optimization that serializes message data and metadata
@@ -118,7 +118,7 @@
118118
# leave this optimization off on the first deploy, then enable it on a
119119
# subsequent deploy.
120120
#++
121-
# Rails.application.config.active_support.use_message_serializer_for_metadata = true
121+
Rails.application.config.active_support.use_message_serializer_for_metadata = true
122122

123123
###
124124
# Set the maximum size for Rails log files.
@@ -174,7 +174,7 @@
174174
# leave this optimization off on the first deploy, then enable it on a
175175
# subsequent deploy.
176176
#++
177-
# Rails.application.config.active_record.marshalling_format_version = 7.1
177+
Rails.application.config.active_record.marshalling_format_version = 7.1
178178

179179
###
180180
# Run `after_commit` and `after_*_commit` callbacks in the order they are defined in a model.
@@ -193,21 +193,6 @@
193193
#++
194194
Rails.application.config.active_record.generate_secure_token_on = :initialize
195195

196-
###
197-
# ** Please read carefully, this must be configured in config/application.rb **
198-
#
199-
# Change the format of the cache entry.
200-
#
201-
# Changing this default means that all new cache entries added to the cache
202-
# will have a different format that is not supported by Rails 7.0
203-
# applications.
204-
#
205-
# Only change this value after your application is fully deployed to Rails 7.1
206-
# and you have no plans to rollback.
207-
# When you're ready to change format, add this to `config/application.rb` (NOT
208-
# this file):
209-
# config.active_support.cache_format_version = 7.1
210-
211196
###
212197
# Configure Action View to use HTML5 standards-compliant sanitizers when they are supported on your
213198
# platform.

0 commit comments

Comments
 (0)