Added caching functionality, and api for enabling/disabling logging service