What is ListTransactions?
Finds potentially stuck or long-running transactions via kafka-transactions.sh --list. Filtering by duration threshold lets operators quickly identify transactions that have been open longer than expected and may be blocking read_committed consumers.
| Version | Kafka | Changes |
|---|---|---|
| ListTransactionsRequest | ||
| v0 | 3.0 | + StateFilters []string+ ProducerIdFilters []int64~ Flexible encoding enabled FLEXIBLE |
| v1 | 3.8 | + DurationFilter int64adds DurationFilter to list transactions older than specified duration |
| v2 | 4.1 | + TransactionalIdPattern stringadds TransactionalIdPattern to list transactions with the same pattern(KIP-1152) |
| ListTransactionsResponse | ||
| v0 | 3.0 | + ThrottleTimeMs int32+ ErrorCode int16+ UnknownStateFilters []string+ TransactionStates []TransactionState+ TransactionalId string+ ProducerId int64+ TransactionState string~ Flexible encoding enabled FLEXIBLE |
| v1 | 3.8 | is the same as version 0 (KIP-994). |
| v2 | 4.1 | No changes |