Project:
View Issue Details[ Jump to Notes ] | [ Issue History ] [ Print ] | |||||||
ID | ||||||||
0038853 | ||||||||
Type | Category | Severity | Reproducibility | Date Submitted | Last Update | |||
defect | [Modules] Not Posted Transactions | major | always | 2018-06-28 10:00 | 2020-02-28 06:03 | |||
Reporter | egoitz | View Status | public | |||||
Assigned To | Sandrahuguet | |||||||
Priority | urgent | Resolution | fixed | Fixed in Version | ||||
Status | closed | Fix in branch | Fixed in SCM revision | bc5f285ab1ad | ||||
Projection | none | ETA | none | Target Version | ||||
OS | Any | Database | Any | Java version | ||||
OS Version | Database version | Ant version | ||||||
Product Version | SCM revision | |||||||
Regression date | ||||||||
Regression introduced by commit | ||||||||
Regression level | ||||||||
Review Assigned To | markmm82 | |||||||
Regression introduced in release | ||||||||
Summary | 0038853: Report not posted consume a lot of memory | |||||||
Description | The execution of the report not posted window produces a high memory usage if there are lot of records to show. That produces severe performance problems issues on the system ending consuming finally all the postgresql connections. | |||||||
Steps To Reproduce | Execute the report on an environment with big amount of data. The method retaining memory is: getGridData | |||||||
Proposed Solution | ** Use ScrollableResults instead of list() ** Set limit to the query fetching the records from active tables in Accounting Schema Tables. | |||||||
Tags | No tags attached. | |||||||
Attached Files | reportNOtposted.png [^] (46,596 bytes) 2018-06-28 10:00
| |||||||
Relationships [ Relation Graph ] [ Dependency Graph ] | |
Notes | |
(0105684) hgbot (developer) 2018-07-09 17:10 |
Repository: erp/mods/org.openbravo.financialmgmt.accounting.report.notposted Changeset: 8c17a25759e2a81720608ef43ea8490d05c74345 Author: Atul Gaware <atul.gaware <at> openbravo.com> Date: Mon Jul 09 19:06:38 2018 +0530 URL: http://code.openbravo.com/erp/mods/org.openbravo.financialmgmt.accounting.report.notposted/rev/8c17a25759e2a81720608ef43ea8490d05c74345 [^] Fixes Issue 38853:Report not posted consume a lot of memory ** Use ScrollableResults instead of list ** Set limit to query as endRow as every time query retreived all rows and when counter reached endRow, result was returned. ** Avoid list size() method, made use of IsEmpty() instead. --- M src/org/openbravo/financialmgmt/accounting/report/notposted/NotPostedDocumentsDataSource.java --- |
(0105685) hgbot (developer) 2018-07-09 17:10 |
Repository: erp/mods/org.openbravo.financialmgmt.accounting.report.notposted Changeset: 853f11444b1443020b6daceefb7712cafed1dd3b Author: Sandra Huguet <sandra.huguet <at> openbravo.com> Date: Mon Jul 09 17:10:32 2018 +0200 URL: http://code.openbravo.com/erp/mods/org.openbravo.financialmgmt.accounting.report.notposted/rev/853f11444b1443020b6daceefb7712cafed1dd3b [^] related to issue 38853 update module version --- M src-db/database/sourcedata/AD_MODULE.xml --- |
(0105686) Sandrahuguet (developer) 2018-07-09 17:18 |
Code review + testing OK |
(0105970) egoitz (manager) 2018-07-27 10:05 |
Ticket reopened as the problem is still reproducible. High memory usage when printing the reports. I saw that you added the scrollable but you are not doing a clear, so the memory usage will be the same but it the problem will appear later. |
(0106163) hgbot (developer) 2018-08-06 11:19 |
Repository: erp/mods/org.openbravo.financialmgmt.accounting.report.notposted Changeset: 8cee7c2afae4e707a638a561f388dff5b5b09ca4 Author: Atul Gaware <atul.gaware <at> openbravo.com> Date: Wed Aug 01 22:31:44 2018 +0530 URL: http://code.openbravo.com/erp/mods/org.openbravo.financialmgmt.accounting.report.notposted/rev/8cee7c2afae4e707a638a561f388dff5b5b09ca4 [^] Related to Issue 38853:Report not posted consume a lot of memory ** Use evict to detach object from session. --- M src/org/openbravo/financialmgmt/accounting/report/notposted/NotPostedDocumentsDataSource.java --- |
(0106164) Sandrahuguet (developer) 2018-08-06 11:20 |
Code review + testing OK |
(0107646) egoitz (manager) 2018-10-29 21:28 |
The issue is still reproducible after apply the patches |
(0107868) hgbot (developer) 2018-11-13 09:12 |
Repository: erp/mods/org.openbravo.financialmgmt.accounting.report.notposted Changeset: d6cf08d194bfcb9f72102178584bf12e851e6364 Author: Mark <markmm82 <at> gmail.com> Date: Fri Nov 09 00:39:13 2018 -0500 URL: http://code.openbravo.com/erp/mods/org.openbravo.financialmgmt.accounting.report.notposted/rev/d6cf08d194bfcb9f72102178584bf12e851e6364 [^] Related to issue 38853: Report not posted consume a lot of memory ** Always get the table to be processed by getting a new instance from the schemaTable ID. ** Extract to entityByTableName variable the value of ModelProvider.getInstance(). getEntityByTableName(table.getDBTableName()) to avoid call it more than once for the same table. ** Extract to entityHasDocumentTypeProperty the value of ModelProvider.getInstance(). getEntityByTableName(table.getDBTableName()).hasProperty("documentType") to avoid call it more than once for the same table. ** Extract to defaultDocumentTypeForTable variable the value of the default doctype of the processing table instead of get it every time when scroling the scrollable if the table hasn't document type property. ** Use evict to detach schemaTable object from session. ** Clear the session each 100 records in the scrollable. --- M src/org/openbravo/financialmgmt/accounting/report/notposted/NotPostedDocumentsDataSource.java --- |
(0107869) Sandrahuguet (developer) 2018-11-13 09:42 |
Code review + testing OK |
(0108683) hgbot (developer) 2018-12-20 09:10 |
Repository: erp/mods/org.openbravo.financialmgmt.accounting.report.notposted Changeset: bc5f285ab1addd14a52efb3b6653d3d2ac0ddec2 Author: Sandra Huguet <sandra.huguet <at> openbravo.com> Date: Thu Dec 20 09:10:00 2018 +0100 URL: http://code.openbravo.com/erp/mods/org.openbravo.financialmgmt.accounting.report.notposted/rev/bc5f285ab1addd14a52efb3b6653d3d2ac0ddec2 [^] fixed issue 38853 Report not posted consume a lot of memory **add a preference to limit the number of scrolls in the report **add pagination in document type combo --- M src/org/openbravo/financialmgmt/accounting/report/notposted/NotPostedDocumentsDataSource.java --- |
(0108714) hgbot (developer) 2018-12-21 08:35 |
Repository: erp/mods/org.openbravo.financialmgmt.accounting.report.notposted Changeset: 7535cff488c347d963625fde452517b15886b293 Author: Sandra Huguet <sandra.huguet <at> openbravo.com> Date: Fri Dec 21 08:35:09 2018 +0100 URL: http://code.openbravo.com/erp/mods/org.openbravo.financialmgmt.accounting.report.notposted/rev/7535cff488c347d963625fde452517b15886b293 [^] related to issue 38853 Fix eclipse warnings for CI *create a proper variable to the new scrollable --- M src/org/openbravo/financialmgmt/accounting/report/notposted/NotPostedDocumentsDataSource.java --- |
(0108758) hgbot (developer) 2018-12-27 04:13 |
Repository: erp/mods/org.openbravo.financialmgmt.accounting.report.notposted Changeset: 73625def499210331897282ad8708986ec354533 Author: Mark <markmm82 <at> gmail.com> Date: Wed Dec 26 10:51:26 2018 -0500 URL: http://code.openbravo.com/erp/mods/org.openbravo.financialmgmt.accounting.report.notposted/rev/73625def499210331897282ad8708986ec354533 [^] Related to issue 38853: Code review refactor Use the new log4j API. Use StringUtils.isEmpty to ask for empty strings Use StringBuilder to build HQL query. Removed the doctype variable and was added directly to the documentTypes --- M src/org/openbravo/financialmgmt/accounting/report/notposted/NotPostedDocumentsDataSource.java --- |
(0108759) markmm82 (developer) 2018-12-27 04:15 |
Code review + testing OK |
(0108826) hgbot (developer) 2019-01-04 09:08 |
Repository: erp/mods/org.openbravo.financialmgmt.accounting.report.notposted Changeset: 8cf7bc0f4e6387dcf5562aa1dfb9673ef7c26b9e Author: Sandra Huguet <sandra.huguet <at> openbravo.com> Date: Fri Jan 04 09:08:36 2019 +0100 URL: http://code.openbravo.com/erp/mods/org.openbravo.financialmgmt.accounting.report.notposted/rev/8cf7bc0f4e6387dcf5562aa1dfb9673ef7c26b9e [^] related to issue 38853 missing preference --- A src-db/database/sourcedata/AD_REF_LIST.xml --- |
Issue History | |||
Date Modified | Username | Field | Change |
2018-06-28 10:00 | egoitz | New Issue | |
2018-06-28 10:00 | egoitz | Assigned To | => Triage Finance |
2018-06-28 10:00 | egoitz | File Added: reportNOtposted.png | |
2018-06-28 10:00 | egoitz | Modules | => Core |
2018-06-28 10:00 | egoitz | Triggers an Emergency Pack | => No |
2018-06-28 10:01 | egoitz | Resolution time | => 1531951200 |
2018-06-28 10:09 | Sandrahuguet | Assigned To | Triage Finance => AtulOpenbravo |
2018-06-28 11:39 | martinsdan | Issue Monitored: martinsdan | |
2018-06-28 13:28 | Sandrahuguet | Project | Openbravo ERP => Modules |
2018-06-28 13:28 | Sandrahuguet | Category | 09. Financial management => Not Posted Transactions |
2018-07-01 20:34 | AtulOpenbravo | Status | new => scheduled |
2018-07-09 15:44 | AtulOpenbravo | Review Assigned To | => Sandrahuguet |
2018-07-09 15:44 | AtulOpenbravo | Proposed Solution updated | |
2018-07-09 17:10 | hgbot | Checkin | |
2018-07-09 17:10 | hgbot | Note Added: 0105684 | |
2018-07-09 17:10 | hgbot | Status | scheduled => resolved |
2018-07-09 17:10 | hgbot | Resolution | open => fixed |
2018-07-09 17:10 | hgbot | Fixed in SCM revision | => http://code.openbravo.com/erp/mods/org.openbravo.financialmgmt.accounting.report.notposted/rev/8c17a25759e2a81720608ef43ea8490d05c74345 [^] |
2018-07-09 17:10 | hgbot | Checkin | |
2018-07-09 17:10 | hgbot | Note Added: 0105685 | |
2018-07-09 17:18 | Sandrahuguet | Note Added: 0105686 | |
2018-07-09 17:18 | Sandrahuguet | Status | resolved => closed |
2018-07-27 10:05 | egoitz | Note Added: 0105970 | |
2018-07-27 10:05 | egoitz | Status | closed => new |
2018-07-27 10:05 | egoitz | Resolution | fixed => open |
2018-07-27 10:38 | ngarcia | Issue Monitored: ngarcia | |
2018-07-31 08:44 | AtulOpenbravo | Status | new => scheduled |
2018-08-06 11:19 | hgbot | Checkin | |
2018-08-06 11:19 | hgbot | Note Added: 0106163 | |
2018-08-06 11:20 | Sandrahuguet | Note Added: 0106164 | |
2018-08-06 11:20 | Sandrahuguet | Status | scheduled => resolved |
2018-08-06 11:20 | Sandrahuguet | Resolution | open => fixed |
2018-08-06 11:20 | Sandrahuguet | Status | resolved => closed |
2018-10-29 21:28 | egoitz | Note Added: 0107646 | |
2018-10-29 21:28 | egoitz | Status | closed => new |
2018-10-29 21:28 | egoitz | Resolution | fixed => open |
2018-11-05 14:29 | vmromanos | Status | new => scheduled |
2018-11-05 14:29 | vmromanos | Assigned To | AtulOpenbravo => markmm82 |
2018-11-13 09:12 | hgbot | Checkin | |
2018-11-13 09:12 | hgbot | Note Added: 0107868 | |
2018-11-13 09:41 | Sandrahuguet | Status | scheduled => resolved |
2018-11-13 09:41 | Sandrahuguet | Resolution | open => fixed |
2018-11-13 09:42 | Sandrahuguet | Note Added: 0107869 | |
2018-11-13 09:42 | Sandrahuguet | Status | resolved => closed |
2018-11-28 16:57 | egoitz | Assigned To | markmm82 => Sandrahuguet |
2018-11-28 16:57 | egoitz | Status | closed => new |
2018-11-28 16:57 | egoitz | Resolution | fixed => open |
2018-12-13 11:11 | Sandrahuguet | Status | new => scheduled |
2018-12-20 09:10 | hgbot | Checkin | |
2018-12-20 09:10 | hgbot | Note Added: 0108683 | |
2018-12-20 09:10 | hgbot | Status | scheduled => resolved |
2018-12-20 09:10 | hgbot | Resolution | open => fixed |
2018-12-20 09:10 | hgbot | Fixed in SCM revision | http://code.openbravo.com/erp/mods/org.openbravo.financialmgmt.accounting.report.notposted/rev/8c17a25759e2a81720608ef43ea8490d05c74345 [^] => http://code.openbravo.com/erp/mods/org.openbravo.financialmgmt.accounting.report.notposted/rev/bc5f285ab1addd14a52efb3b6653d3d2ac0ddec2 [^] |
2018-12-20 09:14 | Sandrahuguet | Review Assigned To | Sandrahuguet => markmm82 |
2018-12-21 08:35 | hgbot | Checkin | |
2018-12-21 08:35 | hgbot | Note Added: 0108714 | |
2018-12-27 04:13 | hgbot | Checkin | |
2018-12-27 04:13 | hgbot | Note Added: 0108758 | |
2018-12-27 04:15 | markmm82 | Note Added: 0108759 | |
2018-12-27 04:15 | markmm82 | Status | resolved => closed |
2019-01-04 09:08 | hgbot | Checkin | |
2019-01-04 09:08 | hgbot | Note Added: 0108826 | |
2020-02-28 06:03 | AtulOpenbravo | Issue cloned | 0043361 |
Copyright © 2000 - 2009 MantisBT Group |