Major API calls should be cached in memory (redis to scale) and returned instantly without a database query. Whenever new data arrives in the database, trigger a cache refresh. Also whenever a user requests resource the cache can be refreshed after responding to the user.
Major API calls should be cached in memory (redis to scale) and returned instantly without a database query. Whenever new data arrives in the database, trigger a cache refresh. Also whenever a user requests resource the cache can be refreshed after responding to the user.