Skip to content

Commit

Permalink
[BACKLOG-39705] Remove from Region Cache not removing 1st level cache…
Browse files Browse the repository at this point in the history
… entry.
  • Loading branch information
Tim Kafalas tkafalas committed Jan 30, 2024
1 parent 7c88769 commit 32793d4
Showing 1 changed file with 4 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -400,7 +400,10 @@ public Set getAllEntriesFromRegionCache( String region ) {
public void removeFromRegionCache( String region, Object key ) {
if ( checkRegionEnabled( region ) ) {
HvCache hvcache = (HvCache) regionCache.get( region );
hvcache.evictEntityData( (String) key );
try ( SessionImpl session = (SessionImpl) hvcache.getSessionFactory().openSession() ) {
hvcache.getStorageAccess().removeFromCache( key, session );
hvcache.evictEntityData( (String) key );
}
} else {
CacheManager.logger.warn( Messages.getInstance().getString(
"CacheManager.WARN_0003_REGION_DOES_NOT_EXIST", region ) ); //$NON-NLS-1$
Expand Down

0 comments on commit 32793d4

Please sign in to comment.