3rd-Eden / memcached

A fully featured Memcached client build on top of Node.js. Build with scaling in mind so it will support Memcached clusters and consistent hashing.
MIT License
1.31k stars 276 forks source link

process hangs after close() #348

Open yofreke opened 5 years ago

yofreke commented 5 years ago

My process fails to connect to a memcache server in test logic, then the process hangs. I am calling memcached.end();, but the process still hangs.

After debugging with node debugger, and wtfnode, I was able to determine that memcached was generating a couple timers in connection.js.

After waiting 5 minutes (the failuresReset timeout), the process exits as expected.

Ideally memcache.end also closes any in-process timers, so the process may exit.