c92090539ee40b1f12d5cd880bf6c5f2aa076817
[utils] / system / spring / src / main / resources / spring / test.org.wamblee.security.database.xml
1 <?xml version="1.0" encoding="UTF-8"?>
2 <!DOCTYPE beans PUBLIC "-//SPRING//DTD BEAN//EN" "http://www.springframework.org/dtd/spring-beans.dtd">
3
4 <!-- This is the Spring configuration to define the database-related stuff for the
5     all persistence tests.  -->
6 <beans>
7     
8     <bean id="sessionFactory" class="org.springframework.orm.hibernate3.LocalSessionFactoryBean">
9         <property name="dataSource">
10             <ref bean="dataSource"/>
11         </property>
12         <property name="hibernateProperties">
13             <props>
14                 <prop key="hibernate.dialect">${hibernate.dialect}</prop>
15                 <prop key="hibernate.cache.provider_class">${hibernate.cache.provider}</prop>
16                 <prop key="hibernate.show_sql">${hibernate.show_sql}</prop>
17                 <prop key="hibernate.cache.use_query_cache">${hibernate.cache.use_query_cache}</prop>
18             </props>
19         </property>
20         <property name="schemaUpdate">
21             <value>${hibernate.schemaupdate}</value>
22         </property>
23         <property name="mappingResources"><ref bean="hibernateMappingFiles"/></property>
24     </bean>
25     
26     <bean id="transactionManager"
27         class="org.springframework.orm.hibernate3.HibernateTransactionManager">
28         <property name="sessionFactory">
29             <ref local="sessionFactory"/>
30         </property>
31     </bean>
32     
33     <!--  Hibernate template used within test code for addition 
34             Hibernate-specific stuff -->
35     <bean id="org.springframework.orm.hibernate3.HibernateTemplate" 
36         class="org.springframework.orm.hibernate3.HibernateTemplate">
37         <property name="sessionFactory">
38             <ref bean="sessionFactory"/>
39         </property>
40     </bean>
41 </beans>