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

View Issue DetailsJump to Notes ] Issue History ] Print ]
ID
0025361
TypeCategorySeverityReproducibilityDate SubmittedLast Update
defect[Openbravo ERP] A. Platformtrivialalways2013-12-18 08:362013-12-22 05:46
ReporteralostaleView Statuspublic 
Assigned Toalostale 
PrioritynormalResolutionfixedFixed in Version3.0MP31
StatusclosedFix in branchFixed in SCM revision936ce44b74bd
ProjectionnoneETAnoneTarget Version
OSAnyDatabaseAnyJava version
OS VersionDatabase versionAnt version
Product VersionSCM revision 
Review Assigned Toshankarb
Web browser
ModulesCore
Regression level
Regression date
Regression introduced in release
Regression introduced by commit
Triggers an Emergency PackNo
Summary

0025361: Unneeded queries when filtering

DescriptionWhenever a filter on a foreign key is applied in a grid AD is queried to determine whether the identifier is composed by one or more columns.

This results in DB 3 queries (one to get column, one to get table and another one to get all columns in table) and in a loop over all columns in table.

Note these queries are repeated for each FK field that is used in the filter.
Steps To Reproduce-Enable HQL SQL loggging
-Go to (for example) Product window
-Filter by organization
  Check log, these queries are present:

  select ... from AD_Table ...
  select ... from AD_Column ...
  select ... from AD_Column ...
Proposed SolutionUse in memory model instead of querying DB
TagsPerformance
Attached Files

- Relationships Relation Graph ] Dependency Graph ]
related to defect 0020643 closedguilleaer fillters columns does not work when there are records with the character "-" 
related to defect 0036421 closedalostale Financial Account records are not filtered by name if the filter contains "-" 

-  Notes
(0062756)
hgbot (developer)
2013-12-18 08:41

Repository: erp/devel/pi
Changeset: 936ce44b74bd99462d5ffd2f7e35b376393e86de
Author: Asier Lostalé <asier.lostale <at> openbravo.com>
Date: Wed Dec 18 08:41:31 2013 +0100
URL: http://code.openbravo.com/erp/devel/pi/rev/936ce44b74bd99462d5ffd2f7e35b376393e86de [^]

fixed bug 25361: unneeded queries when filtering

  using in memory model instead of reading identifier info from AD

---
M modules/org.openbravo.service.json/src/org/openbravo/service/json/AdvancedQueryBuilder.java
---
(0062757)
alostale (manager)
2013-12-18 08:43

Performance improvement after the fix:

* For each FK field that participates in the filter:
  - Prevent 3 DB queries
  - Prevent loop on columns
    - Total time: 10-15ms for each field
(0062862)
hudsonbot (developer)
2013-12-19 12:32

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/b878bb51dc09 [^]

Maturity status: Test
(0063043)
shankarb (reporter)
2013-12-22 05:46

Code reviewed and tested in pi changeset a0194e74f446

- Issue History
Date Modified Username Field Change
2013-12-18 08:36 alostale New Issue
2013-12-18 08:36 alostale Assigned To => AugustoMauch
2013-12-18 08:36 alostale Modules => Core
2013-12-18 08:36 alostale Triggers an Emergency Pack => No
2013-12-18 08:36 alostale Assigned To AugustoMauch => alostale
2013-12-18 08:36 alostale Tag Attached: Performance
2013-12-18 08:37 alostale Description Updated View Revisions
2013-12-18 08:38 alostale Relationship added related to 0020643
2013-12-18 08:41 hgbot Checkin
2013-12-18 08:41 hgbot Note Added: 0062756
2013-12-18 08:41 hgbot Status new => resolved
2013-12-18 08:41 hgbot Resolution open => fixed
2013-12-18 08:41 hgbot Fixed in SCM revision => http://code.openbravo.com/erp/devel/pi/rev/936ce44b74bd99462d5ffd2f7e35b376393e86de [^]
2013-12-18 08:43 alostale Note Added: 0062757
2013-12-19 12:32 hudsonbot Checkin
2013-12-19 12:32 hudsonbot Note Added: 0062862
2013-12-20 07:42 alostale Review Assigned To => shankarb
2013-12-22 05:46 shankarb Note Added: 0063043
2013-12-22 05:46 shankarb Status resolved => closed
2013-12-22 05:46 shankarb Fixed in Version => 3.0MP31
2017-07-05 18:02 caristu Relationship added related to 0036421


Copyright © 2000 - 2009 MantisBT Group
Powered by Mantis Bugtracker