I recently started hosting a website with an API. The api worked great when i ran it locally. While hosting it the POST requests are lightning quick at inserting data into my database. However the GET requests will usually just retrieve data that is 5 minutes old (I.e. there is a 5 minute delay between posting data and seeing the API retrieve it). The problem is not that the GET requests are taking 5 minutes, the GET requests run quickly it just takes them 5 minutes to realize new data has been added to the database. Any idea why this is happening?
Edit: Issue has been solved, caching was enabled in my browser which caused the GET request to not check the updated database
Please sign in to leave a comment.