Theo's Typesafe CultTTC
Theo's Typesafe Cult3y ago
3 replies
jgoon

Server side caching with Next API

Unsure if this pattern is common, or if I am approaching this incorrectly.

I am using an api in my backend (next route handlers /api), and want to cache the data for 24 hours, so that I am only calling the api once a day.

I understand how this can be done in a typical server using memory, but am curious if there is a different method possible when using serverless (since there is no persistent memory) that doesnt involve s3 or introducing a whole db.

Please clarify if I am misunderstanding anything! Thanks!
Was this page helpful?