GeeCON Prague 2014*
The moose likes Other Java Products and Servers and the fly likes Problem faced while logging through log4j Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


JavaRanch » Java Forums » Products » Other Java Products and Servers
Bookmark "Problem faced while logging through log4j" Watch "Problem faced while logging through log4j" New topic
Author

Problem faced while logging through log4j

ujjawal rohra
Ranch Hand

Joined: Mar 20, 2010
Posts: 105
Hi All

I have an application that uses log4j to log to a file. Now from this application I call a batch file which calls another application in a separate JVM and uses log4j with a separate root logger. The application being called through batch file logs normally in a file. The problem is that when an error occurs in this application(which is called through batch file) then no logging is done in its log file, that is logging hangs and when the main application which calls the batch file is stopped then the error messages and the rest messages are logged to this file. The ideal behavior should be that all messages whether they be error also should be logged to the log file without stopping the main application.

Can anyone suggest a solution or the reason of this ?

Thanks!!


SCJP 6
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Problem faced while logging through log4j