Spring学习- 08 Druid数据源换成Hikari数据源(xml)
08.01 导入Hikari依赖(pom.xml)
导入HikariCP依赖
<dependency>
<groupId>com.zaxxer</groupId>
<artifactId>HikariCP</artifactId>
</dependency>
删除druid依赖
<dependency>
<groupId>com.alibaba</groupId>
<artifactId>druid</artifactId>
</dependency>
08.02 配置Datasource
-
删除druidDatasource配置(
resources\spring-context-druid.xml
) -
增加HikariDatasource(resources\spring-context-hikari.xml)
<?xml version="1.0" encoding="UTF-8"