Hello, can you please advise about QueryCache middleware. By default it thinks that I'm using only one connection (ActiveRecord::Base.connection) and sql generated by models connected to other DBs are not cached
For instance cache works for this
class Item < ActiveRecord::Base
end
and doesn't work for this
class SlaveItem < ActiveRecord::Base
establish_connection "#{Rails.env}_slave".to_sym
end
But manual says "Query caching is a Rails feature that caches the result set returned by each query"
SO thread http://stackoverflow.com/questions/4326250/why-is-rails-query-caching-not-working
Hello, can you please advise about QueryCache middleware. By default it thinks that I'm using only one connection (ActiveRecord::Base.connection) and sql generated by models connected to other DBs are not cached
For instance cache works for this
and doesn't work for this
But manual says "Query caching is a Rails feature that caches the result set returned by each query"
SO thread http://stackoverflow.com/questions/4326250/why-is-rails-query-caching-not-working