Answer the question
In order to leave comments, you need to log in
Logger does not work well. How to fix?
Greetings dear forum users.
I have such a problem. Connected Logger
<!-- SLF4J LOG4J 12 Binding -->
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-log4j12</artifactId>
<version>1.7.30</version>
</dependency>
<!-- Apache Log4j Core-->
<dependency>
<groupId>org.apache.logging.log4j</groupId>
<artifactId>log4j-core</artifactId>
<version>2.13.3</version>
</dependency>
# Root logger option
log4j.rootLogger=INFO, file, stdout
log4j.logger.org.springframework.jdbc.core = TRACE
log4j.logger.org.springframework.jdbc.core.JdbcTemplate = TRACE
# Direct log messages to a log file
log4j.appender.file=org.apache.log4j.RollingFileAppender
log4j.appender.file.File=D:\\Test\\logging.log
log4j.appender.file.MaxFileSize=10MB
log4j.appender.file.MaxBackupIndex=10
log4j.appender.file.layout=org.apache.log4j.PatternLayout
log4j.appender.file.layout.ConversionPattern=%d{yyyy-MM-dd HH:mm:ss} %-5p %c{1}:%L - %m%n
# Direct log messages to stdout
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=%d{yyyy-MM-dd HH:mm:ss} %-5p %c{1}:%L - %m%n
2020-10-18 07:08:32 INFO RepositoryConfigurationDelegate:127 - Bootstrapping Spring Data JPA repositories in DEFAULT mode.
2020-10-18 07:08:32 INFO RepositoryConfigurationDelegate:187 - Finished Spring Data repository scanning in 128ms. Found 1 JPA repository interfaces.
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question