mirror of
https://github.com/rails/rails.git
synced 2022-11-09 12:12:34 -05:00
Added missing docs for clear_cache! on adapters
This commit is contained in:
parent
e2656e07b9
commit
0e2644cde0
3 changed files with 3 additions and 0 deletions
|
@ -332,6 +332,7 @@ module ActiveRecord
|
|||
rows
|
||||
end
|
||||
|
||||
# Clear prepared statement cache.
|
||||
def clear_cache!
|
||||
@statements.values.each do |cache|
|
||||
cache[:stmt].close
|
||||
|
|
|
@ -237,6 +237,7 @@ module ActiveRecord
|
|||
@local_tz = execute('SHOW TIME ZONE', 'SCHEMA').first["TimeZone"]
|
||||
end
|
||||
|
||||
# Clear prepared statement cache.
|
||||
def clear_cache!
|
||||
@statements.each_value do |value|
|
||||
@connection.query "DEALLOCATE #{value}"
|
||||
|
|
|
@ -96,6 +96,7 @@ module ActiveRecord
|
|||
@connection.close rescue nil
|
||||
end
|
||||
|
||||
# Clear prepared statement cache.
|
||||
def clear_cache!
|
||||
@statements.clear
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue