File tree Expand file tree Collapse file tree 1 file changed +9
-0
lines changed
hibernate-core/src/main/java/org/hibernate/internal Expand file tree Collapse file tree 1 file changed +9
-0
lines changed Original file line number Diff line number Diff line change @@ -232,6 +232,9 @@ public boolean containsQuery(String regionName) {
232
232
@ Override
233
233
public void evictDefaultQueryRegion () {
234
234
if ( sessionFactory .getSettings ().isQueryCacheEnabled () ) {
235
+ if ( LOG .isDebugEnabled () ) {
236
+ LOG .debugf ( "Evicting default query region cache." );
237
+ }
235
238
sessionFactory .getQueryCache ().clear ();
236
239
}
237
240
}
@@ -247,6 +250,9 @@ public void evictQueryRegion(String regionName) {
247
250
QueryCache namedQueryCache = queryCaches .get ( regionName );
248
251
// TODO : cleanup entries in queryCaches + allCacheRegions ?
249
252
if ( namedQueryCache != null ) {
253
+ if ( LOG .isDebugEnabled () ) {
254
+ LOG .debugf ( "Evicting query cache, region: %s" , regionName );
255
+ }
250
256
namedQueryCache .clear ();
251
257
}
252
258
}
@@ -257,6 +263,9 @@ public void evictQueryRegions() {
257
263
if ( CollectionHelper .isEmpty ( queryCaches ) ) {
258
264
return ;
259
265
}
266
+ if ( LOG .isDebugEnabled () ) {
267
+ LOG .debugf ( "Evicting cache of all query regions." );
268
+ }
260
269
for ( QueryCache queryCache : queryCaches .values () ) {
261
270
queryCache .clear ();
262
271
// TODO : cleanup entries in queryCaches + allCacheRegions ?
You can’t perform that action at this time.
0 commit comments