Hi guys, I wrote a test application to test passivation function with JDBCCacheLoader, the application is simple, two threads, the writer thread try to put 20 nodes into the cache and the reader thread do the read operation periodically. I only set maxNodes to be 10 and passivation to be true, so I was except that there should be only 10 nodes in the cache and the other 10 are in the database, I ran the test, before passivation every thing is correct, but after the passivation operation the reader threads can not read nothing, i checked the database found JBOSSCACHE.NODE column seems contain an empty object for the object passivated here, i did try to debug the cache, found when jbossCache try to passivate a node, the node data property is always NULL, i'm not sure what the problem it was, so can anybody help me? Thanks.
My cache configuration: <?xml version="1.0" encoding="UTF-8"?> | <jbosscache xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="urn:jboss:jbosscache-core:config:3.0"> | | <!-- Configure the TransactionManager --> | <transaction transactionManagerLookupClass="org.jboss.cache.transaction.GenericTransactionManagerLookup"/> | | <!-- Specific eviction policy configurations --> | <eviction wakeUpInterval="5000"> | <!-- Cache wide default --> | <default algorithmClass="org.jboss.cache.eviction.LRUAlgorithm" eventQueueSize="200000"> | <property name="maxNodes" value="5000" /> | <property name="timeToLive" value="3000" /> | </default> | <region name="/testRegion"> | <property name="maxNodes" value="10" /> | <property name="timeToLive" value="3000" /> | </region> | </eviction> | | <!-- Cache Passivation for Tree Cache | On passivation, The objects are written to the backend store on eviction if passivation | is true, otherwise the objects are persisted. On activation, the objects are restored in | the memory cache and removed from the cache loader if 'passivation' attribute is true, | otherwise the objects are only loaded from the cache loader --> | <loaders passivation="true" shared="false"> | <!-- if passivation is true, only the first cache loader is used; the rest are ignored --> | <loader | class="org.jboss.cache.loader.JDBCCacheLoader" | async="false" | fetchPersistentState="true" | ignoreModifications="false" | purgeOnStartup="false"> | <properties> | cache.jdbc.table.name=jbosscache | cache.jdbc.table.create=true | cache.jdbc.table.drop=true | cache.jdbc.table.primarykey=jbosscache_pk | cache.jdbc.fqn.column=fqn | cache.jdbc.fqn.type=varchar(255) | cache.jdbc.node.column=node | cache.jdbc.node.type=blob | cache.jdbc.parent.column=parent | cache.jdbc.sql-concat=1 || 2 | cache.jdbc.driver =oracle.jdbc.driver.OracleDriver | cache.jdbc.url=jdbc:oracle:thin:@15.154.146.115:1521:perf | cache.jdbc.user=malibu_ramon | cache.jdbc.password=malibu_ramon | </properties> | </loader> | </loaders> | </jbosscache> | View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4198538#4198538 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4198538 _______________________________________________ jboss-user mailing list jboss-user@lists.jboss.org https://lists.jboss.org/mailman/listinfo/jboss-user