SSM搭建

SSM搭建_第1张图片
SSM搭建_第2张图片

  • Artifact 名字必须小写* 不然报Artifact contains illegal characters
    SSM搭建_第3张图片
    SSM搭建_第4张图片
    SSM搭建_第5张图片
    SSM搭建_第6张图片
    SSM搭建_第7张图片
spring.datasource.password=123456
spring.datasource.url=jdbc:mysql://127.0.0.1:3306/house?useUnicode=true&characterEncoding=UTF-8&serverTimezone=Hongkong
spring.datasource.driver-class-name=com.mysql.cj.jdbc.Driver
mybatis.configuration.map-underscore-to-camel-case=true

SSM搭建_第8张图片

### \u8BBE\u7F6E###
# debug \u65E5\u5FD7\u7EA7\u522B\uFF0C\u5E38\u7528\u76844\u4E2A\u65E5\u5FD7\u7EA7\u522B\uFF1AERROR\u3001WARN\u3001 INFO\u3001DEBUG
log4j.rootLogger = DEBUG,stdout,D,E

### \u8F93\u51FA\u4FE1\u606F\u5230\u63A7\u5236\u62AC ###
log4j.appender.stdout = org.apache.log4j.ConsoleAppender
log4j.appender.stdout.Target = System.out
log4j.appender.stdout.layout = org.apache.log4j.PatternLayout
log4j.appender.stdout.layout.ConversionPattern = [%-5p] %d{yyyy-MM-dd HH:mm:ss,SSS} method:%l%n%m%n

### \u8F93\u51FADEBUG \u7EA7\u522B\u4EE5\u4E0A\u7684\u65E5\u5FD7\u5230=E://logs/error.log ###
log4j.appender.D = org.apache.log4j.DailyRollingFileAppender
log4j.appender.D.File = E://logs/log.log
log4j.appender.D.Append = true
log4j.appender.D.Threshold = DEBUG 
log4j.appender.D.layout = org.apache.log4j.PatternLayout
log4j.appender.D.layout.ConversionPattern = %-d{yyyy-MM-dd HH:mm:ss}  [ %t:%r ] - [ %p ]  %m%n

### \u8F93\u51FAERROR \u7EA7\u522B\u4EE5\u4E0A\u7684\u65E5\u5FD7\u5230=E://logs/error.log ###
log4j.appender.E = org.apache.log4j.DailyRollingFileAppender
log4j.appender.E.File =E://logs/error.log 
log4j.appender.E.Append = true
log4j.appender.E.Threshold = ERROR 
log4j.appender.E.layout = org.apache.log4j.PatternLayout
log4j.appender.E.layout.ConversionPattern = %-d{yyyy-MM-dd HH:mm:ss}  [ %t:%r ] - [ %p ]  %m%n

SSM搭建_第9张图片

你可能感兴趣的:(Java)