This forum is not used anymore. Please ask new questions to Stack Overflow: https://stackoverflow.com/questions/tag ... ort=newest (use aspnetboilerplate tag).
By joemo
#5858 I can use the cache successfully like this:-

var members = _cacheManager
.GetCache("MembersCache")
.Get("Members", () => GetMembersFromDatabase(input.ParentCompanyId)) as List<Customer>;

which calls this:-
private List<Customer> GetMembersFromDatabase(int ParentCompanyId)
{
return _customerRepository.GetAllList(x => x.ParentCompanyId == ParentCompanyId);
}

I've set the timeout to 15 mins. The problem is, after 15 minutes it returns no results.
I would have expected it to start calling the GetMembersFromDatabase function again to get fresh data, but it doesn't
Where am I going wrong?