#端口号
spring:
datasource:
#配置数据源你类型
type: com.zaxxer.hikari.HikariDataSource
driver-class-name: com.mysql.cj.jdbc.Driver
url: jdbc:mysql://localhost:3306/mybatisplus?serverTimezone=GMT%2B8&characterEncoding=utf-8&useSSL=true
username: root
password: 123456
#日志
mybatis-plus:
configuration:
log-impl: org.apache.ibatis.logging.stdout.StdOutImpl
#默认的mapper映射文件位置所在目录 mapper/
#mapper-locations: classpath:/mapper/UserMapper.xml
# type-aliases-package: com.powernode.mapper
#配置mybatisPlus的全局配置 表名
global-config:
db-config:
#设置实体类所对应的表的前缀
table-prefix: t_
#设置统一的主键生成策略
id-type: auto
#配置类型别名随对应的包
type-aliases-package: com/powernode/pojo
#用于扫面通用枚举的包
type-enums-package: com/powernode/enums
server:
port: 9091
yml文件配置
最新推荐文章于 2025-06-13 20:49:31 发布