可以在Application.yml统一配置,也可以在MybatisConfig中详细配置
# 配置DataSource
spring:
  datasource:
    #driver-class-name: com.mysql.jdbc.Driver
    url: jdbc:mysql://localhost:3306/springboot?useUnicode=true&characterEncoding=utf-8&serverTimezone=UTC
    username: root
    password: root
    type: com.alibaba.druid.pool.DruidDataSource
    initialSize: 5
    maxActive: 100
    minIdle: 3
    maxWait: 50000

 

springboot 属性设置

相关文章:

  • 2021-12-19
  • 2021-07-24
  • 2021-10-22
  • 2021-10-27
  • 2022-01-18
  • 2021-09-04
猜你喜欢
  • 2023-03-03
  • 2021-12-14
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-08-01
  • 2022-12-23
相关资源
相似解决方案