Remove deprecated `ActiveRecord::Base.connection_config`

This commit is contained in:
Rafael Mendonça França 2021-11-19 22:13:46 +00:00
parent 50ec25b506
commit 54ddb3be31
No known key found for this signature in database
GPG Key ID: FC23B6D0F1EEE948
3 changed files with 6 additions and 11 deletions

View File

@ -1,3 +1,7 @@
* Remove deprecated `ActiveRecord::Base.connection_config`.
*Rafael Mendonça França*
* Filter attributes in SQL logs
Previously, SQL queries in logs containing `ActiveRecord::Base.filter_attributes` were not filtered.

View File

@ -296,17 +296,6 @@ module ActiveRecord
self == Base || application_record_class?
end
# Returns the configuration of the associated connection as a hash:
#
# ActiveRecord::Base.connection_config
# # => {pool: 5, timeout: 5000, database: "db/development.sqlite3", adapter: "sqlite3"}
#
# Please use only for reading.
def connection_config
connection_pool.db_config.configuration_hash
end
deprecate connection_config: "Use connection_db_config instead"
# Returns the db_config object from the associated connection:
#
# ActiveRecord::Base.connection_db_config

View File

@ -254,6 +254,8 @@ Please refer to the [Changelog][active-job] for detailed changes.
* Remove deprecated `:return_false_on_aborted_enqueue` option.
* Remove deprecated `ActiveRecord::Base.connection_config`.
### Deprecations
* Deprecated `Rails.config.active_job.skip_after_callbacks_if_terminated`.