mirror of
https://github.com/GSA/notifications-api.git
synced 2025-12-20 15:31:15 -05:00
to get the data for a day can be reasonably slow (a few hundred milliseconds), and if someone's viewing a service with no activity we don't want to do that query seven times every two seconds. So if there is no data in redis, when we get the data out of the database, we should put it in redis so we can just grab it from there next time. This'll happen in two cases: * redis data is deleted * the service sent no messages that day additionally, make sure that we convert nicely from redis' return values (ascii strings) to unicode keys and integer counts.