Skip to content

Commit

Permalink
config: disable stdout logging
Browse files Browse the repository at this point in the history
  • Loading branch information
betarixm committed Dec 7, 2023
1 parent 925405d commit 0c6181d
Showing 1 changed file with 1 addition and 11 deletions.
12 changes: 1 addition & 11 deletions log4j2.properties
Original file line number Diff line number Diff line change
Expand Up @@ -4,22 +4,12 @@ status = warn
# Name of the configuration
name = ConsoleFileLogConfigDemo

# Console appender configuration
appender.console.type = Console
appender.console.name = consoleLogger
appender.console.layout.type = PatternLayout
appender.console.layout.pattern = %d{yyyy-MM-dd HH:mm:ss} %-5p %c{1}:%L - %m%n

# File appender configuration
appender.file.type = File
appender.file.name = fileLogger
appender.file.fileName = logs/app.log
appender.file.layout.type = PatternLayout
appender.file.layout.pattern = %d{yyyy-MM-dd HH:mm:ss} %-5p %c{1}:%L - %m%n

# Root logger level
rootLogger.level = info

# Root logger referring to both console and file appenders
rootLogger.appenderRef.stdout.ref = consoleLogger
# Root logger referring to both console and file appender
rootLogger.appenderRef.file.ref = fileLogger

0 comments on commit 0c6181d

Please sign in to comment.