mirror of
https://github.com/bitnami/containers.git
synced 2026-10-17 18:49:26 +02:00
[bitnami/pgbouncer] Add reserve_pool_timeout to available environment variables (#37540)
* [bitnami/pgbouncer] Add reserve pool timeout environment variable to pgbouncer. Description of the change: The default for this value being 5 seconds is too high for many usecases. We are adding it as an environment variable so it is easier for the user to determine what they would like the client wait time to be. Signed-off-by: Max Zintel <43785951+maxzintel@users.noreply.github.com> * [bitnami/pgbouncer] Add reserve pool timeout to libpgbouncer.sh file. Signed-off-by: Max Zintel <43785951+maxzintel@users.noreply.github.com> * [bitnami/pgbouncer] Add reserve pool timeout to pgbouncer-env.sh. Signed-off-by: Max Zintel <43785951+maxzintel@users.noreply.github.com> --------- Signed-off-by: Max Zintel <43785951+maxzintel@users.noreply.github.com>
This commit is contained in:
@@ -258,6 +258,7 @@ pgbouncer_initialize() {
|
||||
"default_pool_size:${PGBOUNCER_DEFAULT_POOL_SIZE}"
|
||||
"min_pool_size:${PGBOUNCER_MIN_POOL_SIZE}"
|
||||
"reserve_pool_size:${PGBOUNCER_RESERVE_POOL_SIZE}"
|
||||
"reserve_pool_timeout:${PGBOUNCER_RESERVE_POOL_TIMEOUT}"
|
||||
"ignore_startup_parameters:${PGBOUNCER_IGNORE_STARTUP_PARAMETERS}"
|
||||
"log_connections:${PGBOUNCER_LOG_CONNECTIONS}"
|
||||
"log_disconnections:${PGBOUNCER_LOG_DISCONNECTIONS}"
|
||||
|
||||
@@ -43,6 +43,7 @@ pgbouncer_env_vars=(
|
||||
PGBOUNCER_DEFAULT_POOL_SIZE
|
||||
PGBOUNCER_MIN_POOL_SIZE
|
||||
PGBOUNCER_RESERVE_POOL_SIZE
|
||||
PGBOUNCER_RESERVE_POOL_TIMEOUT
|
||||
PGBOUNCER_IGNORE_STARTUP_PARAMETERS
|
||||
PGBOUNCER_EXTRA_FLAGS
|
||||
PGBOUNCER_STATS_PERIOD
|
||||
@@ -131,6 +132,7 @@ export PGBOUNCER_SERVER_RESET_QUERY="${PGBOUNCER_SERVER_RESET_QUERY:-}"
|
||||
export PGBOUNCER_DEFAULT_POOL_SIZE="${PGBOUNCER_DEFAULT_POOL_SIZE:-}"
|
||||
export PGBOUNCER_MIN_POOL_SIZE="${PGBOUNCER_MIN_POOL_SIZE:-}"
|
||||
export PGBOUNCER_RESERVE_POOL_SIZE="${PGBOUNCER_RESERVE_POOL_SIZE:-}"
|
||||
export PGBOUNCER_RESERVE_POOL_TIMEOUT="${PGBOUNCER_RESERVE_POOL_TIMEOUT:-}"
|
||||
export PGBOUNCER_IGNORE_STARTUP_PARAMETERS="${PGBOUNCER_IGNORE_STARTUP_PARAMETERS:-}"
|
||||
export PGBOUNCER_EXTRA_FLAGS="${PGBOUNCER_EXTRA_FLAGS:-}"
|
||||
export PGBOUNCER_STATS_PERIOD="${PGBOUNCER_STATS_PERIOD:-60}"
|
||||
|
||||
@@ -131,6 +131,7 @@ To expose the same database name as the backend, set `PGBOUNCER_DATABASE="$POSTG
|
||||
* `PGBOUNCER_DEFAULT_POOL_SIZE` : PgBouncer maximum server connections to allow per user/database pair. Default: **20**.
|
||||
* `PGBOUNCER_MIN_POOL_SIZE` : PgBouncer has at least this amount of open connections. Default: **0 (disabled)**.
|
||||
* `PGBOUNCER_RESERVE_POOL_SIZE` : PgBouncer allows this amount of additional connections. Default: **0 (disabled)**.
|
||||
* `PGBOUNCER_RESERVE_POOL_TIMEOUT` : If a client has not been serviced in this time, use additional connections from the reserve pool. 0 disables. Default: **5.0** [seconds].
|
||||
* `PGBOUNCER_IGNORE_STARTUP_PARAMETERS`: you can use this to set `ignore_startup_parameters` in the auto-generated `pgbouncer.ini`. This can be useful for solving certain connection issues. See <https://www.pgbouncer.org/> config.html for more details.
|
||||
* `PGBOUNCER_SERVER_IDLE_TIMEOUT`: PgBouncer maximum time in seconds a server connection can be idle. If 0 then the timeout is disabled. Default: **600**
|
||||
* `PGBOUNCER_SERVER_RESET_QUERY`: PgBouncer query sent to server on connection release before making it available to other clients. Default: **DISCARD ALL**
|
||||
|
||||
Reference in New Issue
Block a user