Hi All,
I am using a File Appender and I have used the following conversion pattern
in log4j.properties.
log4j.appender.fileAppender.layout.ConversionPattern=%d{dd-MM-yyyy hh:mm:ss
z} %p [%c.%M()]:%m%n
and in my Java class, I do the following to log an exception
try {
.
.
.
}
catch(Exception e){
log.error("Exception Caught : " + e);
}
And the output turns out to be
*22-06-2008 03:26:22 AST ERROR
[com.shci.shms.reception.spring.controller.TCIpdTransactionsController.getAdmitData()]:Exception
Caught in getIPDTransactionAdmitGridData() :
java.lang.NumberFormatException: null
*
*Prob*: I just get what the exception is but I dont get to see the complete
stack trace.
Is there any thing equivalent to e.printStackTrace() in log4j?
Thanks in Advance,
Tanuja