How to call silence! on dalli cache_store?

孤街浪徒 提交于 2019-12-07 09:30:20

问题


I'm trying to develop application with caching in development mode, but development.log spammed is heavily by cache logs. I'm use dalli, and I know, that dalli has silence! method (https://github.com/mperham/dalli/commit/892020fbc73613ccc84412ce04b85b7fda645e63), but how to use this method?

I found some old instructions, where it is suggested to call in on config.cache_store, but it is a symbol, and don't has this method:

config.cache_store = :dalli_store
config.cache_store.silence!

Throws exception.


回答1:


Try calling #silence! on Rails.cache



来源:https://stackoverflow.com/questions/13043968/how-to-call-silence-on-dalli-cache-store

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!