Added caching handling