简体   繁体   English

在Spree ruby​​ gem中缓存配置

[英]Caching configs in Spree ruby gem

When I update spree config via admin panel Spree::Config[some_key] = some_value it overwrites the value in a spree_preferences table, but also store previous versions of value and use all these versions. 当我通过管理面板Spree::Config[some_key] = some_value更新spree配置时,它将覆盖spree_preferences表中的值,但还会存储value的先前版本并使用所有这些版本。 Rails.cache.clear do not help. Rails.cache.clear没有帮助。 But restart a unicorn helped me. 但是重启独角兽帮助了我。

Where are these versions stored? 这些版本存储在哪里? How can I explicitly reset the cached values ​​in the code? 如何在代码中显式重置缓存的值?

问题出在独角兽工人的缓存上。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM