Uploaded image for project: 'Hibernate OGM'
  1. OGM-1329

Add annotation to select the template configuration for a cache

    Details

    • Type: New Feature
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 5.4.0.Alpha1
    • Component/s: infinispan
    • Labels:
      None

      Description

      At the moment Hibernate OGM can create caches but only if a default configuration is defined on the Infinispan Server. We need to provide something to allow some customization.

      A few examples of what I'm thinking:

      @Entity
      @CacheTemplate("transactional_confg")
      public class Entity {
      ...
      }
      

      or

      @Entity
      @CacheTemplate(name = "transactional_confg")
      public class Entity {
      ...
      }
      

      The value is what we need to pass to the method:

      hotrodClient.administration().createCache( cacheName, cacheTemplate );
      

      Currently we pass null, see org.hibernate.ogm.datastore.infinispanremote.impl.InfinispanRemoteDatastoreProvider#startAndValidateCaches()

      Tests can be run using maven or via InfinispanRemoteBackendTckHelper.

        Attachments

          Issue links

            Activity

              People

              • Votes:
                0 Vote for this issue
                Watchers:
                5 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: