in the system, the foreground POS machine needs to call the back-end payment API. After the POS machine requests the payment interface for the first time, it has not received a return for a long time, and the timeout is treated as a failure, but the actual backend is already in processing and the final payment is successful. However, the POS machine does not know that the processing is finally successful, but it initiates a second payment request again. At this time, there will be two successful payment requests at the backend. How to optimize this situation?