From 34497524934f32d2216c7e745c56672dda3a3ca5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Galder=20Zamarre=C3=B1o?= Date: Wed, 29 Feb 2012 17:54:27 +0100 Subject: [PATCH] HHH-7127 Fix query cache evictAll in single node --- .../hibernate/cache/infinispan/query/QueryResultsRegionImpl.java | 1 + .../cache/infinispan/timestamp/TimestampsRegionImpl.java | 1 + 2 files changed, 2 insertions(+) diff --git a/hibernate-infinispan/src/main/java/org/hibernate/cache/infinispan/query/QueryResultsRegionImpl.java b/hibernate-infinispan/src/main/java/org/hibernate/cache/infinispan/query/QueryResultsRegionImpl.java index d4296f768d..8ec6e00c00 100644 --- a/hibernate-infinispan/src/main/java/org/hibernate/cache/infinispan/query/QueryResultsRegionImpl.java +++ b/hibernate-infinispan/src/main/java/org/hibernate/cache/infinispan/query/QueryResultsRegionImpl.java @@ -37,6 +37,7 @@ public class QueryResultsRegionImpl extends BaseTransactionalDataRegion implemen public void evictAll() throws CacheException { Transaction tx = suspend(); try { + invalidateRegion(); // Invalidate the local region and then go remote cacheAdapter.broadcastEvictAll(); } finally { resume(tx); diff --git a/hibernate-infinispan/src/main/java/org/hibernate/cache/infinispan/timestamp/TimestampsRegionImpl.java b/hibernate-infinispan/src/main/java/org/hibernate/cache/infinispan/timestamp/TimestampsRegionImpl.java index bd6c52869e..147d9c0190 100644 --- a/hibernate-infinispan/src/main/java/org/hibernate/cache/infinispan/timestamp/TimestampsRegionImpl.java +++ b/hibernate-infinispan/src/main/java/org/hibernate/cache/infinispan/timestamp/TimestampsRegionImpl.java @@ -45,6 +45,7 @@ public class TimestampsRegionImpl extends BaseGeneralDataRegion implements Times // TODO Is this a valid operation on a timestamps cache? Transaction tx = suspend(); try { + invalidateRegion(); // Invalidate the local region and then go remote cacheAdapter.broadcastEvictAll(); } finally { resume(tx);