Openbravo Issue Tracking System - Modules
View Issue Details
0054937ModulesOpenbravo Business APIpublic2024-03-13 11:322024-04-17 11:31
malsasua 
caristu 
highmajoralways
closedfixed 
5
 
 
0054937: EDL error using ReadOnly database with Business API events
when EDL is configured to use the ReadOnly db:
Openbravo.properties: bbdd.readonly.url=xxxx

in the flow Send Business API Event, if the synchronization between the primary and the replica nodes is slow, an error is raised (attached the whole error trace):
ERROR org.openbravo.externaldata.integration.process.AsynchronousProcessor - Unexpected error processing item
org.openbravo.base.exception.OBException: Could not export data for record with ID A6FACEAC7AA61347420F98C6BB9A96BF
        at org.openbravo.api.edl.ApiEventItemProcessor.lambda$exportItem$0(ApiEventItemProcessor.java:85) ~[classes/:?]

Executing again, the EDL works

The problem is the ticket was processed but it was not synced yet to the replica db node
. in local env, duplicate the db:
 -> create database miDB2 template miDB;
. configure Openbravo.properties to use a readOnly:
bbdd.readonly.url=jdbc:postgresql://localhost:5432 [^]
bbdd.readonly.sid=miDB2
bbdd.readonly.user=tad
bbdd.readonly.password=tad

. configure to use Send Business API - RETAPCO_OrderCreation

. in POS -> complete a ticket
. in BO -> go to EDL -> edl record was created in error
No tags attached.
related to backport 0055135 closed adrianromero EDL error using ReadOnly database with Business API events 
related to backport 0055217 closed adrianromero EDL error using ReadOnly database with Business API events 
log stackTrace.log (5,062) 2024-03-13 11:32
https://issues.openbravo.com/file_download.php?file_id=19540&type=bug
png codeError.png (50,108) 2024-03-13 11:33
https://issues.openbravo.com/file_download.php?file_id=19541&type=bug
png
Issue History
2024-03-13 11:32malsasuaNew Issue
2024-03-13 11:32malsasuaAssigned To => Triage Platform Base
2024-03-13 11:32malsasuaModules => Core
2024-03-13 11:32malsasuaTriggers an Emergency Pack => No
2024-03-13 11:32malsasuaFile Added: stackTrace.log
2024-03-13 11:33malsasuaFile Added: codeError.png
2024-03-13 11:34malsasuaDescription Updatedbug_revision_view_page.php?rev_id=27677#r27677
2024-03-13 11:37caristuProjectOpenbravo ERP => Modules
2024-03-13 11:39caristuAssigned ToTriage Platform Base => Triage Platform Conn
2024-03-13 11:39caristuCategoryA. Platform => Openbravo Business API
2024-03-13 11:41malsasuaSummaryEDL error using ReadOnly database => EDL error using ReadOnly database with Business API events
2024-03-14 08:35hgbotNote Added: 0162130
2024-03-18 10:06adrianromeroAssigned ToTriage Platform Conn => caristu
2024-04-05 12:51hgbotNote Added: 0162884
2024-04-05 12:51hgbotResolutionopen => fixed
2024-04-05 12:51hgbotStatusnew => closed
2024-04-05 12:51hgbotNote Added: 0162885
2024-04-09 09:37adrianromeroIssue cloned0055135
2024-04-09 09:37adrianromeroRelationship addedrelated to 0055135
2024-04-17 11:31adrianromeroIssue cloned0055217
2024-04-17 11:31adrianromeroRelationship addedrelated to 0055217

Notes
(0162130)
hgbot   
2024-03-14 08:35   
Merge Request created: https://gitlab.com/openbravo/product/pmods/org.openbravo.api/-/merge_requests/243 [^]
(0162884)
hgbot   
2024-04-05 12:51   
Merge request merged: https://gitlab.com/openbravo/product/pmods/org.openbravo.api/-/merge_requests/243 [^]
(0162885)
hgbot   
2024-04-05 12:51   
Directly closing issue as related merge request is already approved.

Repository: https://gitlab.com/openbravo/product/pmods/org.openbravo.api [^]
Changeset: 8415e224774f1c20b10d889501093a056f15b5e4
Author: Carlos Aristu <carlos.aristu@openbravo.com>
Date: 05-04-2024 10:51:54
URL: https://gitlab.com/openbravo/product/pmods/org.openbravo.api/-/commit/8415e224774f1c20b10d889501093a056f15b5e4 [^]

fixes BUG-54937: do not use RO pool for single record events

---
M src-test/org/openbravo/api/edl/ApiEventItemProcessorTest.java
M src/org/openbravo/api/edl/ApiEventItemProcessor.java
---