Open drdrsh opened 2 years ago
Should be an easy fix, I'll push something soon @drdrsh 👍
Fixed application_name
, the other ones I'll do later, they are slightly more involved I think. I'll keep this issue open until the remaining parameters are implemented.
Hey @levkk, just stumbled across this open ticket while trying to debug some encoding issues. We've seen temporary issues with client_encoding not being set that we suspect are related to this bug as they first started appearing after switching to pgcat.
Makes sense. You can set client_encoding
on the server just like we do with application_name
, e.g. https://github.com/levkk/pgcat/blob/master/src/client.rs#L1041
PR welcome!
P.S. Ideally we set all parameters with a single query, so maybe something like server.set_parameters(...)
which will execute SET application_name = foo; SET client_encoding = bar;
, etc.
Describe the bug I am comparing pgcat's behavior against pgbouncer with both running in transaction mode.
When the client sets any of the following parameters in the connection string, pgbouncer takes note of them and keeps them consistent for each client
pgcat doesn't. I think of these variables
application_name
is perhaps the most important given it can be used for query source attribution inpg_stat_activity
To Reproduce Run the following ruby script against pgcat after modifying the connection strings to point to the correct address
This produces
Expected behavior It should output