• Francisco Javier López's avatar
    Ensure freshness of settings with snippet creation · 00dea6c4
    Francisco Javier López authored
    Application settings from the database are currently cached locally in
    the thread for a full minute after the changes are made. That means if
    an administrator attempts to change the default storages in the admin
    page, it might take up to a full minute for those changes to take
    effect.
    
    Since we don't have a great cache invalidation strategy for local caches
    yet, the simplest approach to solving this problem would be to expire
    the local application setting cache whenever we create a snippet. This
    causes every snippet creation to make an additional SELECT call for
    `application_settings`.
    00dea6c4
project.rb 81.5 KB