
Theme support template invalidation in production
Reported by Sven Fuchs | January 23rd, 2009 @ 08:37 PM | in Release 0.1.1
In production ActionView compiles ERB templates and caches the result as dynamically created Ruby methods in memory.
When a template was saved the theme support engine removes this method from memory so it gets rebuilt on the next request.
This mechanism does not work with more than one server (Mongrel) process running because the cached method would need to be removed from all running server processes.
Instead we could have a "pull" mechanism here that checks the last theme modification time against a timestamp that is cached in memory when the first template was compiled. When the theme was modified after the first template was compiled then all compiled template methods can be removed (and will then be rebuilt).
This requires an extra check to occur each time #render is called so we might not want to compare mtimes for every template separately but instead sweep the whole compiled methods cache for the theme at once.
Comments and changes to this ticket
-
Sven Fuchs January 23rd, 2009 @ 08:38 PM
- State changed from new to open
-
Sven Fuchs January 24th, 2009 @ 01:37 PM
- State changed from open to resolved
Hopefully solved with http://github.com/svenfuchs/adva...
-
ava james March 17th, 2023 @ 04:16 PM
Nice post thanks for sharing this check this Lightinthebox Discount Code
Please Sign in or create a free account to add a new ticket.
With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.
Create your profile
Help contribute to this project by taking a few moments to create your personal profile. Create your profile »
<p>Cutting edge cms, blog, wiki, forum ... plattform.</p>
<p>Find the code on <a href="http://github.com/svenfuchs/adva_cms/tree/master">GitHub: adva cms</a></p>
<p>Part of the business application framework <a href="http://www.advabest.org/">adva best</a>.</p>