3

Ruby on Rails offers different caching techniques (https://guides.rubyonrails.org/caching_with_rails.html)

I just want to save and fetch some data to Memcached. And I don't want to use Memcached for other types of Rails caching like page caching or SQL caching.

I added the next settings to the environment file: config.cache_store = :dalli_store. And now get worked Rails.cache.write and Rails.cache.read. That's all of I need for my task.

Can I be sure that Rails will not use :dalli_store storage for other internal mechanisms like SQL Caching.

vovan
  • 1,460
  • 12
  • 22
  • 1
    Rails will not cache your SQL or DB output unless you explicitly tell it to. Go ahead and work with it. – Nick M Aug 05 '20 at 07:21

0 Answers0