Openbravo Issue Tracking System - Openbravo ERP
View Issue Details
0037435Openbravo ERPA. Platformpublic2017-12-04 08:112018-01-03 12:39
alostale 
alostale 
normalminorhave not tried
closedfixed 
5
 
3.0PR18Q1 
caristu
Core
No
0037435: unneeded traces logged when exception occurs on background DalBaseProcess
When a background DalBaseProcess throws an exception two stack traces are logged in openbravo.log:

1. Stack trace for the actual exception, logged from DalBaseProcess
2. DalBaseProcess generates a new unrelated exception that is logged by DefaultJob
1. Make any background DalBaseProcess fail (ie. apply attached patch for Acct Server Process)
2. Run that process (ie. execute immediate Acct Server Process)
  -> See openbravo.log:

595dbc4c 980205 [DefaultQuartzScheduler_Worker-6] ERROR org.openbravo.service.db.DalBaseProcess - The process org.openbravo.erpCommon.ad_process.AcctServerProcess has thrown an exception.
java.lang.ArithmeticException: / by zero
    at org.openbravo.erpCommon.ad_process.AcctServerProcess.doExecute(AcctServerProcess.java:60)
    at org.openbravo.service.db.DalBaseProcess.execute(DalBaseProcess.java:83)
    at org.openbravo.scheduling.DefaultJob.execute(DefaultJob.java:63)
    at org.quartz.core.JobRunShell.run(JobRunShell.java:202)
    at org.quartz.simpl.SimpleThreadPool$WorkerThread.run(SimpleThreadPool.java:525)
595dbc4c 980205 [DefaultQuartzScheduler_Worker-6] ERROR org.openbravo.scheduling.DefaultJob - Error executing process org.openbravo.scheduling.ProcessBundle@11ac59e2
java.lang.Exception: / by zero
    at org.openbravo.service.db.DalBaseProcess.execute(DalBaseProcess.java:89)
    at org.openbravo.scheduling.DefaultJob.execute(DefaultJob.java:63)
    at org.quartz.core.JobRunShell.run(JobRunShell.java:202)
    at org.quartz.simpl.SimpleThreadPool$WorkerThread.run(SimpleThreadPool.java:525)
No tags attached.
blocks design defect 0036162 acknowledged Triage Platform Base clean up openbravo.log 
diff fail-process.diff (467) 2017-12-04 08:19
https://issues.openbravo.com/file_download.php?file_id=11352&type=bug
Issue History
2017-12-04 08:11alostaleNew Issue
2017-12-04 08:11alostaleAssigned To => platform
2017-12-04 08:11alostaleModules => Core
2017-12-04 08:11alostaleTriggers an Emergency Pack => No
2017-12-04 08:11alostaleAssigned Toplatform => alostale
2017-12-04 08:11alostaleReview Assigned To => caristu
2017-12-04 08:12alostaleRelationship addedblocks 0036162
2017-12-04 08:19alostaleFile Added: fail-process.diff
2017-12-04 08:25hgbotCheckin
2017-12-04 08:25hgbotNote Added: 0100909
2017-12-04 08:25hgbotStatusnew => resolved
2017-12-04 08:25hgbotResolutionopen => fixed
2017-12-04 08:25hgbotFixed in SCM revision => http://code.openbravo.com/erp/devel/pi/rev/3fed28edc82710cce1d80092ce304ef06e1964e7 [^]
2017-12-15 11:13caristuNote Added: 0101055
2017-12-15 11:13caristuStatusresolved => closed
2017-12-15 11:13caristuFixed in Version => 3.0PR18Q1
2018-01-03 12:39hudsonbotCheckin
2018-01-03 12:39hudsonbotNote Added: 0101513

Notes
(0100909)
hgbot   
2017-12-04 08:25   
Repository: erp/devel/pi
Changeset: 3fed28edc82710cce1d80092ce304ef06e1964e7
Author: Asier Lostalé <asier.lostale <at> openbravo.com>
Date: Mon Dec 04 08:24:04 2017 +0100
URL: http://code.openbravo.com/erp/devel/pi/rev/3fed28edc82710cce1d80092ce304ef06e1964e7 [^]

fixed bug 37435: unneeded log when exception thrown by DalBaseProcess

  When an exception was thrown by a background DalBaseProcess, 2 traces were logged.
  Once with the stack trace of the actual excpetion, another one with a the stack
  trace of a new unrelated generated exception.

  Now DalBaseProcess just rethrows original exception instead of logging it and
  creating a new one, DefaultJob logs it with its stack trace, it also prints a
  readable process name.

---
M src/org/openbravo/scheduling/DefaultJob.java
M src/org/openbravo/service/db/DalBaseProcess.java
---
(0101055)
caristu   
2017-12-15 11:13   
Code reviewed + tested OK.
(0101513)
hudsonbot   
2018-01-03 12:39   
A changeset related to this issue has been promoted main and to the
Central Repository, after passing a series of tests.

Promotion changeset: https://code.openbravo.com/erp/devel/main/rev/c81e0d3cbab5 [^]
Maturity status: Test