We need to add full cache support for most routes. This should be done via middleware. We need the cache-control, etag, and expires at headers. Since data rarely changes, most routes should be cached.
The etag could be a hash of the model or of the DB updated_at timestamp. The cache headers should only be added if the request is successful. The controller could set the value of the etag on the request itself (poem request extension).
We need to add full cache support for most routes. This should be done via middleware. We need the cache-control, etag, and expires at headers. Since data rarely changes, most routes should be cached.
The etag could be a hash of the model or of the DB
updated_at
timestamp. The cache headers should only be added if the request is successful. The controller could set the value of the etag on the request itself (poem request extension).