1 Reply Latest reply on Jul 12, 2013 7:30 PM by Sanne Grinovero

    Object updates not persisted to file with org.infinispan.loaders.file.FileCacheStore

    R AR Newbie

      Hi,

       

      Having a cache (clustering mode="local") persisting to a file using org.infinispan.loaders.file.FileCacheStore I do the following steps in it:

       

      1.- cache.put(key, value)

      2.- value = cache.get(key)

      3.- value.setName("name");

       

      After these actions, I can see that the object kept in the cache in memory has the value set in step 3 but this change is not persisted in the file. When I stop my application and start it, the cache only has the object values which where in the object at the "put" time.

       

      I found in the documentation the following: "Cache loader is Infinispan's connection to a (persistent) data store. Cache loader fetches data from a store when that data is not in the cache, and when modifications are made to data in the cache the CacheLoader is called to store those modifications back to the store."

       

      Despite it, is this the normal behavior or am I doing something wrong?

       

      Thanks

       

      Version: Infinispan 'Delirium' 5.2.1.Final