node-pool
node-pool copied to clipboard
Attempt to fix defaultEvictor.
If pooledResource
is not a Resource
(but an Error
), it won't have lastIdleTime
thus all ifs are returning false
meaning the Resource
(which is already broken in some way) won't get evicted ever, they stay in the pool and this may result in a ResourceRequest Timed Out
error (b/c all slots are occupied by stuck Resource
s).
As a solution, idleTime
is checked, and if it is falsy, the Resource
gets evicted.
Signed-off-by: Daniel Schopper [email protected]
Please someone shed some light how to interpret the eslint errors in the Travis build log, I cannot figure out, what the problem is.
npm run lint
or yarn run lint
should fix up the formatting errors which travis is complaining about.
This is definitely not good as it is, the added JSON.stringify
produces a TypeError: Converting circular structure to JSON
. Currently I am testing it with util.inspect
instead.
I have reported ResourceRequest Timed Out here. I would like to ask what causes” pooledResource is not a Resource (but an Error)“ @scream314
Sorry, I cannot work on this anymore. Maybe @steveetm?