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

View Issue DetailsJump to Notes ] Issue History ] Print ]
ID
0053100
TypeCategorySeverityReproducibilityDate SubmittedLast Update
defect[Retail Modules] Web POSmajorhave not tried2023-07-28 14:342023-08-02 11:26
ReporterAugustoMauchView Statuspublic 
Assigned ToAugustoMauch 
PrioritynormalResolutionfixedFixed in Version
StatusclosedFix in branchFixed in SCM revision
ProjectionnoneETAnoneTarget Version
OSAnyDatabaseAnyJava version
OS VersionDatabase versionAnt version
Product VersionSCM revision 
Merge Request Statusapproved
Review Assigned To
OBNetwork customerNo
Support ticket
Regression level
Regression date
Regression introduced in release
Regression introduced by commit
Triggers an Emergency PackNo
Summary

0053100: SynchronizationBuffer.internalFlush does not flush all messages if some endpoints where currently syncing other messages

DescriptionThe internalFlush function of SynchronizationBuffer tries to synchronize all the messages from all the available endpoints. If an endpoint is already synchronizing previous messages, that endpoint will be skipped.

That function is invoked whenever new messages are added to the synchronization buffer, but also externally (i.e. to ensure all messages are synchronized before stopping the synchronization buffer when logging out).

It would be useful if, on demand, when internalFlush is executed and some endpoints are skipped because they were busy, it is recursively invoked a reasonable number of times until all messages are synchronized
Steps To ReproduceThis issue is difficult to reproduce, as it relies on a race condition (i.e. the backend endpoint being busy synchronizing terminal log messages when a user closes a cashup, resulting in the cashup not being synchronized until the next time the user logs in).

To help reproduce the issue:
- Install the attached sleepOnTerminalLog.diff patch. It contains commented out code that will result in the synchronized terminal log messages taking very long. Uncomment the code right after opening the cashup screen in pos2, if you do it before it will be difficult to use POS2.
- Open the Cashup window, move to the last step. Pay attention to the eclipse log, and the momento the "Sleeping" message is shown, complete the cashup. The user will be logged out, and if you check the synchronization buffer store in IndexedDB you will check that the message was not synchronized
TagsNo tags attached.
Attached Files

- Relationships Relation Graph ] Dependency Graph ]
depends on backport 0053131RR23Q1.4 closedAugustoMauch SynchronizationBuffer.internalFlush does not flush all messages if some endpoints where currently syncing other messages 
depends on backport 0053132RR23Q3 closedAugustoMauch SynchronizationBuffer.internalFlush does not flush all messages if some endpoints where currently syncing other messages 
depends on backport 0053133RR23Q2.3 closedAugustoMauch SynchronizationBuffer.internalFlush does not flush all messages if some endpoints where currently syncing other messages 
related to defect 0053139 closedAugustoMauch A message should be logged when SynchronizationBuffer.internalFlush gives after reaching max amount of retries 

-  Notes
(0152983)
hgbot (developer)
2023-07-28 14:53

Merge Request created: https://gitlab.com/openbravo/product/pmods/org.openbravo.mobile.core/-/merge_requests/583 [^]
(0153088)
hgbot (developer)
2023-08-02 09:08

Merge request merged: https://gitlab.com/openbravo/product/pmods/org.openbravo.mobile.core/-/merge_requests/583 [^]
(0153089)
hgbot (developer)
2023-08-02 09:08

Directly closing issue as related merge request is already approved.

Repository: https://gitlab.com/openbravo/product/pmods/org.openbravo.mobile.core [^]
Changeset: d7e84992f5c1ffe44bc8d163187d963a3fd3561c
Author: Augusto Mauch <augusto.mauch@openbravo.com>
Date: 02-08-2023 08:53:46
URL: https://gitlab.com/openbravo/product/pmods/org.openbravo.mobile.core/-/commit/d7e84992f5c1ffe44bc8d163187d963a3fd3561c [^]

Fixes ISSUE-53100: SynchronizationBuffer.internalFlush does not ensure all messages are synchronized

Now, if the internalFlush method was executed and any of the endpoints were busy with previous synchronizations, it will be
recursively invoked after waiting for 500ms. The recursive calls will continue until none of the endpoints were busy or until
a maximum number of recursive calls (set to 10 for a total of a 5 second wait) is reached.

By default, internalFlush will behave as before, the new retry behaviour will only take place if its first param is passed to true

---
M web/org.openbravo.mobile.core/app/model/synchronization-buffer/SynchronizationBuffer.js
---

- Issue History
Date Modified Username Field Change
2023-07-28 14:34 AugustoMauch New Issue
2023-07-28 14:34 AugustoMauch Assigned To => AugustoMauch
2023-07-28 14:34 AugustoMauch OBNetwork customer => No
2023-07-28 14:34 AugustoMauch Triggers an Emergency Pack => No
2023-07-28 14:35 AugustoMauch Status new => scheduled
2023-07-28 14:42 AugustoMauch Steps to Reproduce Updated View Revisions
2023-07-28 14:53 hgbot Merge Request Status => open
2023-07-28 14:53 hgbot Note Added: 0152983
2023-07-28 14:57 hgbot Note Added: 0152984
2023-08-01 10:02 hgbot Note Added: 0153049
2023-08-02 08:32 AugustoMauch Note Deleted: 0152984
2023-08-02 08:32 AugustoMauch Note Deleted: 0153049
2023-08-02 09:07 hgbot Merge Request Status open => approved
2023-08-02 09:08 hgbot Resolution open => fixed
2023-08-02 09:08 hgbot Status scheduled => closed
2023-08-02 09:08 hgbot Note Added: 0153088
2023-08-02 09:08 hgbot Fixed in Version => RR23Q4
2023-08-02 09:08 hgbot Note Added: 0153089
2023-08-02 11:25 AugustoMauch Status closed => new
2023-08-02 11:25 AugustoMauch Resolution fixed => open
2023-08-02 11:25 AugustoMauch Fixed in Version RR23Q4 =>
2023-08-02 11:26 AugustoMauch Status new => scheduled
2023-08-02 11:26 AugustoMauch Status scheduled => resolved
2023-08-02 11:26 AugustoMauch Resolution open => fixed
2023-08-02 11:26 AugustoMauch Status resolved => closed
2023-08-02 14:01 AugustoMauch Relationship added related to 0053139


Copyright © 2000 - 2009 MantisBT Group
Powered by Mantis Bugtracker