How to configure logging in Play framework

#application.conf


# Log level

# ~~~~~

# Specify log level for your application.

# If you want a very customized log, create a log4j.properties file in the conf directory

application.log=INFO

# More logging configuration

application.log.path=/log4j.properties

application.log.system.out=on


#log4j.properties


log4j.rootLogger=INFO,A2

log4j.logger.play=INFO


log4j.appender.A2=org.apache.log4j.DailyRollingFileAppender

log4j.appender.A2.file=/logs/application.log

log4j.appender.A2.Append=true

log4j.appender.A2.layout=org.apache.log4j.PatternLayout

log4j.appender.A2.layout.ConversionPattern=%d [%t] %-5p %C{6} (%F:%L) - %m%n


你可能感兴趣的:(How to configure logging in Play framework)