I use log4j in my java application.
My log4j configuration file
Set root logger level.
log4j.rootLogger=WARN, logfile
log4j.appender.logfile.MaxFileSize=20MB backup file
log4j.appender.logfile.MaxBackupIndex=2
log4j.appender.logfile=org.apache.log4j.RollingFileAppender
log4j.appender.logfile.File=${log.output.file}
log4j.appender.logfile.layout=org.apache.log4j.PatternLayout
log4j.appender.logfile.layout.ConversionPattern=%-5p %d [%t] %c{2}: %m%n
log.output.File refers to the logging File.
I run multiple threads in a program that writes logging entries periodically to the output File. If I manually open the file and edit the contents of the file when the program is running .log4j stops logging. I dont want the logging to stop; I am new to Log4j.