Add basic caching with ttl