#h2 配置 spring: cache: type: ehcache ehcache: config: classpath:ehcache.xml jpa: generate-ddl: false show-sql: true hibernate: ddl-auto: none h2: console: path: /h2-console enabled: true settings: web-allow-others: true datasource: platform: h2 url: jdbc:h2:~/testjiscuss username: sa password: schema: classpath:schema.sql data: classpath:data.sql driver-class-name: org.h2.Driver type: com.alibaba.druid.pool.DruidDataSource druid: min-idle: 2 initial-size: 5 max-active: 10 max-wait: 5000 validation-query: select 1SS # 状态监控 filter: stat: enabled: true db-type: h2 log-slow-sql: true slow-sql-millis: 2000 # 监控过滤器 web-stat-filter: enabled: true exclusions: - "*.js" - "*.gif" - "*.jpg" - "*.png" - "*.css" - "*.ico" - "/druid/*" # druid 监控页面 stat-view-servlet: enabled: true url-pattern: /druid/* # reset-enable: false # login-username: root # login-password: root freemarker: # 设置模板后缀名 suffix: .ftl # 设置文档类型 content-type: text/html # 设置页面编码格式 charset: UTF-8 # 设置页面缓存 cache: false # 设置ftl文件路径 template-loader-path: - classpath:/templates settings: classic_compatible: true # 设置静态文件路径,js,css等 mvc: static-path-pattern: /static/** server: port: 80