# Transaction Related (Continue...)

+ `Grafana` Monitor TiDB —> Transaction —> Transaction Retry Num


![left](./student-guide/diagram/09-TiDB-Transaction-03-01.png)
------------------------------------------------------------
- Transaction - Duration: Transaction response time, divided into pessimistic transactions (pessimistic) and optimistic transactions (optimistic). According to the tidb_txn_mode setting, the transaction response time includes two parts, one is the SQL in the transaction on the TiDB side The sum of the response time, the other part is the interval between each SQL request reaching the TiDB side. It can be considered the sum of the processing delay of SQL on the application side and the link delay applied to the database

- Transaction - Transaction Statement Num: The number of statements in a transaction. If there are more, there may be large transactions, and the write and commit pressure is high, which may affect performance.

- Transaction - Transaction Retry Num, an optimistic transaction will retry the transaction when it encounters a write conflict. If there are many retries here, you need to check whether the business load is hot, and pessimistic transactions do not need to pay attention to this indicator.
