Utilizing Available Tools
Benefits of the Redis Caching Tool
In addition to elasticsearch, the Redis caching engine is another practical tool to improve performance. Redis is a mechanism for caching that allows the calls to the database to get stored in a cache. From there, the results from standard queries can automatically be saved into a flat file system. This becomes a huge asset, as flat file systems and flat databases generally have the following capabilities:
- Accessing data very rapidly
- Effectiveness with highly complex sets of information
- Data is stored in a way that can be accessed and filtered efficiently
- Without hammering the CPU and RAM in the hard drives to get the data
As a result, Redis can help minimize the site load time for certain key website components that are cached, therefore reduced by a 10X, 200X or more. This increase in loading speed is in comparison to other areas of the site, outside of the product catalog for example. The Redis tool is also applicable to more common components, like the menu, some of the detailed views on the product pages and even things like customer-specific pricing.
You might have hundreds of thousands of products, each with their own sets of customer-specific pricing. Well, that customer pricing can be cached so that once it initially loads, it's stored and then Redis serves it each time that particular end user is navigating through the site.
In this case, you might notice a relatively slow loading initially. But after it loads once, the data is stored and won’t require a call to the database until the Redis cache is cleared. Clearing the cache can be configured and optimized per section of the site, so there’s no need to apply the action everywhere.