-
-
Notifications
You must be signed in to change notification settings - Fork 1.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Postgres sslmode
parameter support
#1949
Comments
You can, for the time being use generic connection-string to parse it, and use the connection object with any parameters that you want. Other than that, I submitted a PR there sometime ago, but it's still just hanging there. |
Thank you, I already found out that problem lies in fact in But I still wonder, what are reasons behind current state of affairs? Why I have to parse connection string myself beforehand? |
There's some discrepancy between this driver and what that old parser can do. It was somewhat updated lately, but the old version is still referenced here, hence the mess. At least if you parse it yourself, you can be certain of how it works :) |
The option is called |
This is probably an oversight in implementing PostgreSQL-connection-URI-compatible options, though, maybe related to
|
What makes a difference - this driver continues to use an ancient version of pg-connection-string, and for no good reason that I know of. And though I suggested more than once to switch over to the generic connection-string, it is turned down every time on some premise of old compatibility that few would care about. So you keep getting issues open and people getting confused about all the discrepancies going on between the object format and the connection string syntax. This should have been sorted ages ago. |
@vitaly-t I’m not sure what “What makes a difference” means. Anyway, mixing pg options and libpq options into the same connection URI syntax is a mistake, in my opinion. Switching to “generic connection-string”, which uses (now, an unspecified superset of) the MongoDB connection string spec instead of the libpq implementation would also be a mistake. |
I can't figure out clearly, is
sslmode
parameter supported for connection strings? As I can see in pg-connection-string,sslmode
isn't parsed, but I can see its mention in the codebase.I use
pg-promise
in my project, and I havesslmode
parameter in the Postgres connection string from Google Cloud. So I can't connect due to thedatabase "dbname?sslmode=disable" does not exist
, that's why I'm asking :)The text was updated successfully, but these errors were encountered: