diff options
author | Christophe Maximin <christophe.maximin@gmail.com> | 2018-10-05 13:00:45 +0100 |
---|---|---|
committer | Christophe Maximin <christophe.maximin@gmail.com> | 2018-10-10 00:17:05 +0100 |
commit | 961776832d13b4cea7f67aface2c2882416ac975 (patch) | |
tree | 2e0853cb0775f11c69622c1da2e2bb16906bbd05 /activerecord/CHANGELOG.md | |
parent | 1ceaf7db5013a233bdc671b3f46583c4c1189fe1 (diff) | |
download | rails-961776832d13b4cea7f67aface2c2882416ac975.tar.gz rails-961776832d13b4cea7f67aface2c2882416ac975.tar.bz2 rails-961776832d13b4cea7f67aface2c2882416ac975.zip |
Clear QueryCache when reloading associations
Diffstat (limited to 'activerecord/CHANGELOG.md')
-rw-r--r-- | activerecord/CHANGELOG.md | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/activerecord/CHANGELOG.md b/activerecord/CHANGELOG.md index 96fd6a62c6..19558a9e0c 100644 --- a/activerecord/CHANGELOG.md +++ b/activerecord/CHANGELOG.md @@ -1,3 +1,20 @@ +* Reloading associations now clears the Query Cache like `Persistence#reload` does. + + ``` + class Post < ActiveRecord::Base + has_one :category + belongs_to :author + has_many :comments + end + + # Each of the following will now clear the query cache. + post.reload_category + post.reload_author + post.comments.reload + ``` + + *Christophe Maximin* + * Added `index` option for `change_table` migration helpers. With this change you can create indexes while adding new columns into the existing tables. |