Improvements in caching and counters API implementations
Merge remote-tracking branch 'origin/master'