I am using JBC 3.0. My config looks as below. I need to move the config to 
Spring because I have to use the connection pooling object from some other 
Spring config or if I cant use the connection pooling object I will have to get 
the Database connection stuff(server:port user password) from some other Spring 
config and be able to create the cache object. Does anybody have any example to 
show how to do that 


  | <?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">
  |   
  | 
  |       <locking isolationLevel="REPEATABLE_READ" 
lockParentForChildInsertRemove="true" lockAcquisitionTimeout="15000" 
nodeLockingScheme="mvcc"/>
  | 
  |             <eviction wakeUpInterval="60000">
  |           <!-- Cache wide default -->
  |           <default algorithmClass="org.jboss.cache.eviction.LRUAlgorithm" 
eventQueueSize="200000">
  |              <attribute name="maxNodes">5000</attribute>
  |              <attribute name="timeToLive">1000000</attribute>
  |           </default>
  |     
  |             <region name="/root/cache" 
algorithmClass="org.jboss.cache.eviction.LRUAlgorithm" eventQueueSize="200000">
  |                <attribute name="maxNodes">5</attribute>
  |                <attribute name="timeToLive">1000</attribute>
  |             </region>
  |    
  |             </eviction>
  |       <loaders passivation="false" shared="true">
  |           <!-- if passivation is true, only the first cache loader is used; 
the rest are ignored -->
  |           <loader class="org.jboss.cache.loader.JDBCCacheLoader" 
async="true" fetchPersistentState="true"
  |                   ignoreModifications="false" purgeOnStartup="false">
  |              <properties>
  |                       cache.jdbc.table.name=jboss_cache
  |                       cache.jdbc.table.create=false
  |                       cache.jdbc.table.drop=false
  |                       cache.jdbc.table.select=true
  |                       cache.jdbc.table.primarykey=cache_id
  |                       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.parent.type=varchar(255)
  |                       cache.jdbc.driver=com.mysql.jdbc.Driver
  |                       
cache.jdbc.url=jdbc:mysql://CACHEDATABASE:3333/jboss_cache
  |                       cache.jdbc.user=user
  |                       cache.jdbc.password=password
  |                       cache.jdbc.sql-concat=concat(1,2)
  |                
  |                               c3p0.maxIdleTime=60
  |                               c3p0.minPoolSize=0
  |                       c3p0.maxPoolSize=40
  |                       c3p0.checkoutTimeout=5000
  |                       
cache.jdbc.connection.factory=org.jboss.cache.loader.C3p0ConnectionFactory
  |                  
  |              </properties>
  |           </loader>
  |        </loaders>
  |     
  |  </jbosscache>
  | 

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

Reply to the post : 
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4197201
_______________________________________________
jboss-user mailing list
jboss-user@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/jboss-user

Reply via email to