transaction.timeout.ms — Kafka Producer Configuration
The maximum amount of time in milliseconds that a transaction will remain open before the coordinator proactively aborts it. The start of the transaction is set at the time that the first partition is added to it
Description
The maximum amount of time in milliseconds that a transaction will remain open before the coordinator proactively aborts it. The start of the transaction is set at the time that the first partition is added to it. If this value is larger than the transaction.max.timeout.ms setting in the broker, the request will fail with a InvalidTxnTimeoutException error.
Default Values by Kafka Version
| Component | Kafka version line | Documented default |
|---|---|---|
| Producer | 0.11.0 | 60000 |
| Producer | 1.0 | 60000 |
| Producer | 1.1 | 60000 |
| Producer | 2.0 | 60000 |
| Producer | 2.1 | 60000 |
| Producer | 2.2 | 60000 |
| Producer | 2.3 | 60000 |
| Producer | 2.4 | 60000 |
| Producer | 2.5 | 60000 |
| Producer | 2.6 | 60000 (1 minute) |
| Producer | 2.7 | 60000 (1 minute) |
| Producer | 2.8 | 60000 (1 minute) |
| Producer | 3.0 | 60000 (1 minute) |
| Producer | 3.1 | 60000 (1 minute) |
| Producer | 3.2 | 60000 (1 minute) |
| Producer | 3.3 | 60000 (1 minute) |
| Producer | 3.4 | 60000 (1 minute) |
| Producer | 3.5 | 60000 (1 minute) |
| Producer | 3.6 | 60000 (1 minute) |
| Producer | 3.7 | 60000 (1 minute) |
| Producer | 3.8 | 60000 (1 minute) |
| Producer | 3.9 | 60000 (1 minute) |
| Producer | 4.0 | 60000 (1 minute) |
| Producer | 4.1 | 60000 (1 minute) |
| Producer | 4.2 | 60000 (1 minute) |
| Producer | 4.3 | 60000 (1 minute) |
| Producer | 4.4 | 60000 (1 minute) |
Tuning Recommendation
Workload-dependent proposals, not benchmarked defaults. Review the versioned Config Advisor before applying.
| Profile | Proposal | Rationale and tradeoff |
|---|---|---|
| producer / durability | 60000 | Defines the producer transaction timeout requested from the coordinator; it must not exceed the broker maximum. Tradeoff: Long-running transactions may be aborted when the timeout expires. Excessive values can prolong the visibility delay for read_committed consumers. Reference · 2026-10-27 |
Related Configs
transactional.id · delivery.timeout.ms