Charmander

Results 205 comments of Charmander

I’d like to know why `handleError` is called after completion and haven’t looked into it yet. (code style doesn’t match, by the way)

Config option: ```js types: { getTypeParser: () => String, }, ``` Easy enough for how niche it is, and it’s nice to have defaults that allow switching to binary mode....

@xiaoshimimi Only `ca` is required for `verify-full`. `key` and `cert` are for client certificate authentication. You definitely shouldn’t specify both `rejectUnauthorized: false` and `ca`. Do other PostgreSQL clients (e.g. psql)...

@NicholasIoanJones If all you need to specify is `rejectUnauthorized: false`, you can omit `ssl` from the configuration object and switch between `sslmode=no-verify` in production and no `sslmode` in development.

@xiaoshimimi Oh, I forgot about this bug: try removing `sslmode` from your connection string and leaving only the `ssl: { ca: … }` in the configuration object.

@xiaoshimimi You won’t need to add `sslmode` in a future release; specifying `ssl` is perfectly supported. The bug is that `sslmode` from the connection string isn’t merged with `ssl` and...

> What should the host and port config properties be used for, the SOCKS5 host, or the pg host? The port doesn’t matter when passing `stream`, and the host should...

That’s right – you need to add error handlers when checking clients out of the pool, in addition to the pool-level error handler, *and* remove them before returning clients to...

> Are you saying there is a way to [unregister] listeners of [events](https://node-postgres.com/apis/client#events)? @jcalfee Yes, the [usual way](https://nodejs.org/api/events.html#emitterremovelistenereventname-listener).

> Correction: I now think that the two uses of the word "idle" mean the same thing, because the pool only checks out / acquires a client for the duration...