Anonymous | Login
Project:
RSS
  
News | My View | View Issues | Roadmap | Summary

View Issue DetailsJump to Notes ] Issue History ] Print ]
ID
0034010
TypeCategorySeverityReproducibilityDate SubmittedLast Update
backport[Openbravo ERP] I. Performanceminorhave not tried2016-09-14 13:292016-09-19 11:27
ReportergorkaionView Statuspublic 
Assigned Togorkaion 
PrioritynormalResolutionfixedFixed in Version3.0PR16Q3.2
StatusclosedFix in branchFixed in SCM revisionf3f2391a1346
ProjectionnoneETAnoneTarget Version3.0PR16Q3.2
OSAnyDatabasePostgreSQLJava version
OS VersionDatabase version9.4Ant version
Product VersionSCM revision 
Review Assigned Toaferraz
Web browser
ModulesCore
Regression level
Regression date
Regression introduced in release
Regression introduced by commit
Triggers an Emergency PackNo
Summary

0034010: Slow login loading organization's default ledgers

DescriptionOn a system with +200 organizations the login can take more than 2 seconds. In particular OBLedgerUtils.getOrgLedgerRecursive() method's query takes more 1.5 seconds.
Steps To ReproduceOn a system with +200 organizations try to login.
Check that the mentioned method takes too much time by adding some logs or measuring it with YourKit.
Proposed Solutionremove the query that filters and order by slow ad_isorgincluded procedure
TagsNo tags attached.
Attached Files

- Relationships Relation Graph ] Dependency Graph ]
blocks defect 0033989 closedgorkaion Slow login loading organization's default ledgers 

-  Notes
(0090052)
hgbot (developer)
2016-09-19 11:24

Repository: erp/backports/3.0PR16Q3.2
Changeset: f3f2391a134630de1f41b801330071d4efa2daf3
Author: Gorka Ion Damián <gorkaion.damian <at> openbravo.com>
Date: Wed Sep 14 13:39:12 2016 +0200
URL: http://code.openbravo.com/erp/backports/3.0PR16Q3.2/rev/f3f2391a134630de1f41b801330071d4efa2daf3 [^]

Fixed issue 34010. Removed slow query getting Organization Ledger.

The method to get the default General Ledget was using a query that filtered
and sorted the results using ad_isorgincluded procedure. In case of having a
large number of organizations this query was slow.

The method is now using the OrganizationStructureProvider to get the parent
organization List of the required org to search the default General Ledger.

---
M src/org/openbravo/erpCommon/utility/OBLedgerUtils.java
---
(0090053)
hgbot (developer)
2016-09-19 11:24

Repository: erp/backports/3.0PR16Q3.2
Changeset: 58c8fdd8d3d0666c11fb52b83bd6d2a77c9b1455
Author: Alvaro Ferraz <alvaro.ferraz <at> openbravo.com>
Date: Mon Sep 19 11:14:46 2016 +0200
URL: http://code.openbravo.com/erp/backports/3.0PR16Q3.2/rev/58c8fdd8d3d0666c11fb52b83bd6d2a77c9b1455 [^]

Related to issue 34010: Code review improvements

- Avoid setting admin mode in getOrgLedgerRecursive() and getClientLedger() methods as it is already done in getOrgLedger() method in OBLedgerUtils class.
- Retrieve first, general ledger of login organization in LoginUtils class. If no result is retrieved, we will retrieve general ledger of rest of context organizations.

---
M src/org/openbravo/base/secureApp/LoginUtils.java
M src/org/openbravo/erpCommon/utility/OBLedgerUtils.java
---
(0090055)
aferraz (manager)
2016-09-19 11:27

Code review + Testing OK

- Issue History
Date Modified Username Field Change
2016-09-16 10:38 aferraz Type defect => backport
2016-09-16 10:38 aferraz Target Version => 3.0PR16Q3.2
2016-09-19 11:24 hgbot Checkin
2016-09-19 11:24 hgbot Note Added: 0090052
2016-09-19 11:24 hgbot Status scheduled => resolved
2016-09-19 11:24 hgbot Resolution open => fixed
2016-09-19 11:24 hgbot Fixed in SCM revision => http://code.openbravo.com/erp/backports/3.0PR16Q3.2/rev/f3f2391a134630de1f41b801330071d4efa2daf3 [^]
2016-09-19 11:24 hgbot Checkin
2016-09-19 11:24 hgbot Note Added: 0090053
2016-09-19 11:27 aferraz Review Assigned To => aferraz
2016-09-19 11:27 aferraz Note Added: 0090055
2016-09-19 11:27 aferraz Status resolved => closed
2016-09-19 11:27 aferraz Fixed in Version => 3.0PR16Q3.2


Copyright © 2000 - 2009 MantisBT Group
Powered by Mantis Bugtracker