Ensure defunct connections are completely closed (JAVA-394).
Merge branch '2.0' into 2.1