Openbravo Issue Tracking System - Retail Modules
View Issue Details
0052799Retail ModulesRetail APIpublic2023-06-20 15:172023-06-29 14:28
azzeddine_meftoh 
Triage Omni WMS 
urgentmajorhave not tried
newopen 
5
 
 
No
0052799: [RM-6914] Distribution order Import API - when error on import the remaining objects are not tried one by one
when importing Distribution orders through the API with a list of DO
if there i an error on one object the remaining objects are not moved to a new edl request line


Dev analysis : I see that this is a bug in the definition of the DistributionOrder entity mapping. It does not have any record marked as "Identifies Record Univocally" which is the mechanism used to check existing records

https://openbravo.atlassian.net/browse/RM-6914 [^]
import with Distribution order API a list of DO
make sure there are errors (such us undefined warehouse)
when the error occurs the object with the undefined warehouse is rejected.
but the remaining objects are not processed
This behavior is happening because the DO import process is internally committing the transaction at this point[1]. It would be feasible to avoid doing that commit at that point at least when importing DO through the API?

[1] https://gitlab.com/openbravo/product/pmods/org.openbravo.warehouse.advancedwarehouseoperations/-/blob/master/src/org/openbravo/warehouse/advancedwarehouseoperations/verbosity/AWOVerbosityLogger.java#L133 [^]
No tags attached.
txt CURL-DOi.txt (6,838) 2023-06-21 23:08
https://issues.openbravo.com/file_download.php?file_id=18680&type=bug
Issue History
2023-06-20 15:17azzeddine_meftohNew Issue
2023-06-20 15:17azzeddine_meftohAssigned To => Triage Platform Conn
2023-06-20 15:17azzeddine_meftohTriggers an Emergency Pack => No
2023-06-20 16:42rafarodaPrioritynormal => urgent
2023-06-20 17:23adrianromeroAssigned ToTriage Platform Conn => Triage Omni OMS
2023-06-20 17:38aferrazAssigned ToTriage Omni OMS => Triage Omni WMS
2023-06-21 23:08mtaalFile Added: CURL-DOi.txt
2023-06-21 23:47mtaalAssigned ToTriage Omni WMS => ruben_jimenez
2023-06-22 15:16caristuAssigned Toruben_jimenez => Triage Platform Base
2023-06-22 15:16caristuAssigned ToTriage Platform Base => Triage Platform Conn
2023-06-22 17:00caristuAssigned ToTriage Platform Conn => Triage Omni WMS
2023-06-22 17:01caristuProposed Solution updated
2023-06-22 17:01caristuProposed Solution updated
2023-06-26 10:41mtaalSummaryDistribution order Import API - when error on import the remaining objects are not tried one by one => [RM-6914] Distribution order Import API - when error on import the remaining objects are not tried one by one
2023-06-26 10:41mtaalDescription Updatedbug_revision_view_page.php?rev_id=26354#r26354
2023-06-29 14:28mtaalNote Added: 0151848
2023-06-29 14:28mtaalTypedefect => design defect

Notes
(0151848)
mtaal   
2023-06-29 14:28   
Snippet of email discussion:
what you have found is something incredibly deep in the core of the AWO Engine...
This is not something to change as the implications are quite important for all customers using AWO.

Thinking about importing DOs and the flow of generating tasks afterwards (which is the reason for this flush),
changing it would also require significant effort and some redefinition of it.

So this is something that has no easy fix from either side and it is a topic to discuss with more time and think carefully.
I will discuss first with Azzeddine and Rafa and then we can have a meeting later on to sync up and think about the possible options.