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

View Issue DetailsJump to Notes ] Issue History ] Print ]
ID
0040215
TypeCategorySeverityReproducibilityDate SubmittedLast Update
defect[Modules] External Data Integrationminorhave not tried2019-02-15 11:472019-06-11 10:39
ReportercaristuView Statuspublic 
Assigned Tocaristu 
PriorityhighResolutionfixedFixed in Version
StatusclosedFix in branchFixed in SCM revision8c539d5ddeff
ProjectionnoneETAnoneTarget Version
OSAnyDatabaseAnyJava version
OS VersionDatabase versionAnt version
Product VersionSCM revision 
Regression date
Regression introduced by commit
Regression level
Review Assigned ToAugustoMauch
Regression introduced in release
Summary

0040215: An orphan import entry is left when the execution of a batch fails

DescriptionAn orphan import entry is left when the execution of a batch fails
Steps To Reproduce0a) Install the EDL examples module[1]
0b) Apply the attached patch. It will force the failure in the batch processing of the sample EDL process.
0c) Run ant smartbuild -Dlocal=no
1) Go to the [EDL Configuration] window and create a new configuration for the "UOM Import Process".
2) Run the [Import UOM Asynchronously] process.
3) Check the logs. Note that apart from the errors in the batch processing. There are some additional errors:

ERROR org.openbravo.service.importprocess.ImportEntryProcessor.ImportEntryProcessRunnable - null
java.lang.NullPointerException: null
    at org.openbravo.externaldata.integration.process.EDLImportEntryProcessor$EDLEntryProcessRunnable.shouldWaitForDependencies(EDLImportEntryProcessor.java:170) ~[classes/:?]
    at org.openbravo.externaldata.integration.process.EDLImportEntryProcessor$EDLEntryProcessRunnable.processEntry(EDLImportEntryProcessor.java:144) ~[classes/:?]
    at org.openbravo.service.importprocess.ImportEntryProcessor$ImportEntryProcessRunnable.doRunCycle(ImportEntryProcessor.java:376) [classes/:?]
    at org.openbravo.service.importprocess.ImportEntryProcessor$ImportEntryProcessRunnable.run(ImportEntryProcessor.java:297) [classes/:?]
    at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) [?:1.8.0_191]
    at java.util.concurrent.FutureTask.run(FutureTask.java:266) [?:1.8.0_191]
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [?:1.8.0_191]
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [?:1.8.0_191]
    at java.lang.Thread.run(Thread.java:748) [?:1.8.0_191]
2019-02-15 11:43:10,855 [Import Entry - 4] ERROR org.openbravo.service.importprocess.ImportEntryProcessor.ImportEntryProcessRunnable - null

This is because when the complete batch fails the original EDL request line is deleted, but not the associated ImportEntry (see attached image). Therefore when this ImportEntry is executed again by the ImportEntryManager it fails because it does not have any EDL related information.


[1] https://code.openbravo.com/erp/pmods/org.openbravo.externaldata.integration.examples [^]
TagsNo tags attached.
Attached Filesdiff file icon forceEDLError.diff [^] (367 bytes) 2019-02-15 14:42 [Show Content]
png file icon orphanImportEntries.png [^] (72,916 bytes) 2019-05-30 10:37

- Relationships Relation Graph ] Dependency Graph ]
related to defect 0036615 newplatform Error thrown when re-processing an EDL Request in asynchronous mode right after restarting tomcat 
related to defect 0048156 closedcaristu Error when reprocessing EDL 

-  Notes
(0112267)
hgbot (developer)
2019-05-30 13:34

Repository: erp/pmods/org.openbravo.externaldata.integration
Changeset: 8c539d5ddeff0de7d5c093ccda6cd53c97eb199b
Author: Carlos Aristu <carlos.aristu <at> openbravo.com>
Date: Thu May 30 13:33:13 2019 +0200
URL: http://code.openbravo.com/erp/pmods/org.openbravo.externaldata.integration/rev/8c539d5ddeff0de7d5c093ccda6cd53c97eb199b [^]

fixes bug 40215: Remove related import entry when request line is deleted

---
M src/org/openbravo/externaldata/integration/process/ProcessRequest.java
---
(0112268)
hgbot (developer)
2019-05-30 13:49

Repository: erp/pmods/org.openbravo.externaldata.integration
Changeset: 1462527e852069e4f3c9da5a139216dd01f727a5
Author: Carlos Aristu <carlos.aristu <at> openbravo.com>
Date: Thu May 30 13:48:41 2019 +0200
URL: http://code.openbravo.com/erp/pmods/org.openbravo.externaldata.integration/rev/1462527e852069e4f3c9da5a139216dd01f727a5 [^]

related to bug 40215: prevent NPE

  When trying to process import entries not related with any EDL request line, throw a controlled exception istead of a NPE

---
M src/org/openbravo/externaldata/integration/process/EDLImportEntryProcessor.java
---
(0112269)
hgbot (developer)
2019-05-30 13:52

Repository: erp/pmods/org.openbravo.externaldata.integration.examples
Changeset: 2319b3242ea47119540f8819d4c90d60ffd8ffa2
Author: Carlos Aristu <carlos.aristu <at> openbravo.com>
Date: Thu May 30 13:51:28 2019 +0200
URL: http://code.openbravo.com/erp/pmods/org.openbravo.externaldata.integration.examples/rev/2319b3242ea47119540f8819d4c90d60ffd8ffa2 [^]

related to bug 40215: assertion to ensure there aren't orphan import entries

---
M src-test/org/openbravo/externaldata/integration/examples/test/AddRequestTest.java
---
(0112568)
AugustoMauch (manager)
2019-06-11 10:39

Code reviewed and verified

- Issue History
Date Modified Username Field Change
2019-02-15 11:47 caristu New Issue
2019-02-15 11:47 caristu Assigned To => platform
2019-02-15 11:47 caristu Issue generated from 0040214
2019-02-15 14:42 caristu File Added: forceEDLError.diff
2019-02-15 14:43 caristu Steps to Reproduce Updated View Revisions
2019-03-28 10:56 caristu Relationship added related to 0036615
2019-05-30 09:14 caristu Steps to Reproduce Updated View Revisions
2019-05-30 09:18 caristu Proposed Solution updated
2019-05-30 09:18 caristu Assigned To platform => caristu
2019-05-30 10:35 caristu Steps to Reproduce Updated View Revisions
2019-05-30 10:37 caristu File Added: orphanImportEntries.png
2019-05-30 13:34 hgbot Checkin
2019-05-30 13:34 hgbot Note Added: 0112267
2019-05-30 13:34 hgbot Status new => resolved
2019-05-30 13:34 hgbot Resolution open => fixed
2019-05-30 13:34 hgbot Fixed in SCM revision => http://code.openbravo.com/erp/pmods/org.openbravo.externaldata.integration/rev/8c539d5ddeff0de7d5c093ccda6cd53c97eb199b [^]
2019-05-30 13:34 caristu Review Assigned To => AugustoMauch
2019-05-30 13:49 hgbot Checkin
2019-05-30 13:49 hgbot Note Added: 0112268
2019-05-30 13:52 hgbot Checkin
2019-05-30 13:52 hgbot Note Added: 0112269
2019-06-11 10:39 AugustoMauch Note Added: 0112568
2019-06-11 10:39 AugustoMauch Status resolved => closed
2021-11-25 10:58 caristu Relationship added related to 0048156


Copyright © 2000 - 2009 MantisBT Group
Powered by Mantis Bugtracker