Openbravo Issue Tracking System - Openbravo ERP
View Issue Details
0026664Openbravo ERPA. Platformpublic2014-05-22 14:522016-12-22 12:54
alostale 
alostale 
normalminorhave not tried
closedfixed 
5
 
3.0PR16Q4 
caristu
Core
No
0026664: Useless ConnectionProvider caching in ApplicationDictionaryCachedStructures
ApplicationDictionaryCachedStructures is caching DalConnectionProvider for ComboTableData, which retains DAl's StatefulPersintanceContext. Caching of DalConnectionProvider can be avoided. Reducing in this manner the total amount of memory retained per session.
* With no modules in development execute 4 times https://code.openbravo.com/erp/devel/pi-performance/file/274220fc729c/FICnewAllHeaderTabs.jmx [^] jMeter test case
* Obtain a JVM memory dump

See org.apache.catalina.session.StandardManager is retaining 4 org.apache.catalina.session.StandardSession instances having each of them org.hibernate.engine.StatefulPersistenceContext instances up to ~5MB each. These 20MB (4x5MB) are useless and could be not cached.
See attached patch. Though it requires to be properly tested, it apparently works.

Applying this patch these 20MB are reduced from retained memory.
Performance
related to defect 00244213.0MP28 closed alostale ApplicationDictionaryCachedStructures is not thread safe 
related to defect 0034813 closed alostale clean up ComboTableData unneeded cached pool 
diff conn-adcs.diff (876) 2014-05-22 14:54
https://issues.openbravo.com/file_download.php?file_id=6942&type=bug
Issue History
2014-05-22 14:52alostaleNew Issue
2014-05-22 14:52alostaleAssigned To => AugustoMauch
2014-05-22 14:52alostaleModules => Core
2014-05-22 14:52alostaleTriggers an Emergency Pack => No
2014-05-22 14:52alostaleTag Attached: Performance
2014-05-22 14:52alostaleRelationship addedrelated to 0024421
2014-05-22 14:54alostaleFile Added: conn-adcs.diff
2015-01-05 11:14shuehnerIssue Monitored: shuehner
2015-01-07 09:50alostaleTarget Version => 3.0PR15Q2
2015-02-24 17:18alostalePrioritynormal => urgent
2015-02-24 17:18alostaleStatusnew => acknowledged
2015-03-11 08:11alostaleTarget Version3.0PR15Q2 =>
2015-03-17 14:37alostaleAssigned ToAugustoMauch => platform
2015-11-11 11:37alostalePriorityurgent => normal
2016-07-14 15:44alostaleAssigned Toplatform => alostale
2016-07-14 15:45alostaleReview Assigned To => caristu
2016-07-14 15:45hgbotCheckin
2016-07-14 15:45hgbotNote Added: 0088490
2016-07-14 15:45hgbotStatusacknowledged => resolved
2016-07-14 15:45hgbotResolutionopen => fixed
2016-07-14 15:45hgbotFixed in SCM revision => http://code.openbravo.com/erp/devel/pi/rev/d0b7ee93f8e78e1e14df9f3539032b3b8458eb90 [^]
2016-07-26 09:32caristuNote Added: 0088658
2016-07-26 09:32caristuStatusresolved => closed
2016-07-26 09:32caristuFixed in Version => 3.0PR16Q4
2016-08-11 18:40hudsonbotCheckin
2016-08-11 18:40hudsonbotNote Added: 0089014
2016-12-22 12:54alostaleRelationship addedrelated to 0034813

Notes
(0088490)
hgbot   
2016-07-14 15:45   
Repository: erp/devel/pi
Changeset: d0b7ee93f8e78e1e14df9f3539032b3b8458eb90
Author: Asier Lostalé <asier.lostale <at> openbravo.com>
Date: Mon Jul 11 13:25:10 2016 +0200
URL: http://code.openbravo.com/erp/devel/pi/rev/d0b7ee93f8e78e1e14df9f3539032b3b8458eb90 [^]

fixed bug 26664: useless ConnectionProvider caching in ADCS

  ConnectionProvider was cached in ADCS through cached ComboTableData instances.

  This retained a significant amount of memory.

  Now it is not cached anymore and obtained from DAL connection when needed.

---
M src/org/openbravo/erpCommon/utility/ComboTableData.java
---
(0088658)
caristu   
2016-07-26 09:32   
Code reviewed
(0089014)
hudsonbot   
2016-08-11 18:40   
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/edaa05b1fb18 [^]
Maturity status: Test