reduce caching duration

This commit is contained in:
Collin Barrett 2018-09-24 20:16:15 -05:00
parent c9dc88e58b
commit 55cb8583f4

View file

@ -5,13 +5,13 @@
namespace FilterLists.Api.V1.Controllers
{
[ApiVersion("1")]
[ApiVersion("1.0")]
//TODO: use versioning without needing to manually specify in swagger-ui (https://github.com/domaindrivendev/Swashbuckle.AspNetCore/issues/370)
[Route("v{version:apiVersion}/[controller]")]
[ResponseCache(Duration = 86400)]
[ResponseCache(Duration = 14400)]
public class BaseController : Controller
{
protected static readonly TimeSpan MemoryCacheExpirationDefault = TimeSpan.FromDays(1);
protected static readonly TimeSpan MemoryCacheExpirationDefault = TimeSpan.FromHours(4);
protected readonly IMemoryCache MemoryCache;
protected readonly SeedService SeedService;