Openbravo Issue Tracking System - Retail Modules
View Issue Details
0042004Retail ModulesWeb POSpublic2019-10-14 12:182019-11-14 11:18
rafademiguel 
ranjith_qualiantech_com 
normalmajorsometimes
closedfixed 
5
 
RR20Q1 
marvintm
No
0042004: Populate table obretco_productcategory causes problems with high concurrency
Table obretco_productcategory is populated via ProductListEventHandler.java. This feature was implemented in Issue 30553 for High Volumes. 6 month ago the feature was implemented also to standard WebPOS (not only High Volumes).

The problem appears with high concurrency. For example in an Asynch EDL Process that inserts records in obretco_prol_product. The ProductListEventHandler checks if the product category of the product inserted in obretco_prol_product is present in obretco_productcategory and if it doesn't exists then insert the product category in the table obretco_productcategory for that assortment.

With high concurrency asynchronous processes (running in parallel) two (or more) executions identify the category as missing at the same time and try to insert it at the same time. First one success but subsequent ones produces an: ERROR: duplicate key value violates unique constraint "obretco_productcategory_un"
You need a process that insert records in obretco_prol_product in paralell with high concurrency. For example an EDL asynch process.

Then try to insert several products with a product category not present in the table obretco_productcategory for that assorment.
No tags attached.
caused by feature request 0030553RR15Q4 closed Sandrahuguet High volume products: make reading product categories more efficient 
Issue History
2019-10-14 12:18rafademiguelNew Issue
2019-10-14 12:18rafademiguelAssigned To => Retail
2019-10-14 12:18rafademiguelTriggers an Emergency Pack => No
2019-10-14 12:19rafademiguelRelationship addedcaused by 0030553
2019-10-14 12:24guillermogilResolution time => 1572822000
2019-10-30 15:19ranjith_qualiantech_comAssigned ToRetail => ranjith_qualiantech_com
2019-10-30 19:08ranjith_qualiantech_comStatusnew => scheduled
2019-11-08 13:13hgbotCheckin
2019-11-08 13:13hgbotNote Added: 0115478
2019-11-08 13:13hgbotStatusscheduled => resolved
2019-11-08 13:13hgbotResolutionopen => fixed
2019-11-08 13:13hgbotFixed in SCM revision => http://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/42c29a6aca5b046d753da006a66ddc89808b90ad [^]
2019-11-12 16:14marvintmReview Assigned To => marvintm
2019-11-12 16:14marvintmStatusresolved => closed
2019-11-12 16:14marvintmFixed in Version => RR20Q1
2019-11-14 09:47ranjith_qualiantech_comNote Added: 0115595
2019-11-14 09:47ranjith_qualiantech_comStatusclosed => new
2019-11-14 09:47ranjith_qualiantech_comResolutionfixed => open
2019-11-14 09:47ranjith_qualiantech_comFixed in VersionRR20Q1 =>
2019-11-14 09:47ranjith_qualiantech_comStatusnew => scheduled
2019-11-14 10:26hgbotCheckin
2019-11-14 10:26hgbotNote Added: 0115596
2019-11-14 10:26hgbotStatusscheduled => resolved
2019-11-14 10:26hgbotResolutionopen => fixed
2019-11-14 10:26hgbotFixed in SCM revisionhttp://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/42c29a6aca5b046d753da006a66ddc89808b90ad [^] => http://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/45c5ddcea929bbe59d9f61f7be1891cd0499ace2 [^]
2019-11-14 11:18marvintmStatusresolved => closed
2019-11-14 11:18marvintmFixed in Version => RR20Q1

Notes
(0115478)
hgbot   
2019-11-08 13:13   
Repository: erp/pmods/org.openbravo.retail.posterminal
Changeset: 42c29a6aca5b046d753da006a66ddc89808b90ad
Author: Ranjith S R <ranjith <at> qualiantech.com>
Date: Fri Nov 08 17:34:00 2019 +0530
URL: http://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/42c29a6aca5b046d753da006a66ddc89808b90ad [^]

Fixed issue 42004 : Assortment should be locked until Product Event Handler completes

---
M src/org/openbravo/retail/posterminal/event/ProductListEventHandler.java
---
(0115595)
ranjith_qualiantech_com   
2019-11-14 09:47   
Tests failing in https://ci.openbravo.com/job/mod-simple/46448/ [^]
(0115596)
hgbot   
2019-11-14 10:26   
Repository: erp/pmods/org.openbravo.retail.posterminal
Changeset: 45c5ddcea929bbe59d9f61f7be1891cd0499ace2
Author: Ranjith S R <ranjith <at> qualiantech.com>
Date: Thu Nov 14 14:55:53 2019 +0530
URL: http://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/45c5ddcea929bbe59d9f61f7be1891cd0499ace2 [^]

Fixed issue 42004 : Validating assortment before saving assortment product category

---
M src/org/openbravo/retail/posterminal/event/ProductListEventHandler.java
---