when you write with a transaction, a transactionend is written separately on commit. which allows you to write more than a single batch in a transaction.
I did my homework and after staring at code for last couple of days I think I figured it out.
I noticed there is a PrepareAck message sent to each node of a cluster. So I imagine if the prepare phase has failed, the transaction is rolled back for the entire cluster.
The commit message is there to assess the changes have been materialized (I suppose it means it can be seen from the outside) across the system.
If it’s not possible then the transaction is rolled back.
Greg’s responses are often succinct but are a great source of motivation