I have one table configuration_variables(name,value). It contains configuration variables for my symfony-application such as reset-password-link-expiration-time. Since these configuration variables change rarely, I want to cache it in a temporary folder (app/cache is the right place?).
How can I do it in symfony2?
I tried How to cache in Symfony 2?. But I think it is not suitable to my reqiuirement.
You could create a cache warmer http://blog.servergrove.com/2012/04/18/how-to-create-a-cache-warmer-in-symfony2/ to cache the configuration in a file. You could use http://php.net/manual/fr/function.var-export.php to export the data to the file, or serialize.
Then, create a service that uses the data from the file.