1 <?xml version="1.0" encoding="UTF-8"?>
2 <!DOCTYPE beans PUBLIC "-//SPRING//DTD BEAN//EN" "http://www.springframework.org/dtd/spring-beans.dtd">
4 <!-- This is the Spring configuration to define the database-related stuff for the
5 all persistence tests. -->
8 <bean id="sessionFactory" class="org.springframework.orm.hibernate3.LocalSessionFactoryBean">
9 <property name="dataSource">
10 <ref bean="dataSource"/>
12 <property name="hibernateProperties">
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>
20 <property name="schemaUpdate">
21 <value>${hibernate.schemaupdate}</value>
23 <property name="mappingResources"><ref bean="hibernateMappingFiles"/></property>
26 <bean id="transactionManager"
27 class="org.springframework.orm.hibernate3.HibernateTransactionManager">
28 <property name="sessionFactory">
29 <ref local="sessionFactory"/>
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"/>