ERROR 1205 lock wait timeout: client cannot confirm prior commit before retry
After a lock wait timeout, MySQL returns ERROR 1205 and rolls back the current statement or, depending on innodb_rollback_on_timeout , the entire transaction. The client receives the error but cannot determine whether the transaction had already committed before the timeout was detected. Blindly retrying the same multi-statement transaction risks duplicating