Watch 1 Star 2 Fork 0

youlixishi / demo-worldLGPL-2.1

Create your Gitee Account
Explore and code with more than 5 million developers,Free private repositories !:)
Sign up
http://demoworld.tech 中demo源代码 spread retract

Clone or download
mybatis-conf.xml 1.31 KB
Copy Edit Web IDE Raw Blame History
youlixishi authored 2017-06-25 17:40 . 添加多个数据源访问demo
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE configuration PUBLIC "-//mybatis.org//DTD Config 3.0//EN" "http://mybatis.org/dtd/mybatis-3-config.dtd">
<configuration>
<properties resource="jdbc.properties"></properties>
<environments default="User">
<environment id="User">
<transactionManager type="JDBC"/>
<dataSource type="POOLED">
<property name="driver" value="${user.jdbc.driverClassName}"/>
<property name="url" value="${user.jdbc.url}"/>
<property name="username" value="${user.jdbc.username}"/>
<property name="password" value="${user.jdbc.password}"/>
</dataSource>
</environment>
<environment id="Bank">
<transactionManager type="JDBC"/>
<dataSource type="POOLED">
<property name="driver" value="${bank.jdbc.driverClassName}"/>
<property name="url" value="${bank.jdbc.url}"/>
<property name="username" value="${bank.jdbc.username}"/>
<property name="password" value="${bank.jdbc.password}"/>
</dataSource>
</environment>
</environments>
<mappers>
<mapper resource="mappers/user.maper.xml"/>
<mapper resource="mappers/bank.mapper.xml"/>
</mappers>
</configuration>

Comment ( 0 )

Sign in for post a comment

1
https://git.oschina.net/youlixishi/demo-world.git
git@git.oschina.net:youlixishi/demo-world.git
youlixishi
demo-world
demo-world
master

Search