Monday, 29 April 2019

Doctrine metadata cache during atomic deployments

How do you handle Doctrine's metadata cache during application deployment?

We use the atomic deployment strategy for our applications. Until now we used to use the default file caching method which works very well. We would like however to switch to an in-memory cache like Redis/Memcached for performance reasons.

Should we use some kind of cache ID prefix for each release? For instance when a new version of the software is released, the deployment script warms up the app and fills the cache with new schema metadata. Should the deploy fail we do the rollback and the metadata cache would be still valid.

What's the best method to approach this? I'd like to avoid CPU spikes when the first requests come in and there's no metadata cache yet.



from Doctrine metadata cache during atomic deployments

No comments:

Post a Comment