Project:
| View Issue Details[ Jump to Notes ] | [ Issue History ] [ Print ] | |||||||
| ID | ||||||||
| 0034189 | ||||||||
| Type | Category | Severity | Reproducibility | Date Submitted | Last Update | |||
| backport | [Openbravo ERP] 04. Warehouse management | critical | always | 2016-07-01 14:25 | 2016-11-04 15:08 | |||
| Reporter | VictorVillar | View Status | public | |||||
| Assigned To | dmiguelez | |||||||
| Priority | immediate | Resolution | fixed | Fixed in Version | 3.0PR16Q4 | |||
| Status | closed | Fix in branch | Fixed in SCM revision | bbc17f33517b | ||||
| Projection | none | ETA | none | Target Version | 3.0PR16Q4 | |||
| OS | Any | Database | Any | Java version | ||||
| OS Version | Database version | Ant version | ||||||
| Product Version | SCM revision | |||||||
| Merge Request Status | ||||||||
| Review Assigned To | aferraz | |||||||
| OBNetwork customer | OBPS | |||||||
| Web browser | ||||||||
| Modules | Core | |||||||
| Support ticket | 42684 | |||||||
| Regression level | ||||||||
| Regression date | ||||||||
| Regression introduced in release | ||||||||
| Regression introduced by commit | ||||||||
| Triggers an Emergency Pack | No | |||||||
| Summary | 0034189: Bad performance Costing Background process using 3 types of adjustments | |||||||
| Description | Bad performance Costing Background process using 3 types of adjustments | |||||||
| Steps To Reproduce | Bad performance Costing Background process using 3 types of adjustments: Backdated, Price Cost Correction, Negative Stock correction. This query is taking more than 1.5 seconds: 2016-07-01 04:21:54 CDT LOG: duration: 1699.337 ms execute S_18203/C_18204: select max(materialmg0_.MovementDate) as col_0_0_ from M_Transaction materialmg0_ where materialmg0_.IsCostCalculated='Y' and (materialmg0_.AD_Org_ID in ($1)) | |||||||
| Tags | No tags attached. | |||||||
| Attached Files | ||||||||
Relationships [ Relation Graph ]
[ Dependency Graph ]
|
||||||||
|
||||||||
Notes |
|
|
(0091141) hgbot (developer) 2016-11-03 21:04 |
Repository: erp/backports/3.0PR16Q4 Changeset: bbc17f33517b305885622b7b8db4880ee6934967 Author: David Miguelez <david.miguelez <at> openbravo.com> Date: Mon Sep 26 19:57:27 2016 +0200 URL: http://code.openbravo.com/erp/backports/3.0PR16Q4/rev/bbc17f33517b305885622b7b8db4880ee6934967 [^] Fixes issue 34189: Bad performance in Costing Background with all adjustments - Add M_TRANSACTION_TRXPROCDATE index same as M_TRANSACTION_MOVEMENTDATE - Modify M_TRANSACTION_CALCULATED index, by adding movementdate column in order to improve CostingUtils.getMaxTransactionDate query. - Add new M_LASTTRX table to store last transaction movementdate and improve CostAdjustmentUtils.isNeededBackdatedCostAdjustment query. --- M src-db/database/model/tables/M_TRANSACTION.xml M src-db/database/sourcedata/AD_COLUMN.xml M src-db/database/sourcedata/AD_TABLE.xml M src/org/openbravo/costing/CostAdjustmentUtils.java M src/org/openbravo/costing/CostingServer.java A src-db/database/model/tables/M_LASTTRX.xml --- |
|
(0091142) hgbot (developer) 2016-11-03 21:04 |
Repository: erp/backports/3.0PR16Q4 Changeset: 54b2c8a6fb7de0beb9568c2845c4ed03e8a59853 Author: Alvaro Ferraz <alvaro.ferraz <at> openbravo.com> Date: Tue Sep 27 12:38:06 2016 +0200 URL: http://code.openbravo.com/erp/backports/3.0PR16Q4/rev/54b2c8a6fb7de0beb9568c2845c4ed03e8a59853 [^] Related to issue 34189: Code review improvements - Remove unnecessary M_LASTTRX_PRODUCT_IDX and M_LASTTRX_WAREHOUSE_IDX indexes and create M_LASTTRX_PRODUCT_ORG_WH index with m_product_id, ad_org_id and m_warehouse_id columns. - Remove unnecessary M_TRX_CALCULATED_MOVEMENTDATE and M_TRX_CALCULATED_PRODUCT_DATES indexes. - Remove unneeded parameters in CostingServer.updateLastTransaction method, and make it private and non static. - Remove unnecessary flush() after calling to updateLastTransaction, as flush() is already done in finally statement. - Move getLastTransaction method from CostingServer to CostAdjustmentUtils class. - Remove unneeded startingDate parameter in CostAdjustmentUtils.getLastTransaction method. - Merge isBeforeLastTransaction and isAfterLastTransaction methods into CostAdjustmentUtils.compareToLastTransaction new method. --- M src-db/database/model/tables/M_LASTTRX.xml M src-db/database/model/tables/M_TRANSACTION.xml M src/org/openbravo/costing/CostAdjustmentUtils.java M src/org/openbravo/costing/CostingServer.java --- |
|
(0091143) hgbot (developer) 2016-11-03 21:04 |
Repository: erp/backports/3.0PR16Q4 Changeset: b88e19da46e56352ddaed61d829b2b18c76185f4 Author: Alvaro Ferraz <alvaro.ferraz <at> openbravo.com> Date: Tue Sep 27 19:29:56 2016 +0200 URL: http://code.openbravo.com/erp/backports/3.0PR16Q4/rev/b88e19da46e56352ddaed61d829b2b18c76185f4 [^] Related to issue 34189: Rename table from M_LASTTRX to M_TRANSACTION_LAST Rename table from M_LASTTRX to M_TRANSACTION_LAST and remove unneeded movementdate, trxprocessdate, movementtype and qty columns. --- M src-db/database/sourcedata/AD_COLUMN.xml M src-db/database/sourcedata/AD_TABLE.xml M src/org/openbravo/costing/CostAdjustmentUtils.java M src/org/openbravo/costing/CostingServer.java A src-db/database/model/tables/M_TRANSACTION_LAST.xml R src-db/database/model/tables/M_LASTTRX.xml --- |
|
(0091144) hgbot (developer) 2016-11-03 21:04 |
Repository: erp/backports/3.0PR16Q4 Changeset: 76260019ecff107eabbaf2fd8fae3aa2959cabe8 Author: Alvaro Ferraz <alvaro.ferraz <at> openbravo.com> Date: Tue Oct 11 18:50:35 2016 +0200 URL: http://code.openbravo.com/erp/backports/3.0PR16Q4/rev/76260019ecff107eabbaf2fd8fae3aa2959cabe8 [^] Related to issue 34189: Run Synchronize Terminology --- M src-db/database/sourcedata/AD_COLUMN.xml M src-db/database/sourcedata/AD_ELEMENT.xml M src/org/openbravo/costing/CostAdjustmentUtils.java M src/org/openbravo/costing/CostingServer.java --- |
|
(0091145) hgbot (developer) 2016-11-03 21:04 |
Repository: erp/backports/3.0PR16Q4 Changeset: fea7f984c0d3cb474bbff1146b066d9a45b4cc59 Author: Alvaro Ferraz <alvaro.ferraz <at> openbravo.com> Date: Tue Sep 27 19:34:57 2016 +0200 URL: http://code.openbravo.com/erp/backports/3.0PR16Q4/rev/fea7f984c0d3cb474bbff1146b066d9a45b4cc59 [^] Related to issue 34189: Delete TransactionLast when validating new Costing Rule Delete M_Transaction_Last when validating a new Costing Rule and exists a previous rule. --- M src/org/openbravo/costing/CostingRuleProcess.java --- |
|
(0091146) hgbot (developer) 2016-11-03 21:04 |
Repository: erp/backports/3.0PR16Q4 Changeset: 8fa93e685008c71034ceabcc2c1ecf5000c3fb6c Author: Alvaro Ferraz <alvaro.ferraz <at> openbravo.com> Date: Thu Nov 03 13:57:43 2016 +0100 URL: http://code.openbravo.com/erp/backports/3.0PR16Q4/rev/8fa93e685008c71034ceabcc2c1ecf5000c3fb6c [^] Related to issue 34189: Initialize TransactionLast table In case TransactionLast has not been initialized yet, it will be done by CostAdjustmentUtils.insertLastTransaction method when calling CostAdjustmentUtils.isNeededBackdatedCostAdjustment. --- M src/org/openbravo/costing/CostAdjustmentUtils.java --- |
|
(0091175) hgbot (developer) 2016-11-04 15:06 |
Repository: erp/backports/3.0PR16Q4 Changeset: 24a5506e9ba089a763b8b1e6cdebd1dbb479036b Author: Alvaro Ferraz <alvaro.ferraz <at> openbravo.com> Date: Fri Nov 04 14:33:35 2016 +0100 URL: http://code.openbravo.com/erp/backports/3.0PR16Q4/rev/24a5506e9ba089a763b8b1e6cdebd1dbb479036b [^] Related to issue 34189: Update last transaction before check cost adjustments --- M src/org/openbravo/costing/CostingServer.java --- |
|
(0091178) aferraz (viewer) 2016-11-04 15:08 |
Code review + Testing OK |
Issue History |
|||
| Date Modified | Username | Field | Change |
| 2016-10-11 18:24 | aferraz | Type | defect => backport |
| 2016-10-11 18:24 | aferraz | Target Version | 3.0PR17Q1 => 3.0PR16Q4 |
| 2016-11-03 21:04 | hgbot | Checkin | |
| 2016-11-03 21:04 | hgbot | Note Added: 0091141 | |
| 2016-11-03 21:04 | hgbot | Status | scheduled => resolved |
| 2016-11-03 21:04 | hgbot | Resolution | open => fixed |
| 2016-11-03 21:04 | hgbot | Fixed in SCM revision | => http://code.openbravo.com/erp/backports/3.0PR16Q4/rev/bbc17f33517b305885622b7b8db4880ee6934967 [^] |
| 2016-11-03 21:04 | hgbot | Checkin | |
| 2016-11-03 21:04 | hgbot | Note Added: 0091142 | |
| 2016-11-03 21:04 | hgbot | Checkin | |
| 2016-11-03 21:04 | hgbot | Note Added: 0091143 | |
| 2016-11-03 21:04 | hgbot | Checkin | |
| 2016-11-03 21:04 | hgbot | Note Added: 0091144 | |
| 2016-11-03 21:04 | hgbot | Checkin | |
| 2016-11-03 21:04 | hgbot | Note Added: 0091145 | |
| 2016-11-03 21:04 | hgbot | Checkin | |
| 2016-11-03 21:04 | hgbot | Note Added: 0091146 | |
| 2016-11-03 21:10 | aferraz | Review Assigned To | => aferraz |
| 2016-11-03 21:10 | aferraz | Note Added: 0091154 | |
| 2016-11-03 21:10 | aferraz | Status | resolved => closed |
| 2016-11-03 21:10 | aferraz | Fixed in Version | => 3.0PR16Q4 |
| 2016-11-04 15:06 | hgbot | Checkin | |
| 2016-11-04 15:06 | hgbot | Note Added: 0091175 | |
| 2016-11-04 15:08 | aferraz | Note Deleted: 0091154 | |
| 2016-11-04 15:08 | aferraz | Note Added: 0091178 | |
| Copyright © 2000 - 2009 MantisBT Group |