【异常】SpringBoot3.2.0 Description: Failed to configure a DataSource: ‘url‘ att

mybatisPlus 多数据源导致

异常

复制代码
Description:
 
Failed to configure a DataSource: 'url' attribute is not specified and no embedded datasource could be configured.
 
Reason: Failed to determine a suitable driver class
 
 
Action:
 
Consider the following:
	If you want an embedded database (H2, HSQL or Derby), please put it on the classpath.
	If you have database settings to be loaded from a particular profile you may need to activate it (the profiles dev are currently active).

解决

spring-boot 1.5.x 2.x.x

复制代码
<dependency>
  <groupId>com.baomidou</groupId>
  <artifactId>dynamic-datasource-spring-boot-starter</artifactId>
  <version>${version}</version>
</dependency>

spring-boot3 使用以下依赖

复制代码
<dependency>
  <groupId>com.baomidou</groupId>
  <artifactId>dynamic-datasource-spring-boot3-starter</artifactId>
  <version>${version}</version>
</dependency>
相关推荐
2401_824697666 分钟前
如何实现SQL存储过程状态监控_编写实时运行监控仪表盘
jvm·数据库·python
Mike117.8 分钟前
GBase 8c MOT 内存表落地前要先画清楚边界
服务器·数据库
iAm_Ike8 分钟前
c++怎么在写入文件流时通过peek预读功能实现复杂的逻辑判断【实战】
jvm·数据库·python
dFObBIMmai11 分钟前
mysql如何确保主从数据完全同步_开启半同步复制机制
jvm·数据库·python
2501_9307077824 分钟前
使用C#代码压平 PDF 表单字段
数据库·pdf·c#
m0_4708576432 分钟前
CSS如何实现Bootstrap进度条自定义动画_利用keyframe关键帧
jvm·数据库·python
treesforest35 分钟前
IP数据库下载完全指南:免费与商业IP定位库对比
网络·数据库·php
书语时38 分钟前
单体 MySQL 支撑业务的上限一般从哪里先触顶?如何论证瓶颈在 DB?
数据库·mysql
m0_6245785940 分钟前
SQL高效实现基于JOIN的交叉分析_多表关联实现多维统计
jvm·数据库·python
威联通网络存储41 分钟前
QNAP 闪存底座:制造企业 ERP 数据库容灾方案
数据库·python·制造