We have moved our forum to GitHub Discussions. For questions about Phalcon v3/v4/v5 you can visit here and for Phalcon v6 here.

Compiling templates to cache instead of a file

This one has been bugging me for w long time now. All volt files are compiled and saved in the "compiledPath" folder. Is it possible to change that somehow to a proper cache system? Like Memcache or wincache or something? So every time volt compiles a new template, instead of writing the output php into a file, it would go into memory.

I was thinking abot maybe writing a custom compiler that extends volt etc but that would probably impact the performance even more.

Thanks



98.9k
Accepted
answer

If you use APC or Zend Optimizer they're in memory always.



15.1k

I guess thats a fair point.