[jboss-user] [JBossCache] - TreeCache Replication in Cluster not working

kpandey do-not-reply at jboss.com
Wed Feb 13 16:16:37 EST 2008


[Jboss - 4.2.2.GA
JGroups - 2.4.1-SP4
JBossCache - 1.4.1.SP5]


I'm testing simple TreeCache replication in Cluster mode. When some data is put in cache of node1, node2 is notified but the cache on node2 is not updated with the new data.

Here's the log snippet 
Node1 log where data is added to cache
------------------------------------
2008-02-13 21:53:08,112 DEBUG [org.jboss.cache.eviction.BaseEvictionAlgorithm] Adding element /a/b/c for a node that doesn't exist yet. Process as an add.

2008-02-13 21:53:08,114 DEBUG [org.jboss.cache.eviction.BaseEvictionAlgorithm] Adding element /a/b/c/d for a node that doesn't exist yet. Process as an add.

Node2 log
-------------------------------------
2008-02-13 20:53:17,073 DEBUG [org.jboss.cache.marshall.TreeCacheMarshaller140] Received call on an inactive Fqn region (/a/b/c).  Calling notifyCallOnInactiveMetod

2008-02-13 20:53:17,079 DEBUG [org.jboss.cache.marshall.TreeCacheMarshaller140] Received call on an inactive Fqn region (/a/b/c/d).  Calling notifyCallOnInactiveMetod


Howerver node2 still shows 0 nodes
org.jboss.cache.TreeCache [0 nodes, 0 locks]

Hrere's my cache config file

  | <?xml version="1.0" encoding="UTF-8"?>
  | <server>
  | 
  |    <!-- ========================================================== -->
  |    <!-- Clustered Seratelbe cache config for use with JBoss Cache 1.4.x --> 
  |    <!-- ========================================================== -->
  |    <mbean code="org.jboss.cache.TreeCache" 
  |           name="jboss.cache:service=SeratelBeClusteredCache">
  |       
  |       <depends>jboss:service=Naming</depends> 
  |       <!--depends>jboss:service=TransactionManager</depends--> 
  |             
  |       <attribute name="IsolationLevel">NONE</attribute>
  | 
  |       <attribute name="CacheMode">REPL_SYNC</attribute>
  | 
  |       <!-- We want to activate/inactivate regions as beans are deployed -->
  |       <attribute name="UseRegionBasedMarshalling">true</attribute>
  |       <!-- Must match the value of "useRegionBasedMarshalling" -->
  |       <attribute name="InactiveOnStartup">true</attribute>
  | 
  | 	  <!-- 
  | 	       JGroups stuff here --Omitted
  | 	  -->     
  |       
  | 
  |       <attribute name="InitialStateRetrievalTimeout">17500</attribute>
  | 
  |       <attribute name="SyncReplTimeout">17500</attribute>
  | 
  |       <!--  Max number of milliseconds to wait for a lock acquisition -->
  |       <attribute name="LockAcquisitionTimeout">15000</attribute>
  | 
  |       <!--  Name of the eviction policy class. -->
  |       <attribute name="EvictionPolicyClass">org.jboss.cache.eviction.LRUPolicy</attribute>
  | 
  |       <!--  Specific eviction policy configurations. -->
  |       <attribute name="EvictionPolicyConfig">
  |          <config>
  |             <attribute name="wakeUpIntervalSeconds">5</attribute>
  |             <name>statefulClustered</name>
  |             <!-- So default region would never timeout -->
  |             <region name="/_default_">
  |                <attribute name="maxNodes">0</attribute>
  |                <attribute name="timeToIdleSeconds">0</attribute>
  |             </region>
  | 
  |          </config>
  |       </attribute>
  | 
  |       <!-- Store passivated sessions to the file system -->
  |       <attribute name="CacheLoaderConfiguration">
  |           <config>
  |               
  |               <passivation>true</passivation>
  |               <shared>false</shared>
  | 
  |               <cacheloader>
  |                   <class>org.jboss.cache.loader.FileCacheLoader</class>
  |                   <!-- Passivate to the server data dir -->
  |                   <properties>
  |                        location=${jboss.server.data.dir}${/}seratelbeCache 
  |                   </properties>
  |                   <async>false</async>
  |                   <fetchPersistentState>true</fetchPersistentState>
  |                   <ignoreModifications>false</ignoreModifications>
  |               </cacheloader>
  | 
  |           </config>
  |       </attribute>
  |    </mbean>
  | 
  | </server>
  | 

I copied this config file from SFSB config file and I'm wondering If I missed some nuances on setup.

Code putting data on the node1 is like so

cache.put("/a/b/c", "name", "Ben");
cache.put("/a/b/c/d", "uid", new Integer(322649));

Any pointers on proceeding forward on troubleshooting this would be great.

Thanks
Kumar

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4129258#4129258

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4129258



More information about the jboss-user mailing list