forked from cloudfoundry/java-buildpack-auto-reconfiguration
/
test-grails-map-reference-good-context.xml
32 lines (26 loc) · 1.54 KB
/
test-grails-map-reference-good-context.xml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:context="http://www.springframework.org/schema/context"
xmlns:util="http://www.springframework.org/schema/util"
xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.0.xsd
http://www.springframework.org/schema/util http://www.springframework.org/schema/util/spring-util-2.5.xsd
http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-3.0.xsd">
<bean name="myDs" class="org.springframework.jdbc.datasource.DriverManagerDataSource">
<property name="url" value="jdbc:hsql:localdb" />
</bean>
<bean name="txAwareDXProxy" class="org.springframework.jdbc.datasource.TransactionAwareDataSourceProxy">
<property name="targetDataSource" ref="myDs"/>
</bean>
<bean id="sessionFactory" class="org.springframework.orm.hibernate3.LocalSessionFactoryBean" lazy-init="true">
<property name="dataSource" ref="myDs"/>
<property name="hibernateProperties" ref="hibernateProperties"/>
</bean>
<util:map id="hibernateProperties">
<entry key="hibernate.dialect" value="dialect.that.doesnt.exist.and.should.be.auto_replaced"/>
<entry key="hibernate.show_sql" value="true"/>
<entry key="hibernate.generate_statistics" value="false"/>
<!-- To avoid connecting to database during testing -->
<entry key="hibernate.temp.use_jdbc_metadata_defaults" value="false"/>
</util:map>
</beans>