Files
notifications-api/app/clients/redis/__init__.py
Martyn Inglis 9e2ba9ee81 Pushed the cache increment into the shared code that persists notifications.
Much simpler implementation, inc code removed from tasks and V1/V2 rest clients.
2016-11-22 12:53:20 +00:00

6 lines
166 B
Python

from datetime import datetime
def daily_limit_cache_key(service_id):
return "{}-{}-{}".format(str(service_id), datetime.utcnow().strftime("%Y-%m-%d"), "count")