1 Reply Latest reply on Jun 30, 2010 7:16 AM by mircea.markus

    Multiple local and distributed caches from same configuration...?

    girishadat

      I am planning to migrate to Infinispan from JBossCache 3 (Pojo 3.0.0 and Core 3.2.4, with JBossTS 4.6 and JGroups 2.8). A few configuration related questions:

       

      1. Can I make two named-caches in a configuration with one of them in LOCAL mode and other in DIST_ASYNC/REPL_ASYNC mode? I can set Manager.getConfiguration().setCacheMode(). Can I override it @ each named-cache level?
      2. Are there any issues in running two Infinispan instances in single JVM? May be (a) one LOCAL and other DIST_ASYNC, or (b) one in one JGroups cluster and other in another JGroups cluster?

       

      Please advise...

        • 1. Re: Multiple local and distributed caches from same configuration...?
          mircea.markus

          1. yes. you can have 2 (or more) caches with different configurations within the same CacheManager. The cache mode is configured as Cache level, not at CacheManager level.

          2. What do you mean by Infinispan instances? if it is CacheManager, then yes, you can have multiple cache managers running in the same JVM - we recommend one if it is possible as multiple cache managers would duplicate resources(e.g. jgroups channel handle). All the caches associated to an CacheManager share the same transport(jgrous channel), so if you need to be part of two different jgroups clusters you'll need two CacheManagers.

          HTH,

          Mircea