Library for smart caching and invalidating this cache