1 Reply Latest reply on Aug 4, 2008 1:10 PM by manik

    treecache in hibernate takes too much cpu

    yangju

      We are running jboss 4.2GA and treecache that comes with it as a hibernate cache provider. The hibernate also comes with the default jboss 4.2GA.
      The following is the cache config (deployed as jboss mbean:

      <attribute name="CacheMode">LOCAL</attribute>
      <attribute name="IsolationLevel">REPEATABLE_READ</attribute>
       <attribute name="TransactionManagerLookupClass">org.jboss.cache.JBossTransactionManagerLookup</attribute>
       <attribute name="EvictionPolicyClass">org.jboss.cache.eviction.LRUPolicy</attribute>
       <attribute name="EvictionPolicyConfig">
       <config>
       <attribute name="wakeUpIntervalSeconds">60</attribute>
      
       <region name="/_default_">
       <!--0 means no limit -->
       <attribute name="maxNodes">0</attribute>
       <attribute name="timeToLiveSeconds">1800</attribute>
       <attribute name="maxAgeSeconds">1800</attribute>
       </region>


      The cpu keeps running on 95% level after we deploy our application. The load is actually not very high. And we keep getting the following messages:

      eviction node event queue size at 98% threadhold value of capacity: 200000. You will need...

      I don't understand why there are so many event triggered. I know our wakeUpIntervalSeconds is set as 1 minute which is a bit too long, but we never expected that hibernate or treecache would generate so many event.

      What can we do to solve this problem. Most of cache data are for read and we do not often update data.

      Thanks.