Algorithm to identify CT transactions that need to be executed must not stop recursion just because a transaction's state is still Pending after its execution #73
The current algorithm - "handle oldest transaction with state Pending" - is not sufficient for scenarios like 4.2.7 Sample: preauthorization/capture, REC with credit note in PAYONE's Server API documentation:
The Charge transaction of the invoice is still Pending (buyer hasn't paid anything, yet) while a Refund transaction (credit note issued by merchant) is requested (and completed).
Problem
The current algorithm - "handle oldest transaction with state Pending" - is not sufficient for scenarios like 4.2.7 Sample: preauthorization/capture, REC with credit note in PAYONE's Server API documentation: The Charge transaction of the invoice is still Pending (buyer hasn't paid anything, yet) while a Refund transaction (credit note issued by merchant) is requested (and completed).
Another scenario is described in #42.
Solution
To be defined...
See also
9's discussion