Note:
This topic has been translated from a Chinese forum by GPT and might contain errors.
[TiDB Usage Environment] Online production environment
[TiDB Version] v4.0.12
[Encountered Problem]
The data writing speed is relatively slow, causing pessimistic lock transactions to time out. Transaction commit failed.
[Problem Phenomenon and Impact]
When the data writing wait time is too long, the transaction commit fails:
Error message is as follows:
error code [8229]; TTL manager has timed out, pessimistic locks may expire, please commit or rollback this transaction; nested exception is java.sql.SQLException: TTL manager has timed out, pessimistic locks may expire, please commit or rollback this transaction
I saw someone posted before, saying that the transaction time can be increased by modifying the max_txn_ttl parameter. But how do you modify this parameter? Is there a guide manual that can be referred to?