引入依赖
我本地用的是 springboot 2 的版本,引用的 ShardingSphere-JDBC 的5.0.0-beta
版本
<dependency>
<groupId>org.apache.shardingsphere</groupId>
<artifactId>shardingsphere-jdbc-core-spring-boot-starter</artifactId>
<version>5.0.0-beta</version>
</dependency>
修改配置文件
spring:
profiles:
include: common