The application code effectively maintains the cache. It attempts to read from cache; if miss, it reads from DB and writes to cache.
App checks Redis for 'user:123'. If missing, fetches from MySQL, saves to Redis, and returns to user.
class Cache-Aside:\n def __init__(self):\n pass\n\n def execute(self):\n print('Executing Cache-Aside')