my dog learned polymorphism*
The moose likes Other Open Source Projects and the fly likes Log4j Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Products » Other Open Source Projects
Bookmark "Log4j " Watch "Log4j " New topic
Author

Log4j

abhishek khandelwal
Greenhorn

Joined: Apr 17, 2007
Posts: 11
Hi Guys,

I seek your valuable help with regards to the implementation of Log4j in my application.

We have two different web applications deployed on single websphere application server cluster.
both have different log4j.properties file.

Here are their listing:

Property File for application 1
---------------------------------------------
log4j.rootLogger=DEBUG, ROOT

log4j.appender.ROOT=org.apache.log4j.RollingFileAppender

log4j.appender.ROOT.File=E:\\X\\ApplicationFramework.log

log4j.appender.ROOT.MaxFileSize=500KB

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

log4j.appender.ROOT.MaxBackupIndex=5

log4j.appender.ROOT.layout.ConversionPattern=[%d] %t %c %-5p - %m%n

Property File for application 2
---------------------------------------------
log4j.rootLogger=INFO, HELLO

log4j.appender.HELLO=org.apache.log4j.RollingFileAppender

log4j.appender.HELLO.File=E:\\Y\\Hello.log

log4j.appender.HELLO.MaxFileSize=10MB

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

log4j.appender.HELLO.MaxBackupIndex=5

log4j.appender.HELLO.layout.ConversionPattern=[%d] %t %c %-5p - %m%n

Problem: The log statements from Application 1 are being written to the Hello.log file.

Could you help me to figure out the problem?
Thanks in Advance!


Abhishek Khandelwal


Abhishek Khandelwal
SCPJ1.4, SCWCD1.4
Jaikiran Pai
Marshal

Joined: Jul 20, 2005
Posts: 9953
    
163

Did you check which log4j.properties file is being picked up by application1?


[My Blog] [JavaRanch Journal]
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Log4j
 
Similar Threads
problem in configure Log4j with chainsaw
Log4j to debug Struts
thread safe logging in a servlet
log4j file logging problem
problem in configure Log4j with chainsaw