This seems to write to the database on every request. Could it have a threshold added, so it only updates the database every minute, or a user configurable period, based on the updated_at time?