Spring Boot ignoring logback-spring.xml

前端 未结 6 490
慢半拍i
慢半拍i 2021-02-05 16:31

I have 2 Spring Boot (1.4.1-RELEASE) console applications using Logback. Both configuration files are more or less identical, are located in my /src/main/resources

6条回答
  •  广开言路
    2021-02-05 17:05

    I would specify in application.properties the location of the config file like that.

    logging.config=path
    

    Spring might not be looking for this file name. Spring doc

    They suggest using this name logback-spring.xml rather than just logback.xml

    I would place the configuration in application.properties if possible.

提交回复
热议问题