Default: 0
+==== ignore_startup_parameters ====
+
+By default, PgBouncer allows only parameters it can keep track of in startup
+packets - `client_encoding`, `datestyle`, `timezone` and `standard_conforming_strings`.
+
+All others raise error. To allow others too, they can be specified here,
+so that pgbouncer knows that they have handled by admin and it can ignore them.
+
+Default: empty
+
=== Log settings ===
==== log_connections ====
; log error messages pooler sends to clients
log_pooler_errors = 1
+; PgBouncer gives errors on random parameters passed via
+; startup packet. By listing some parameters here,
+; it will allow and ignore them.
+;
+;ignore_startup_parameters = extra_float_digits, geqo
+
; If off, then server connections are reused in LIFO manner
;server_round_robin = 0
[databases]
marko = host=127.0.0.1 port=5432
+template1 =
+regression =
+postgres =
+contrib_regression =
+
[pgbouncer]
logfile = lib/pgbouncer.log
; statement - after statement finishes
pool_mode = transaction
+server_reset_query = RESET ALL; SET SESSION AUTHORIZATION DEFAULT
+
+ignore_startup_parameters = extra_float_digits
+
server_check_query = select 1
server_check_delay = 5
max_client_conn = 100
extern char *cf_logfile;
extern char *cf_pidfile;
+extern char *cf_ignore_startup_params;
+
extern char *cf_admin_users;
extern char *cf_stats_users;
extern int cf_stats_period;
username = val;
else if (varcache_set(&client->vars, key, val))
slog_debug(client, "got var: %s=%s", key, val);
- else {
+ else if (strlist_contains(cf_ignore_startup_params, key)) {
+ slog_debug(client, "ignoring startup parameter: %s=%s", key, val);
+ } else {
+ slog_warning(client, "unsupported startup parameter: %s=%s", key, val);
disconnect_client(client, true, "Unknown startup parameter");
return false;
}
usec_t cf_server_check_delay = 30 * USEC;
int cf_server_round_robin = 0;
+char *cf_ignore_startup_params = "";
+
usec_t cf_server_lifetime = 60*60*USEC;
usec_t cf_server_idle_timeout = 10*60*USEC;
usec_t cf_server_connect_timeout = 15*USEC;
{"server_connect_timeout",true, CF_TIME, &cf_server_connect_timeout},
{"server_login_retry", true, CF_TIME, &cf_server_login_retry},
{"server_round_robin", true, CF_INT, &cf_server_round_robin},
+{"ignore_startup_parameters", true, CF_STR, &cf_ignore_startup_params},
{"pkt_buf", false, CF_INT, &cf_sbuf_len},
{"tcp_defer_accept", false, CF_INT, &cf_tcp_defer_accept},