Three Phase Commit
An improved version of Two Phase Commit which added another steps called "can commit" steps which typically do health check and so on before running the Two Phase Commit
- Can commit: coordinator ping all the services to check if they're healthy to commit
- Prepare phase: services prepare to commit, lock the database to prepare to commit and so on
- Commit phase: services started to commit. If all commits then it stays commits. If one fails then coordinator will ask all services to rollback
However, in this case we still have the coordinator as Single point of failure