Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion docs/guides/configuration-reference.md
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ Property keys are matched case-insensitively.
|----------------|--------------|---------|-------------|
| `waitTimeoutMillis(int)` | `waitTimeout` | `1000` | Millis a thread waits for a free connection once the pool is at max before throwing `ConnectionPoolExhaustedException`. |
| `slowCreationMillis(int)` | `slowCreationMillis` | `100` | Log new physical connection creation at INFO when it exceeds this threshold. Set to `0` to disable slow creation logging. |
| `maxInactiveTimeSecs(int)` | `maxInactiveTimeSecs` | `300` | Idle seconds after which a free connection can be trimmed back towards `minConnections`. |
| `maxInactiveTimeSecs(int)` | `maxInactiveTimeSecs` | `900` | Idle seconds after which a free connection can be trimmed back towards `minConnections`. |
| `maxAgeMinutes(int)` | `maxAgeMinutes` | `0` (unlimited) | Maximum age of a connection before it is trimmed regardless of activity. |
| `trimPoolFreqSecs(int)` | `trimPoolFreqSecs` | `59` | How often the background trim check runs. |

Expand Down
2 changes: 1 addition & 1 deletion docs/guides/monitoring-pool-metrics.md
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ For most applications, **`size()` (`free() + busy()`) is the single most useful

- The pool **grows on demand**: when a connection is requested and none is free (and `size < maxConnections`),
it creates a new one. So `size()` rises immediately to meet real concurrent demand.
- The pool **trims slowly**: idle connections are only retired after `maxInactiveTimeSecs` (default 300s),
- The pool **trims slowly**: idle connections are only retired after `maxInactiveTimeSecs` (default 900s),
checked on the `trimPoolFreqSecs` cycle, and never below `minConnections`. This deliberate laziness
avoids connection churn.

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ public class DataSourceConfig implements DataSourceBuilder.Settings {
private boolean captureStackTrace;
private int maxStackTraceSize = 5;
private int leakTimeMinutes = 30;
private int maxInactiveTimeSecs = 300;
private int maxInactiveTimeSecs = 900;
private int maxAgeMinutes = 0;
private int trimPoolFreqSecs = 59;
private int pstmtCacheSize = UNSET; // defaults to 300
Expand Down
Loading