Back to the Learning

Beep Beep. Subscription Required.

Laracasts is packed full with over 1,500 lessons just like this one.
Sign up to get full access or log in to your account and sit back.

Your Teacher | Jeffrey Way's avatar
Hi, I'm Jeffrey. I'm the creator of Laracasts and spend most of my days building the site and thinking of new ways to teach confusing concepts. I live in Orlando, Florida with my wife and two kids.

About This Episode

Published on Oct 6th, 2016

Before we move on to learning about PubSub in Redis, let's take a short break to review how we might organize our PHP to best take advantage of caching. In the previous episode, we simply wrapped our database query in a call to Cache::remember(). But, what if we want to dry up our code a bit, or even turn the caching on and off (through the use of decorators), like the flick of a switch? In this episode, I'll demonstrate a few options that you might consider.

Back to Series Button