2 Replies Latest reply on Dec 4, 2004 11:06 PM by Ben Wang

    Facing problem with Cache Replication/TransactionManager

    A V Newbie


      1> I am trying to instantiate two instances of JBoss Cache on two Machines (say Mac1 and Mac2).

      Mac1 is started up first and a bunch of Nodes is put into the Cache. From Mac2, I am able to see the Nodes that are created and replicated. But latter modification to the cache in Mac1 using putObject() dont seem to be seen when the getObject() is done on Mac2.

      I am sure I am missing something.




      2> Also, maybe related, when starting the Server, I get this error in the log :


      javax.naming.NameNotFoundException: Invalid name:/TransactionManager
      at com.sun.enterprise.naming.java.javaURLContext.getRelativeName(javaURLContext.java:424)
      at com.sun.enterprise.naming.java.javaURLContext.getComponentContext(javaURLContext.java:382)
      at com.sun.enterprise.naming.java.javaURLContext.callBindOrRebind(javaURLContext.java:124)
      at com.sun.enterprise.naming.java.javaURLContext.bind(javaURLContext.java:80)
      at javax.naming.InitialContext.bind(InitialContext.java:355)
      at org.jboss.cache.transaction.DummyTransactionManager.getInstance(DummyTransactionManager.java:41)
      at org.jboss.cache.DummyTransactionManagerLookup.getTransactionManager(DummyTransactionManagerLookup.java:17)
      at org.jboss.cache.TreeCache.startService(TreeCache.java:1098)
      at com.nomura.localrisk.cache.RepositoryCacheImpl.(RepositoryCacheImpl.java:68)
      at com.nomura.localrisk.admin.ServerStartup.main(ServerStartup.java:425)


      My conf file :



      <?xml version="1.0" encoding="UTF-8"?>

      <!-- ===================================================================== -->
      <!-- -->
      <!-- Sample TreeCache Service Configuration -->
      <!-- -->
      <!-- ===================================================================== -->






      <!-- ==================================================================== -->
      <!-- Defines TreeCache configuration -->
      <!-- ==================================================================== -->




      jboss:service=Naming
      jboss:service=TransactionManager


      org.jboss.cache.DummyTransactionManagerLookup

      <!--
      Isolation level : SERIALIZABLE
      REPEATABLE_READ (default)
      READ_COMMITTED
      READ_UNCOMMITTED
      NONE
      -->
      REPEATABLE_READ

      <!--
      Valid modes are LOCAL, REPL_ASYNC and REPL_SYNC
      -->
      REPL_ASYNC

      <!--
      Just used for async repl: use a replication queue
      -->
      false

      <!--
      Replication interval for replication queue (in ms)
      -->
      0

      <!--
      Max number of elements which trigger replication
      -->
      0

      <!-- Name of cluster. Needs to be the same for all clusters, in order
      to find each other
      -->
      RepositoryCluster

      <!-- JGroups protocol stack properties. Can also be a URL,
      e.g. file:/home/bela/default.xml

      -->



      |
      <TCP start_port="7800" bind_addr="147.85.34.229"/>
      <TCPPING initial_hosts="147.85.34.229[7900]" port_range="1" timeout="3000" num_initial_members="2" up_thread="true" down_thread="true"/>
      <FD shun="true" up_thread="true" down_thread="true" timeout="2500" max_tries="5" />
      <VERIFY_SUSPECT timeout="1500" up_thread="false" down_thread="false" />
      <pbcast.NAKACK gc_lag="100" retransmit_timeout="3000" up_thread="true" down_thread="true" />
      <pbcast.STABLE desired_avg_gossip="20000" up_thread="false" down_thread="false" />
      <pbcast.GMS join_timeout="5000" join_retry_timeout="2000" shun="false" print_local_addr="false" down_thread="true" up_thread="true" />
      <pbcast.STATE_TRANSFER up_thread="true" down_thread="true"/>










      RepositoryCache



      <!--
      Whether or not to fetch state on joining a cluster
      -->
      true

      <!--
      The max amount of time (in milliseconds) we wait until the
      initial state (ie. the contents of the cache) are retrieved from
      existing members in a clustered environment
      -->
      5000

      <!--
      Number of milliseconds to wait until all responses for a
      synchronous call have been received.
      -->
      10000

      <!-- Max number of milliseconds to wait for a lock acquisition -->
      15000


      <!-- Name of the eviction policy class. Not supported now. -->
      <!--

      -->


      <!--
      org.jboss.cache.loader.bdbje.BdbjeCacheLoader
      c:\tmp\bdbje
      true
      /
      -->

      <!--
      org.jboss.cache.loader.FileCacheLoader
      c:\tmp
      true
      /

      -->






      <!-- Uncomment to get a graphical view of the TreeCache MBean above -->
      <!-- -->
      <!-- jboss.cache:service=TreeCache-->
      <!-- jboss.cache:service=TreeCache-->
      <!-- -->