Cache and Rule
Accelerate the speed of your API responses with a few changes in the codebase.
We'll cover the following
Why and when to cache?
There are many ways to maintain the speed and performance of our API endpoints: Improved DB queries, DB indexes, queueing delayable actions, caching data, etc. In this lesson, we will cover caching.
We cache the data that does not frequently change. Ideally, there should be a pre-defined boundary of the data that we wish to cache. This allows us to set proper cache keys and quickly identify the places in the code where we need to invalidate the cache. Time to try it with the actual example from our API endpoints.
Get hands-on with 1200+ tech skills courses.