Add tests for CacheService and fix bugs
Fix client caching to preserve top level object identities
Add tests to Session and refactor/fix bugs