CraZySacX / node-jdbc

JDBC Wrapper for node.js
140 stars 107 forks source link

conn.isValidSync using 1000s timeout #220

Open Rouzz opened 3 years ago

Rouzz commented 3 years ago

Hi,

I've experienced a weird issue where sometime my application stops reacting to anything after a new request. I've mapped this issue to the call in lib/pool.js on line 108 that calls conn.isValidSync(1000). With 1000 being the timeout in seconds it seems. So if for any reason that method fail and waits for the timeout, it will wait 1000s for all connections which is a bit too much.

Would it be possible to bring this down to a few seconds ? Or even better to a configurable delay.

Thanks, Rouzz