Skip to content

Tag: caching

False sharing and volatile

Good day, I recently found an annotation introduced in Java 8 called Contended. From this mailing list I read what is false sharing and how annotation allows objects or fields to allocate an entire …

How to use Redis as L2 cache on Hibernate?

I have a spring boot application and need to setup Redis as l2 cache on hibernate. My prop file looks like: I created a custom region factory because I don’t want to use json or yaml files. (right now, the parameters are hardcoded). CustomRegionFactory class looks like: Using redis-cli I found out that all my entities annotated with @Cacheable are

Infinispan : locking in remote transactional cache

We try to use infinispan as a remote cache with a read lock. The clients are making a read with a “put” in order to acquire a lock on the key, like described infinispan documentation in the section pessimistic transactional cache “When cache.put(k1,v1) returns, k1 is locked and no other transaction running anywhere in the cluster can write to it.