Can be used to allow clients issue random parameters.
Mostly needed to handle JDBC extra_float_digits braindamage.
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 but ignore others too, they can be specified here,
+so that pgbouncer knows that they are handled by admin and it can ignore them.
+
+Default: empty
+
=== Log settings ===
==== syslog ====
;
server_reset_query =
+;
+; Comma-separated list of parameters to ignore when given
+; in startup packet.
+;
+;ignore_startup_parameters = extra_float_digits
+
;
; When taking idle server into use, this query is ran first.
; SELECT 1
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_login_retry", true, CF_TIME, &cf_server_login_retry},
{"server_round_robin", true, CF_INT, &cf_server_round_robin},
{"suspend_timeout", true, CF_TIME, &cf_suspend_timeout},
+{"ignore_startup_parameters", true, CF_STR, &cf_ignore_startup_params},
{"pkt_buf", false, CF_INT, &cf_sbuf_len},
{"tcp_defer_accept", true, {cf_get_int, set_defer_accept}, &cf_tcp_defer_accept},