Openbravo Issue Tracking System - Openbravo ERP | ||||||||||||
View Issue Details | ||||||||||||
ID | Project | Category | View Status | Date Submitted | Last Update | |||||||
0024832 | Openbravo ERP | A. Platform | public | 2013-09-25 17:50 | 2013-10-21 10:19 | |||||||
Reporter | vmromanos | |||||||||||
Assigned To | shankarb | |||||||||||
Priority | urgent | Severity | major | Reproducibility | always | |||||||
Status | closed | Resolution | fixed | |||||||||
Platform | OS | 20 | OS Version | Debian 5.0 | ||||||||
Product Version | pi | |||||||||||
Target Version | 3.0MP29 | Fixed in Version | 3.0MP29 | |||||||||
Merge Request Status | ||||||||||||
Review Assigned To | AugustoMauch | |||||||||||
OBNetwork customer | No | |||||||||||
Web browser | ||||||||||||
Modules | Core | |||||||||||
Support ticket | ||||||||||||
Regression level | ||||||||||||
Regression date | ||||||||||||
Regression introduced in release | ||||||||||||
Regression introduced by commit | ||||||||||||
Triggers an Emergency Pack | No | |||||||||||
Summary | 0024832: EntityPersistenceEventObserver: cascade errors from ProcessBundle are not displayed | |||||||||||
Description | Inside an EntityPersistenceEventObserver run a Process through a ProcessBundle. If the process execution raises an exception, the EntityPersistenceEventObserver is unable to show it into the User Interface, and instead it shows the message: "Saving failed. org.openbravo.base.exception.OBException: No request object set" The cause is in the DalBaseProcess class. At the end of the finally the RequestContext is cleared: RequestContext.clear(); This sentence avoids the EntityPersistenceEventObserver to show the ProcessBundle real exception. | |||||||||||
Steps To Reproduce | Create an EntityPersistenceEventObserver for any entity. Run any Process using the ProcessBundle object inside the EntityPersistenceEventObserver, ensuring the execution raises an Exception. Simplified example: Inside the EntityPersistenceEventObserver: try { final ProcessBundle bundle = new ProcessBundle( SMT001_Constant.PROCESS_UPDATEINVOICEPLAN_CONTRACT_PROCESS_ID, vars) .init(new DalConnectionProvider(false)); bundle.getParams().put(SMT001_Constant.PROCESS_UPDATEINVOICEPLAN_CONTRACT_C_PROJECT_ID_PARAM, contract.getId()); final UpdateInvoicePlan updateInvoicePlanContractProcess = new UpdateInvoicePlan(); updateInvoicePlanContractProcess.setDoCommit(false); updateInvoicePlanContractProcess.execute(bundle); } catch (Exception e) { throw new OBException(e.getMessage()); } Inside the Process (in the example the UpdateInvoicePlan class): throw new OBException("@PriceListVersionNotFound@. @Product@: " + product.getIdentifier() + " @Date@: " + OBDateUtils.formatDate(date)); | |||||||||||
Proposed Solution | Remove the RequestContext.clear(); sentence at DalBaseProcess class | |||||||||||
Additional Information | ||||||||||||
Tags | No tags attached. | |||||||||||
Relationships |
| |||||||||||
Attached Files | ||||||||||||
Issue History | ||||||||||||
Date Modified | Username | Field | Change | |||||||||
2013-09-25 17:50 | vmromanos | New Issue | ||||||||||
2013-09-25 17:50 | vmromanos | Assigned To | => AugustoMauch | |||||||||
2013-09-25 17:50 | vmromanos | Modules | => Core | |||||||||
2013-09-25 17:50 | vmromanos | OBNetwork customer | => No | |||||||||
2013-09-25 17:50 | vmromanos | Triggers an Emergency Pack | => No | |||||||||
2013-09-25 17:51 | vmromanos | Relationship added | related to 0022235 | |||||||||
2013-09-26 07:57 | alostale | Target Version | 3.0MP28 => 3.0MP29 | |||||||||
2013-10-03 09:00 | shankarb | Assigned To | AugustoMauch => shankarb | |||||||||
2013-10-07 20:02 | mtaal | Note Added: 0061599 | ||||||||||
2013-10-14 19:29 | shankarb | Review Assigned To | => AugustoMauch | |||||||||
2013-10-14 19:30 | hgbot | Checkin | ||||||||||
2013-10-14 19:30 | hgbot | Note Added: 0061665 | ||||||||||
2013-10-14 19:30 | hgbot | Status | new => resolved | |||||||||
2013-10-14 19:30 | hgbot | Resolution | open => fixed | |||||||||
2013-10-14 19:30 | hgbot | Fixed in SCM revision | => http://code.openbravo.com/erp/devel/pi/rev/18f6233c80af03af357e5bdaa7e4d40d81f3fdb1 [^] | |||||||||
2013-10-16 19:47 | hudsonbot | Checkin | ||||||||||
2013-10-16 19:47 | hudsonbot | Note Added: 0061751 | ||||||||||
2013-10-21 10:19 | AugustoMauch | Note Added: 0061813 | ||||||||||
2013-10-21 10:19 | AugustoMauch | Status | resolved => closed | |||||||||
2013-10-21 10:19 | AugustoMauch | Fixed in Version | => 3.0MP29 |
Notes | |||||
|
|||||
|
|
||||
|
|||||
|
|
||||
|
|||||
|
|
||||
|
|||||
|
|