dcsimg
Issue with numbering of log files creation
0 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   Neetu_Rani
Posted On:   Wednesday, December 1, 2010 03:09 AM

Our Java application is using log4j-1.2.8.jar for creating logs. Although, logs are created with correct numbering order but on machine there numbering sometime is not proper. eg. AuthenticationModule.log AuthenticationModule.log.1 AuthenticationModule.log.3 AuthenticationModule.log.2 is missing.Following values are being used in log4j.properties file. log4j.appender.A1=org.apache.log4j.ConsoleAppender # A1 uses PatternLayout. log4j.appender.A1.layout=org.apache.log4j.PatternLayout log4j.appender.A1.layout.ConversionPattern=%-5p - %m %n # A2 is set to be a FileAppender. log4j.appender.   More>>

Our Java application is using log4j-1.2.8.jar for creating logs.


Although, logs are created with correct numbering order but on machine there numbering sometime is not proper. eg.


AuthenticationModule.log

AuthenticationModule.log.1

AuthenticationModule.log.3



AuthenticationModule.log.2 is missing.Following values are being used in log4j.properties file.



log4j.appender.A1=org.apache.log4j.ConsoleAppender

# A1 uses PatternLayout.

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

log4j.appender.A1.layout.ConversionPattern=%-5p - %m %n



# A2 is set to be a FileAppender.

log4j.appender.A2=org.apache.log4j.RollingFileAppender

log4j.appender.A2.MaxFileSize=5MB

log4j.appender.A2.MaxBackupIndex=10

log4j.appender.A2.File=..\Logs\AuthenticationModule.log

log4j.appender.A2.encoding=UTF-8



# A2 uses PatternLayout.

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

log4j.appender.A2.layout.ConversionPattern= <%d> %-5p [%C] - %m (%t)%n


# Validation log


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

log4j.appender.ADDRESS.layout.ConversionPattern= <%d> %m%n

log4j.appender.ADDRESS=org.apache.log4j.RollingFileAppender

log4j.appender.ADDRESS.MaxFileSize=1MB

log4j.appender.ADDRESS.MaxBackupIndex=5

log4j.appender.ADDRESS.File=..\Logs\validation.log

log4j.appender.ADDRESS.Threshold=INFO




Please guide what could be the reason behind incorrect numbering of log files?

   <<Less
About | Sitemap | Contact