Rafi Shamim
cf24ef28ee
pg-connection-string: avoid clobbering port from queryparams ( #2833 )
...
If the connection string is something like:
postgresql://demo:password@/postgres?host=localhost&port=26258
Then the port from the query parameters should be used. Previously, the
parsing function would end up with a null port, and the default port
would end up being used by the connecetion package.
2023-07-21 11:57:02 -05:00
Adam Jones
c38ecf3405
Fix connection string parsing for overriden hosts ( #2977 )
...
* Add failing test
* Fix test
This corresponds to what was line 48 previously, see https://github.com/brianc/node-postgres/pull/2971/files#diff-08a5e82487ebd9b43751630019753901fae0a111f8d009ad2e9d194445e96922L48
* Update packages/pg-connection-string/index.js
Co-authored-by: Pete Bacon Darwin <pete@bacondarwin.com>
---------
Co-authored-by: Brian C <brian.m.carlson@gmail.com>
Co-authored-by: Pete Bacon Darwin <pete@bacondarwin.com>
2023-05-31 10:24:08 -05:00
Pete Bacon Darwin
f305419676
Use URL rather than url.parse() in pg-connection-string
...
Swapping the deprecated Node.js API for the modern cross
environment API.
2023-05-15 07:29:07 +01:00
Benjie Gillam
e421167d46
Add ssl=true into the test
2020-10-04 13:33:21 -05:00
Benjie Gillam
9cbea21587
Solve issues caused by config.ssl = true
2020-10-04 13:33:21 -05:00
Benjie Gillam
6be3b9022f
Add support for ?sslmode connection string param
2020-10-04 13:33:21 -05:00
Rafi Shamim
06cdf3e9f0
Support options connection parameter
...
This supports the connection parameter documented here:
https://www.postgresql.org/docs/9.1/libpq-connect.html#LIBPQ-CONNECT-OPTIONS
2020-05-14 10:07:35 -04:00
Brian M. Carlson
3a831fc77c
Run lint --fix
2020-04-28 10:02:38 -05:00
Brian M. Carlson
4aff01ef8f
Add 'packages/pg-connection-string/' from commit '5233b3e77e396a368130709e762fca836290a528'
...
git-subtree-dir: packages/pg-connection-string
git-subtree-mainline: 35328807e3612cb267bee86dccb2551ad186624a
git-subtree-split: 5233b3e77e396a368130709e762fca836290a528
2020-04-28 09:50:40 -05:00