ssm完整配置之application.yml(springboot、springmvc、mybatis plus、thymeleaf、druid、日志、分页插件、)

server:
  port: 8080

spring:
  datasource:
    url: jdbc:mysql://localhost:3306/hotel?serverTimezone=CTT&useUnicode=true&characterEncoding=utf-8&allowMultiQueries=true
    driver-class-name: com.mysql.cj.jdbc.Driver
    type: com.alibaba.druid.pool.DruidDataSource
    username: root
    password: 123456
  resources:
    static-locations: classpath:/templates/,classpath:/static/
  thymeleaf:
    cache: false

mybatis-plus:
  configuration:
    log-impl: org.apache.ibatis.logging.stdout.StdOutImpl
  mapper-locations: classpath:/mapper/*.xml
  type-aliases-package: 实体类包路径

#日志
logging:
  level:
    root: info
  file:
    name: demo.log
    path: logs

#PageHelper分页插件
pagehelper:
  # 分页插件会自动检测当前的数据库链接,自动选择合适的分页方式(可以不设置)
  helper-dialect: mysql
  # 上面数据库设置后,下面的设置为true不会改变上面的结果(默认为true)
  page-size-zero: true
  reasonable: true

  support-methods-arguments: true
  params: count=countSql

贴个文件结构图,免得大家搞错了!
在这里插入图片描述

  • 1
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 1
    评论
评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值