Open wonder-sk opened 1 week ago
Hi @wonder-sk, is 404
a good way to check if transaction has been successful? What if server failed to finish the transaction?
if the "push finish" request was not successful on the server for some reason, I believe the transaction will still be alive until it expires or until it is explicitly canceled with "push cancel" request from the client. But it will be good to double check the server implementation 🙂
If there is a push from the mobile app, and the "push finish" request is sent, and client gets a networking issue (e.g. "Software caused connection abort") and server successfully finished the transaction, the mobile app's client gets into an bad state:
The solution could be to distinguish network errors from server errors - and in case of a network error, the client could retry "push finish" request - the server should return 404 if the transaction has been successful (and it's too early for the transaction to expire), or the server should successfully finish the transaction if it was still unfinished.