diff --git a/app/services/location/jhu.py b/app/services/location/jhu.py index 1a11e8ac..07919cfe 100644 --- a/app/services/location/jhu.py +++ b/app/services/location/jhu.py @@ -46,7 +46,7 @@ async def get(self, loc_id): # pylint: disable=arguments-differ ) -@cached(cache=TTLCache(maxsize=128, ttl=1800)) +@cached(cache=TTLCache(maxsize=32, ttl=1800)) async def get_category(category): """ Retrieves the data for the provided category. The data is cached for 30 minutes locally, 1 hour via shared Redis. @@ -129,7 +129,7 @@ async def get_category(category): return results -@cached(cache=TTLCache(maxsize=1024, ttl=1800)) +@cached(cache=TTLCache(maxsize=1, ttl=1800)) async def get_locations(): """ Retrieves the locations from the categories. The locations are cached for 1 hour. diff --git a/app/services/location/nyt.py b/app/services/location/nyt.py index 8b70c5cc..3c092500 100644 --- a/app/services/location/nyt.py +++ b/app/services/location/nyt.py @@ -66,7 +66,7 @@ def get_grouped_locations_dict(data): return grouped_locations -@cached(cache=TTLCache(maxsize=128, ttl=3600)) +@cached(cache=TTLCache(maxsize=1, ttl=3600)) async def get_locations(): """ Returns a list containing parsed NYT data by US county. The data is cached for 1 hour.