Openbravo Issue Tracking System - Openbravo ERP
View Issue Details
0028290Openbravo ERP02. Master data managementpublic2014-11-26 13:242015-03-03 16:09
caristu 
aferraz 
highminoralways
closedfixed 
5
pi 
3.0PR15Q2pi 
umartirena
Core
No
0028290: Performance problem in SL_TaxCategory_Org callout having a big amount of product categories
There is a performance problem in the SL_TaxCategory_Org callout when we have an environment with big amount of product categories.

In line 84 of this class, the list() method for a product category list is invoked to generate the values for the "Product Category" field:

for (final ProductCategory productCategory : productCatCrit.list()) {

Having this amount of product categories this can cause an OutOfMemoryError.
1) Having an environment with around 50000 product categories, go to the [Product] window
2) Create a new record. Notice that it takes so long to display the values in the user interface
3) If we configure tomcat with -Xmx1024M it could be not possible to create the record as the following exception is thrown: java.lang.OutOfMemoryError: GC overhead limit exceeded
Performance
Issue History
2014-11-26 13:24caristuNew Issue
2014-11-26 13:24caristuAssigned To => AtulOpenbravo
2014-11-26 13:24caristuModules => Core
2014-11-26 13:24caristuResolution time => 1423090800
2014-11-26 13:24caristuTriggers an Emergency Pack => No
2014-11-26 13:24caristuIssue Monitored: networkb
2014-11-26 13:24caristuTag Attached: Performance
2014-12-01 13:38egoitzTarget Version3.0PR15Q1 => 3.0PR15Q2
2014-12-08 21:08fsoto82Statusnew => scheduled
2014-12-08 21:08fsoto82Assigned ToAtulOpenbravo => fsoto82
2014-12-08 21:08fsoto82fix_in_branch => pi
2015-02-12 17:20aferrazAssigned Tofsoto82 => aferraz
2015-02-16 11:17aferrazNote Added: 0074502
2015-03-03 09:29hgbotCheckin
2015-03-03 09:29hgbotNote Added: 0075114
2015-03-03 09:29hgbotStatusscheduled => resolved
2015-03-03 09:29hgbotResolutionopen => fixed
2015-03-03 09:29hgbotFixed in SCM revision => http://code.openbravo.com/erp/devel/pi/rev/3b3d70f367a381a13b476a35e3592600f8c8adff [^]
2015-03-03 09:31umartirenaReview Assigned To => umartirena
2015-03-03 09:31umartirenaNote Added: 0075115
2015-03-03 09:31umartirenaStatusresolved => closed
2015-03-03 09:31umartirenaFixed in Version => pi
2015-03-03 16:09hudsonbotCheckin
2015-03-03 16:09hudsonbotNote Added: 0075127

Notes
(0074502)
aferraz   
2015-02-16 11:17   
- Having an environment with around 50000 product categories, go to the [Product] window
- Create a new record. Notice that it doesn't take long to display the values in the user interface
(0075114)
hgbot   
2015-03-03 09:29   
Repository: erp/devel/pi
Changeset: 3b3d70f367a381a13b476a35e3592600f8c8adff
Author: Alvaro Ferraz <alvaro.ferraz <at> openbravo.com>
Date: Mon Feb 16 12:05:59 2015 +0100
URL: http://code.openbravo.com/erp/devel/pi/rev/3b3d70f367a381a13b476a35e3592600f8c8adff [^]

Fixes issue 28290: Performance problem in SL_TaxCategory_Org callout

Changed SL_TaxCategory_Org, now executes a query against ProductCategory only one time instead of two times, retrieving only the one needed result

---
M src/org/openbravo/erpCommon/ad_callouts/SL_TaxCategory_Org.java
---
(0075115)
umartirena   
2015-03-03 09:31   
Code Review + Testing OK
(0075127)
hudsonbot   
2015-03-03 16:09   
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/f4fc528722d4 [^]
Maturity status: Test