Error All expected transactions already processed

Description

Overview:
When an error occurs in createTransaction or updateTransaction, the temporary transactions are currently not cleaned up. Because the same id is currently used to process transactions for orders or invoices again, and because processAllOrNothing compares the number of temporary transactions to the number of expected transactions, this causes the processing of failed temporary transactions with some new ones, and the subsequent error "All expected transactions already processed".

Since the calling mods will give up on the whole set of transactions if a single one fails, we should remove all the related temporary transactions in case of failure, for any case of failure (including validation).

will resolve this issue, but the resolution is too complex to be included in a hot fix. On the other hand, cleaning up the temp transactions is easy and can be included in a hot fix.

Steps to Reproduce:
See related stories.

Expected Results:
User can try again if an operation (such as invoice approval) fails.

Actual Results:
The operation keeps failing with the message "All expected transactions already processed".

Additional Information:
In AllOrNothingTransactionService, deleteTempTransactions should be called if there is an error within createTransaction, updateTransaction or processAllOrNothing.

Interested parties:

CSP Request Details

None

CSP Rejection Details

None

Potential Workaround

See https://wiki.folio.org/display/DD/How+to+fix+issues+with+finance+data (this is not a complete workaround, budget might have to be fixed)

Checklist

hide

TestRail: Results

Activity

Show:

Dennis Bridges April 13, 2022 at 5:35 PM

Test successful in bugfest-lotus. I can not reproduce this issue anymore.

Oleksii Petrenko April 13, 2022 at 10:34 AM

Deployed to Lotus BF. Please proceed with verification

Mikita Siadykh April 12, 2022 at 3:43 PM

should be tested on bugfest env

Damien April 11, 2022 at 6:48 PM

Note: I provided a fix, but I have yet to figure all the consequences of the bug. For instance, if an invoice fails to approve because of 1 line, with the user trying several times to approve it (see ), mod-finance-storage will try to create several pending payments for some of the same non-failing lines. How will it affect the budget ?

Dennis Bridges April 10, 2022 at 11:08 PM

 monday is the deadline for bugfix release. Perhaps someone in europe could work on the on Monday and it can be released before the deadline. If not we will need to seek approval for hotfix. Thx

cc:

Done

Details

Assignee

Reporter

Priority

Story Points

Sprint

Development Team

Thunderjet

Fix versions

Release

Lotus (R1 2022) Bug Fix

RCA Group

Implementation coding issue

TestRail: Cases

Open TestRail: Cases

TestRail: Runs

Open TestRail: Runs

Created April 8, 2022 at 8:35 PM
Updated May 17, 2022 at 5:31 PM
Resolved April 12, 2022 at 3:43 PM
TestRail: Cases
TestRail: Runs