0 Replies Latest reply on Dec 8, 2006 3:46 PM by Carsten Rudat

    Configure JBoss/Hibernate to use JBossCache-TreeCache

    Carsten Rudat Novice

      Hi all,

      I've read some articles about configuring Hibernate to use JBossCache as 2nd level cache (e.g. http://wiki.jboss.org/wiki/Wiki.jsp?page=JBossCacheHibernate).

      I use now a JBoss 4.0.5.GA and "I think", I have a TreeCache now deployed as an MBean:

      <server>
       <mbean
       code="org.jboss.invocation.jrmp.server.JRMPProxyFactory"
       name="mydomain:service=proxyFactory,type=jrmp,target=factory">
       <attribute name="InvokerName">jboss:service=invoker,type=jrmp</attribute>
       <attribute name="TargetName">jboss.cache:service=TreeCache</attribute>
       <attribute name="JndiName">SystemCache</attribute>
       <attribute name="InvokeTargetMethod">true</attribute>
       <attribute name="ExportedInterface">org.jboss.cache.TreeCacheMBean</attribute>
       <attribute name="ClientInterceptors">
       <iterceptors>
       <interceptor>org.jboss.proxy.ClientMethodInterceptor</interceptor>
       <interceptor>org.jboss.proxy.SecurityInterceptor</interceptor>
       <interceptor>org.jboss.invocation.InvokerInterceptor</interceptor>
       </iterceptors>
       </attribute>
       <depends>jboss:service=invoker,type=jrmp</depends>
       <depends>jboss.cache:service=TreeCache</depends>
       </mbean>
      </server>
      


      and a configuration like

      http://labs.jboss.com/file-access/default/members/jbosscache/freezone/docs/1.4.0/TreeCache/en/html/configuration.html#d0e2066


      After all, I tried to set the
      hibernate.cache.provider_class=org.jboss.hibernate.cache.DeployedTreeCacheProvider
      configuration in persistence.properties file, but this doesn't work?!

      Is there any deeper configuraiotn tutorial or a preconfigurated xml-example?

      Thanks,

      Carsten[/url]