# FATAL: sorry, too many clients already (RDS Proxy connection limit exceeded)

- **ID:** `aws/rds-proxy-connection-limit-exceeded`
- **Domain:** aws
- **Category:** resource_error
- **Verification:** ai_generated
- **Fix Rate:** 80%

## Root Cause

The RDS Proxy has reached its maximum concurrent connections limit, often due to connection leaks or insufficient proxy capacity.

## Version Compatibility

| Version | Status | Introduced | Deprecated |
|---------|--------|------------|------------|
| RDS Proxy 1.0.0 | active | — | — |
| PostgreSQL 13.7 | active | — | — |
| MySQL 8.0.33 | active | — | — |

## Workarounds

1. **Increase the RDS Proxy's MaxConnectionsPercent in the proxy settings (console or CLI with 'aws rds modify-db-proxy --db-proxy-name myproxy --max-connections-percent 100'). This allows more connections proportional to the database instance's max_connections.** (85% success)
   ```
   Increase the RDS Proxy's MaxConnectionsPercent in the proxy settings (console or CLI with 'aws rds modify-db-proxy --db-proxy-name myproxy --max-connections-percent 100'). This allows more connections proportional to the database instance's max_connections.
   ```
2. **Fix connection leaks in the application: ensure database connections are properly closed in all code paths (e.g., using connection pools with 'maxLifetime' and 'idleTimeout' settings). Implement a connection pool library like HikariCP (Java) or pgBouncer (PostgreSQL).** (90% success)
   ```
   Fix connection leaks in the application: ensure database connections are properly closed in all code paths (e.g., using connection pools with 'maxLifetime' and 'idleTimeout' settings). Implement a connection pool library like HikariCP (Java) or pgBouncer (PostgreSQL).
   ```

## Dead Ends

- **** — Increasing the database instance max_connections without adjusting RDS Proxy's MaxConnectionsPercent parameter still leaves the proxy as the bottleneck. (60% fail)
- **** — Restarting the RDS Proxy doesn't solve the underlying issue of connection leaks from the application; connections will quickly exhaust the limit again. (40% fail)
