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

View Issue DetailsJump to Notes ] Issue History ] Print ]
ID
0017821
TypeCategorySeverityReproducibilityDate SubmittedLast Update
defect[Openbravo ERP] 01. General setupminoralways2011-06-29 14:482012-04-01 20:37
ReporterroklenardicView Statuspublic 
Assigned Toalostale 
PrioritynormalResolutionfixedFixed in Version
StatusclosedFix in branchpiFixed in SCM revision9644db90eb37
ProjectionnoneETAnoneTarget Version3.0MP10
OSAnyDatabaseAnyJava version
OS VersionDatabase versionAnt version
Product VersionpiSCM revision 
Review Assigned To
Web browserGoogle Chrome
ModulesCore
Regression level
Regression date
Regression introduced in release
Regression introduced by commit
Triggers an Emergency PackNo
Summary

0017821: Rearranging menu items takes abnormal amount of time

DescriptionRearranging menu items takes abnormal amount of time
Steps To Reproduce1) Switch to the System Admin role
2) create a template or check the Customizations Allowed checkbox
3) go to General setup || Application || Menu
4) move any item around

The time it takes for the success message to appear is really long and the user does not know what is going on. Often it happens they start moving another item around, potentially corrupting the menu structure.
TagsNo tags attached.
Attached Filespng file icon Selection_036.png [^] (8,284 bytes) 2012-03-01 12:05


png file icon Selection_037.png [^] (6,685 bytes) 2012-03-01 12:05


? file icon 17821.export [^] (1,323 bytes) 2012-03-01 12:35

- Relationships Relation Graph ] Dependency Graph ]

-  Notes
(0045658)
alostale (manager)
2012-03-01 12:09

The problem is WindowTree call is spending a lot of time (in attached Selection_036.png is 2.34s).

Concretely, the time consuming part is checking possible tree cycles by ad_parent_tree pl function.

This function exits recusivity only when exception occurs, the solution is not to wait for exception to occur but correctly exit by detecting the case that would raise exception.
(0045660)
alostale (manager)
2012-03-01 12:18

After applying the fix the time is reduced to 21ms.

There is no regression risk on this fix because it is changing the implementation of ad_parent_tree but returning the same result.

Test plan:

* To ensure the current result of ad_parent_tree is the same as it was before:
  -create a db function (ad_parent_tree_orig) as it was previously to the fix.
  -compare results of new and old function for all menu entries, the result of this query should be 0:
      select count(*)
        from (select node_id from ad_treenode where ad_tree_id ='10') a
       where ad_parent_tree('10', node_id) != ad_parent_tree_orig('10', node_id)
(0045662)
alostale (manager)
2012-03-01 12:35

Attached export as pi is currently frozen for mp9
(0046065)
hgbot (developer)
2012-03-06 08:45

Repository: erp/devel/pi
Changeset: 9644db90eb375b62a0680acf6ca8112471b80201
Author: Asier Lostalé <asier.lostale <at> openbravo.com>
Date: Thu Mar 01 12:34:27 2012 +0100
URL: http://code.openbravo.com/erp/devel/pi/rev/9644db90eb375b62a0680acf6ca8112471b80201 [^]

fixed bug 17821: Improved performance in ad_parent_tree function

Proper exit recursivity instead of waiting for an exception to be thrown

---
M src-db/database/model/functions/AD_PARENT_TREE.xml
---
(0047040)
hudsonbot (developer)
2012-04-01 20:37

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

Maturity status: Test

- Issue History
Date Modified Username Field Change
2011-06-29 14:48 roklenardic New Issue
2011-06-29 14:48 roklenardic Assigned To => dalsasua
2011-06-29 14:48 roklenardic Web browser => Google Chrome
2011-06-29 14:48 roklenardic Modules => Core
2011-07-20 18:09 dalsasua Assigned To dalsasua => jonalegriaesarte
2012-02-15 19:05 iciordia Assigned To jonalegriaesarte => vmromanos
2012-02-16 14:01 vmromanos Assigned To vmromanos => alostale
2012-02-29 13:19 malsasua Web browser Google Chrome => Google Chrome
2012-02-29 15:16 alostale Web browser Google Chrome => Google Chrome
2012-02-29 15:16 alostale Target Version => 3.0MP10
2012-02-29 15:16 alostale Status new => scheduled
2012-02-29 15:16 alostale fix_in_branch => pi
2012-03-01 12:05 alostale File Added: Selection_036.png
2012-03-01 12:05 alostale File Added: Selection_037.png
2012-03-01 12:09 alostale Note Added: 0045658
2012-03-01 12:18 alostale Note Added: 0045660
2012-03-01 12:35 alostale File Added: 17821.export
2012-03-01 12:35 alostale Note Added: 0045662
2012-03-06 08:45 hgbot Checkin
2012-03-06 08:45 hgbot Note Added: 0046065
2012-03-06 08:45 hgbot Status scheduled => resolved
2012-03-06 08:45 hgbot Resolution open => fixed
2012-03-06 08:45 hgbot Fixed in SCM revision => http://code.openbravo.com/erp/devel/pi/rev/9644db90eb375b62a0680acf6ca8112471b80201 [^]
2012-03-16 15:54 marvintm Status resolved => closed
2012-04-01 20:37 hudsonbot Checkin
2012-04-01 20:37 hudsonbot Note Added: 0047040


Copyright © 2000 - 2009 MantisBT Group
Powered by Mantis Bugtracker