CC-5555 : Implement simple caching for preferences

using apc to save/fetch preferences to/from a cache.