Project:
View Issue Details[ Jump to Notes ] | [ Issue History ] [ Print ] | |||||||
ID | ||||||||
0036172 | ||||||||
Type | Category | Severity | Reproducibility | Date Submitted | Last Update | |||
defect | [Openbravo ERP] A. Platform | major | have not tried | 2017-06-02 14:29 | 2017-09-21 16:49 | |||
Reporter | alostale | View Status | public | |||||
Assigned To | alostale | |||||||
Priority | urgent | Resolution | fixed | Fixed in Version | 3.0PR17Q4 | |||
Status | closed | Fix in branch | Fixed in SCM revision | 3ec690db55fe | ||||
Projection | none | ETA | none | Target Version | ||||
OS | Any | Database | Any | Java version | ||||
OS Version | Database version | Ant version | ||||||
Product Version | SCM revision | |||||||
Review Assigned To | caristu | |||||||
Web browser | ||||||||
Modules | Core | |||||||
Regression level | ||||||||
Regression date | ||||||||
Regression introduced in release | ||||||||
Regression introduced by commit | ||||||||
Triggers an Emergency Pack | No | |||||||
Summary | 0036172: WindowSettingsActionHandler underperformance | |||||||
Description | WindowSettingsActionHandler which is executed whenever a window is opened, has several performance problems from the code point of view: * Retrieving window from DB + DAL: using ADCS would prevent it * Querying one by one WindowAccessData.hasReadOnlyAccess all the tabs in the window, could be implemented in a single query * Getting preferences once and again * Review also PersonalizationHandler * For the window all ad_window_access rows are loaded in memory to iterate them and select only the current one. This is specially problematic having many roles. * When there are ad_tab_access, all fields in the tab are included in the response, but it should be possible, if properly handled in client, to include only the ones with a different setting than the tab access * ... | |||||||
Steps To Reproduce | 1.1. Check it in actual customers or 2.1 Execute attached scripts (for different cases): -case 0: clean sample data -case 1: ad_tab_access to current role for all tabs in product -case 2: case 1 + ad_field_access to current role for all fields in product -case 3: 10K roles with access to product window 2.2 Execute attached jmeter: which performs 200 synchronous requests to WSAH for Product window (as it has many tabs) | |||||||
Proposed Solution | Finally, not all fix candidates have been implemented as some of them were more risky and with current fix we've managed to get stable response times <40ms (for cases where originally were >400ms) regardless configuration settings [1]. Also a much better heap consumption has been achieved. --- [1] https://docs.google.com/spreadsheets/d/1p-KK0gEHj2QjIgKP6tpuPzJ3QW-5M3c9P6hwKVwu0GM/edit#gid=1009287793 [^] | |||||||
Tags | Performance | |||||||
Attached Files | WSAH-plan-config.sql [^] (4,851 bytes) 2017-07-27 12:12 wsah.jmx [^] (11,849 bytes) 2017-07-27 12:13 | |||||||
Relationships [ Relation Graph ] [ Dependency Graph ] | ||||||||||||||||||||||
|
Notes | |
(0098266) hgbot (developer) 2017-07-31 09:11 |
Repository: erp/devel/pi Changeset: 3ec690db55fe0b4bae71617d1775ffe165e63bd6 Author: Asier Lostalé <asier.lostale <at> openbravo.com> Date: Mon Jul 31 09:00:49 2017 +0200 URL: http://code.openbravo.com/erp/devel/pi/rev/3ec690db55fe0b4bae71617d1775ffe165e63bd6 [^] fixed bug 36172: WindowSettingsActionHandler underperformance Several changes in WindowSettingsActionHandler performance which improve both processing time and heap memory consumption: - Use ADCS to query window/tab definition in order to prevent DB queries - Optimized DAL queries so that only relevant records are queries from DB and loaded in memory --- M modules/org.openbravo.client.application/src/org/openbravo/client/application/WindowSettingsActionHandler.java M modules/org.openbravo.client.application/src/org/openbravo/client/application/window/ApplicationDictionaryCachedStructures.java --- |
(0098393) caristu (developer) 2017-08-04 13:20 |
Code reviewed + tested OK. |
(0099287) hudsonbot (developer) 2017-09-21 16:49 |
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/9750b78d3e5c [^] Maturity status: Test |
Issue History | |||
Date Modified | Username | Field | Change |
2017-06-02 14:29 | alostale | New Issue | |
2017-06-02 14:29 | alostale | Assigned To | => platform |
2017-06-02 14:29 | alostale | Modules | => Core |
2017-06-02 14:29 | alostale | Triggers an Emergency Pack | => No |
2017-06-02 14:29 | alostale | Tag Attached: Performance | |
2017-06-02 14:29 | alostale | Relationship added | related to 0035260 |
2017-06-02 14:30 | alostale | Relationship added | related to 0036066 |
2017-06-02 14:31 | alostale | Status | new => acknowledged |
2017-07-26 13:53 | alostale | File Added: windowSettingsAH.sql | |
2017-07-27 12:12 | alostale | File Deleted: windowSettingsAH.sql | |
2017-07-27 12:12 | alostale | File Added: WSAH-plan-config.sql | |
2017-07-27 12:13 | alostale | Assigned To | platform => alostale |
2017-07-27 12:13 | alostale | File Added: wsah.jmx | |
2017-07-27 12:16 | alostale | Relationship added | depends on 0034975 |
2017-07-27 12:23 | alostale | Review Assigned To | => caristu |
2017-07-27 12:23 | alostale | Steps to Reproduce Updated | View Revisions |
2017-07-27 12:23 | alostale | Proposed Solution updated | |
2017-07-27 12:24 | alostale | Proposed Solution updated | |
2017-07-31 09:11 | hgbot | Checkin | |
2017-07-31 09:11 | hgbot | Note Added: 0098266 | |
2017-07-31 09:11 | hgbot | Status | acknowledged => resolved |
2017-07-31 09:11 | hgbot | Resolution | open => fixed |
2017-07-31 09:11 | hgbot | Fixed in SCM revision | => http://code.openbravo.com/erp/devel/pi/rev/3ec690db55fe0b4bae71617d1775ffe165e63bd6 [^] |
2017-08-04 13:20 | caristu | Note Added: 0098393 | |
2017-08-04 13:20 | caristu | Status | resolved => closed |
2017-08-04 13:20 | caristu | Fixed in Version | => 3.0PR17Q4 |
2017-09-21 16:49 | hudsonbot | Checkin | |
2017-09-21 16:49 | hudsonbot | Note Added: 0099287 |
Copyright © 2000 - 2009 MantisBT Group |