deftlabs/mongo-java-distributed-lock — pull request #3 by john-morales (2013-07-20 20:13:09+00:00)
Title: Fixes to service shutdown and monitor thread behavior

Hi deftlabs!

This commit makes the following two changes:

* `SvcImpl.shutdown()` now closes the `Mongo` client and clears the `_locks` map; previously the starting and shutting down of multiple `SvcImpl` instances would leak the connections of the `Mongo` clients.
* The background monitor threads are now signaled to stop more gracefully before resorting to an interrupt. Previous approach of using interrupts first could potentially interrupt an in-process driver operation, causing the following log message: http://cl.ly/image/2X201k3m383l

Thanks!