Sha256: 76682bc0eab87f1fc66c59a5405902b43428929adfc630553a4e7e32fa19ea33
Contents?: true
Size: 436 Bytes
Versions: 2
Compression:
Stored size: 436 Bytes
Contents
module ActiveRecordMultipleQueryCache class Rails5QueryCache < Base def run caching_pool = active_record_base_class.connection.pool caching_was_enabled = caching_pool.query_cache_enabled caching_pool.enable_query_cache! [caching_pool, caching_was_enabled] end def complete((caching_pool, caching_was_enabled)) caching_pool.disable_query_cache! unless caching_was_enabled end end end
Version data entries
2 entries across 2 versions & 1 rubygems