There is a trading business with multiple business logic, to give a simple example of a payment transaction that may have cash, shopping coupons, discount cards and the like to pay at the same time. The normal logic is that each payment type is a transaction, which requires multiple transactions to be opened at the same time, and if there are other combinations later, the transaction will be more.
In this case, if the transaction is abnormal, one idea is to save the successful transaction and commit the unsuccessful transaction the next time it is resubmitted.
This looks good and can save the overhead of a previously successful transaction when the exception is handled.
However, we need to know that in the case of 99.x% we do not require such a logic, such processing is each commit whether it is normal or retry to check whether there have been successfully committed transactions. This adds a burden to the normal business logic of 99.x%, so optimization can only happen by chance with abnormal logic and increase the burden of absolute majority of normal logic, and the result is counterproductive. So after the optimization we are in the normal logic of the direct linear processing, no longer breakpoint save. All transactions are resubmitted after an exception, although the overhead is greater in the exception logic, but overall performance is greatly improved. (Unless your business has a 50% chance of an exception)