improve batch job exception logging to improve failure analysis
---------------------------------------------------------------
Key: MIFOS-2695
URL: http://mifosforge.jira.com/browse/MIFOS-2695
Project: mifos
Issue Type: Improvement
Components: Batch jobs
Reporter: Adam Monsen
Batch jobs often swallow exceptions, obscuring what failed and why. For
example, here's an exception from SavingsIntCalcHelper (as reported in
MIFOSADMIN-16):
--------------------------8<--------------------------
2010-02-07/00:01:47.263/PHT ERROR, org.mifos.framework.components.batchjobs,
TaskHelper, perform, 202, SavingsIntCalcTask failed
org.mifos.framework.components.batchjobs.exceptions.BatchJobException: Failure
at
org.mifos.framework.components.batchjobs.helpers.SavingsIntCalcHelper.execute(SavingsIntCalcHelper.java:67)
at
org.mifos.framework.components.batchjobs.TaskHelper.perform(TaskHelper.java:199)
at
org.mifos.framework.components.batchjobs.TaskHelper.executeTask(TaskHelper.java:115)
at
org.mifos.framework.components.batchjobs.MifosTask.run(MifosTask.java:55)
at java.util.TimerThread.mainLoop(Timer.java:512)
at java.util.TimerThread.run(Timer.java:462)
-------------------------->8--------------------------
The exception points to a "Failure" somewhere in execute(), but the actual
stacktrace is swallowed in a catch() block and never logged.
Proposed:
* plan a
** log exception in catch() block
* plan b
** never use BatchJobException(String, List<String>)
* either way, test to make sure the change results in a readable application
log when these kinds of failures occur
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://mifosforge.jira.com/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
------------------------------------------------------------------------------
The Planet: dedicated and managed hosting, cloud storage, colocation
Stay online with enterprise data centers and the best network in the business
Choose flexible plans and management services without long-term contracts
Personal 24x7 support from experience hosting pros just a phone call away.
http://p.sf.net/sfu/theplanet-com
_______________________________________________
Mifos-issues mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/mifos-issues