Slackbot
02/08/2024, 12:43 AMPenghui
02/08/2024, 2:34 AMKumar L
02/08/2024, 5:11 AMtxn.commit.get(), so if the retry is indefinite, how long will the client wait for a response? if there is any timeout happens, the client assume the commit is failed eventhough transaction coordinator still performing the retry.Penghui
02/08/2024, 5:27 AMCOMMITTING ,the coordinator will retry and finally complete the transaction with COMMITTED with infinite retry.
Another case is your client crashed while waiting for the response of the transaction commit. In this case, the client also doesn't know the transaction state. The transaction coordinator will work the same as above.
You can try to re-commit the transaction for both of the above cases. The transaction coordinator will respond to an exception if the transaction has already been committed or aborted.Kumar L
02/08/2024, 6:38 AMCOMMITTING can I safely assume that the transaction will be guaranteed to be fully COMMITTED by 100%?Penghui
02/08/2024, 8:19 AMKumar L
02/08/2024, 8:36 AMApurva Telang
02/08/2024, 7:20 PMYou can try to re-commit the transaction for both of the above cases. The transaction coordinator will respond to an exception if the transaction has already been committed or aborted.
Please can you elaborate on how the client could re-commit the transaction if it has crashed? If the client were to create a new transaction, then how will the coordinator know if the old txn and the new one is the same?Penghui
02/15/2024, 3:24 AMTransactionCoordinatorClient tcClient = recoverPulsarClient.getTcClient();
for (TxnID txnID : txnIDList) {
tcClient.commit(txnID);
}Apurva Telang
02/15/2024, 6:14 PM