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

View Issue DetailsJump to Notes ] Issue History ] Print ]
ID
0031772
TypeCategorySeverityReproducibilityDate SubmittedLast Update
defect[Openbravo ERP] 04. Warehouse managementmajoralways2015-12-24 10:162016-07-20 11:34
ReporterVictorVillarView Statuspublic 
Assigned Toaferraz 
PriorityimmediateResolutionfixedFixed in Version3.0PR16Q2
StatusclosedFix in branchFixed in SCM revision4e9e547d8199
ProjectionnoneETAnoneTarget Version3.0PR16Q2
OSAnyDatabaseAnyJava version
OS VersionDatabase versionAnt version
Product VersionSCM revision 
Review Assigned Todmiguelez
Web browser
ModulesCore
Regression level
Regression date
Regression introduced in release
Regression introduced by commit
Triggers an Emergency PackNo
Summary

0031772: Performance problem when you try to validate the costing rule with high volume of data

DescriptionPerformance problem when you try to validate the costing rule with high volume of data. Around 6000000 transactions
Steps To ReproduceTry to validate the Costing Rule defining an starting date and having 6000000 warehouse transactions.

The process takes so long, more than 24 hours.
TagsNo tags attached.
Attached Files

- Relationships Relation Graph ] Dependency Graph ]
related to defect 00320123.0PR16Q2 closedaferraz Not possible to either validate a costing rule or create an inventory amount update under some circumstancies 
depends on defect 00320363.0PR16Q2 closedaferraz API Change Request: Change m_transaction_trg to avoid execute m_update_inventory when costing related columns are updated 
related to defect 00334113.0PR17Q1 closeddmiguelez Bad performance Costing Background process using 3 types of adjustments 
related to defect 0036612 newTriage Omni WMS Improve performance of costing rule validation process 
causes defect 0033937 closedmarkmm82 Error in Costing Background Process if first costing rule validated with starting date,previous transactions cost not calculated 

-  Notes
(0084052)
hgbot (developer)
2016-02-09 12:41

Repository: erp/devel/pi
Changeset: 4e9e547d819903e9983b718935144d2c6db4c395
Author: Alvaro Ferraz <alvaro.ferraz <at> openbravo.com>
Date: Thu Jan 28 09:24:21 2016 +0100
URL: http://code.openbravo.com/erp/devel/pi/rev/4e9e547d819903e9983b718935144d2c6db4c395 [^]

Fixes issue 31772: Improve performance in Costing Rule validation

Update M_TRANSACTION_TRG to execute M_UPDATE_INVENTORY only when updated columns are not related to costing (like transactioncost, m_costing_algorithm_id, iscostcalculated, c_currency_id, costing_status, isprocessed, checkpricedifference, manualcostadjustment and iscostpermanent).
Update some methods in CostingRuleProcess and CostingRuleProcessOnProcessHandler to use query.uniqueResult() != null instead of query.count() > 0.
Update initializeOldTrx method in CostingRuleProcess to do an insert and an update in hql instead of doing a loop in java.
Change second loop in updateInventoriesCostAndProcessInitInventories method in CostingRuleProcess to use a scroll instead of looping over a list.
Use new getInventoryLineTransactions method in CostingRuleProcess instead of getInventoryLineTransaction method, which returns a scroll.
Use trx.getPhysicalInventoryLine().getRelatedInventory() instead of getInitIcl(cri.getInitInventory(), icl) in CostingRuleProcess.
Change updateInitInventoriesTrxDate method in CostingRuleProcess to do an update in hql instead of doing a loop in java.

---
M src-db/database/model/triggers/M_TRANSACTION_TRG.xml
M src/org/openbravo/costing/CostingMigrationProcess.java
M src/org/openbravo/costing/CostingRuleProcess.java
M src/org/openbravo/costing/CostingRuleProcessOnProcessHandler.java
---
(0084053)
dmiguelez (developer)
2016-02-09 12:42

Code Review + Testing Ok
(0085121)
hudsonbot (developer)
2016-03-17 10:56

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/b22fb0500156 [^]
Maturity status: Test

- Issue History
Date Modified Username Field Change
2015-12-24 10:16 VictorVillar New Issue
2015-12-24 10:16 VictorVillar Assigned To => Triage Finance
2015-12-24 10:16 VictorVillar Modules => Core
2015-12-24 10:16 VictorVillar Resolution time => 1421362800
2015-12-24 10:16 VictorVillar Triggers an Emergency Pack => No
2015-12-24 10:17 VictorVillar Issue Monitored: networkb
2015-12-28 12:56 VictorVillar Resolution time 1421362800 => 1452898800
2016-01-07 12:39 aferraz Assigned To Triage Finance => aferraz
2016-01-07 13:10 aferraz Status new => scheduled
2016-01-28 10:41 aferraz Relationship added depends on 0032036
2016-01-29 14:59 aferraz Relationship added related to 0032012
2016-02-09 12:41 hgbot Checkin
2016-02-09 12:41 hgbot Note Added: 0084052
2016-02-09 12:41 hgbot Status scheduled => resolved
2016-02-09 12:41 hgbot Resolution open => fixed
2016-02-09 12:41 hgbot Fixed in SCM revision => http://code.openbravo.com/erp/devel/pi/rev/4e9e547d819903e9983b718935144d2c6db4c395 [^]
2016-02-09 12:42 dmiguelez Review Assigned To => dmiguelez
2016-02-09 12:42 dmiguelez Note Added: 0084053
2016-02-09 12:42 dmiguelez Status resolved => closed
2016-03-17 10:56 hudsonbot Checkin
2016-03-17 10:56 hudsonbot Note Added: 0085121
2016-07-20 11:26 aferraz Relationship added related to 0033411
2016-07-20 11:34 aferraz Fixed in Version => 3.0PR16Q2
2016-09-12 18:56 aferraz Relationship added causes 0033937
2017-08-04 14:23 aferraz Relationship added related to 0036612


Copyright © 2000 - 2009 MantisBT Group
Powered by Mantis Bugtracker