WARN No appenders could be found for logger (org.thymeleaf.TemplateEngine).
时间: 2023-09-27 14:08:17 浏览: 97
log4j.properties详解与例子
This warning message indicates that the Thymeleaf template engine was unable to find any configured logging appenders for its internal logging system. This means that any log messages generated by the template engine will not be outputted to any logging destinations.
To resolve this issue, you need to configure an appender for the logger in your logging framework (e.g. log4j, logback). You can do this by adding an appender configuration to your logging configuration file and specifying the appender class and destination (e.g. file, console).
Here is an example configuration for logback:
```
<configuration>
<appender name="console" class="ch.qos.logback.core.ConsoleAppender">
<encoder>
<pattern>%-4relative [%thread] %-5level %logger{35} - %msg%n</pattern>
</encoder>
</appender>
<logger name="org.thymeleaf.TemplateEngine" level="DEBUG">
<appender-ref ref="console" />
</logger>
</configuration>
```
This configuration sets up a console appender for the logger with the name "org.thymeleaf.TemplateEngine". Any log messages generated by this logger will be outputted to the console. You can customize the appender class and destination to suit your needs.
阅读全文