# Caching layer

A step of the [Cloud application](https://gradus.kazet.blog/tree/cloud-application) tree on Gradus, in the Data & storage area: DB, cache, queues.

Page: https://gradus.kazet.blog/tree/cloud-application/step/caching

Add a cache such as Redis in front of the hottest, most expensive reads.

Usually comes after: [Data access layer & seed data](https://gradus.kazet.blog/tree/cloud-application/step/data-access-layer).

## Prompt for your AI assistant

```
Add a Redis-backed cache in front of the most frequently read, expensive query in this application, with a sensible TTL and invalidation strategy.
```

Every step of the tree: https://gradus.kazet.blog/tree/cloud-application/llms.txt
