# org.apache.kafka.common.errors.TransactionCoordinatorNotAvailableException: The transaction coordinator is not available

- **ID:** `kafka/transaction-coordinator-not-available`
- **Domain:** kafka
- **Category:** network_error
- **Verification:** ai_generated
- **Fix Rate:** 82%

## Root Cause

The broker acting as transaction coordinator for the transactional ID is down or unreachable.

## Workarounds

1. **Check broker health and restart the coordinator broker if needed: systemctl restart kafka on the affected broker.** (85% success)
   ```
   Check broker health and restart the coordinator broker if needed: systemctl restart kafka on the affected broker.
   ```
2. **Increase transaction.timeout.ms to give the coordinator more time to recover, e.g., props.put("transaction.timeout.ms", "900000");** (70% success)
   ```
   Increase transaction.timeout.ms to give the coordinator more time to recover, e.g., props.put("transaction.timeout.ms", "900000");
   ```
3. **Wait for the coordinator to become available and retry the transaction with exponential backoff.** (80% success)
   ```
   Wait for the coordinator to become available and retry the transaction with exponential backoff.
   ```

## Dead Ends

- **** — Restarting the application without ensuring the coordinator broker is healthy will retrigger the error. (90% fail)
- **** — Changing the transactional.id in config causes the producer to be fenced and lose transaction state. (85% fail)
