# RDS Proxy connection terminated: idle in transaction timeout (60 seconds)

- **ID:** `aws/rds-proxy-idle-connection-timeout`
- **Domain:** aws
- **Category:** runtime_error
- **Verification:** ai_generated
- **Fix Rate:** 80%

## Root Cause

RDS Proxy enforces a 60-second idle transaction timeout by default, terminating connections that hold open transactions without activity.

## Version Compatibility

| Version | Status | Introduced | Deprecated |
|---------|--------|------------|------------|
| RDS Proxy 1.0 | active | — | — |
| aurora-mysql-8.0 | active | — | — |
| postgresql-15.4 | active | — | — |

## Workarounds

1. **Set `idle_in_transaction_session_timeout` to a higher value in the database (e.g., `SET idle_in_transaction_session_timeout = '120000';`) to allow longer idle transactions.** (85% success)
   ```
   Set `idle_in_transaction_session_timeout` to a higher value in the database (e.g., `SET idle_in_transaction_session_timeout = '120000';`) to allow longer idle transactions.
   ```
2. **Implement application-level keepalive: send a simple query (e.g., `SELECT 1`) every 30 seconds within long transactions to prevent idle detection.** (90% success)
   ```
   Implement application-level keepalive: send a simple query (e.g., `SELECT 1`) every 30 seconds within long transactions to prevent idle detection.
   ```

## Dead Ends

- **** — Increasing the idle timeout in RDS Proxy settings is not supported; the 60-second limit is hardcoded. (100% fail)
- **** — Disabling connection pooling entirely removes the proxy benefit and may cause connection storms. (70% fail)
