From the course: Linux for PHP Developers
Unlock the full course today
Join today to access over 23,100 courses taught by industry experts.
Installing Memcached memory caching
From the course: Linux for PHP Developers
Installing Memcached memory caching
- [Instructor] We're going to install two different caching systems, but why cache data and objects? In short, you can reuse the results of a complex query or operation instead of redoing the same work over and over again. A best practice when building a PHP application is to use a dedicated, purpose-built caching back end. Why is that? You can't just wave a want and make things faster. Most PHP applications already include caching back ends. The first, most likely, is a relational database such as MySQL. It makes sense in that it's always available, so no additional setup is required. However, a relational database is inefficient as a caching system because a relational database is best suited for relational queries, which the application will already be doing. It's not that a caching query is fast, but if the server is waiting to complete a bunch of small cache look ups, it can't perform a larger, more important query. The other option is the file system, such as a dedicated folder…
Practice while you learn with exercise files
Download the files the instructor uses to teach the course. Follow along and learn by watching, listening and practicing.