private void performAgainstAllInCache( CacheCallable callable ) { Set allKeysFromRegionCache = cacheManager.getAllKeysFromRegionCache( ICacheManager.SESSION ); for ( Object compositeKey : allKeysFromRegionCache ) { Matcher matcher = SESSION_KEY_PATTERN.matcher( compositeKey.toString() ); if ( matcher.matches() ) { String key = matcher.toMatchResult().group( 1 ); if ( ENTRY_COLLECTOR.equals( key ) ) { Object fromRegionCache = cacheManager.getFromRegionCache( ICacheManager.SESSION, compositeKey ); if ( EntryCache.class.isAssignableFrom( fromRegionCache.getClass() ) ) { callable.call( (EntryCache) fromRegionCache ); } } } } }