FINERACT-1724: Making sure that the cache is empty upon starting a transaction for default cache configurations
This commit is contained in:
committed by
Arnold Gálovics
parent
41651a6cbb
commit
3b337c96ee
+9
@@ -31,6 +31,15 @@ public class TransactionBoundCacheManager implements TransactionLifecycleCallbac
|
||||
|
||||
@Override
|
||||
public void afterCompletion() {
|
||||
resetCaches();
|
||||
}
|
||||
|
||||
@Override
|
||||
public void afterBegin() {
|
||||
resetCaches();
|
||||
}
|
||||
|
||||
private void resetCaches() {
|
||||
Collection<String> cacheNames = delegate.getCacheNames();
|
||||
cacheNames.forEach(c -> {
|
||||
Cache cache = delegate.getCache(c);
|
||||
|
||||
Reference in New Issue
Block a user