CursorManager was deprecated in PYTHON-323. Now we undeprecate it, but we remove
BatchCursorManager. MongoClient.set_cursor_manager now accepts None in addition
to accepting a CursorManager subclass. CursorManager.close now requires, and
MongoClient.kill_cursors accepts, an "address" parameter.
This fixes three circular references that stop
Connection instances from being deallocated by
the standard ref counting GC.
Database and SystemJS instances
Connection and CursorManager instances
_Pool and Connection (through a bound method)
Previously if you did something like:
>>> c = pymongo.Connection()
>>> c = None
'c' wouldn't be deallocated. This is a problem for
at least two reasons...
1. memory is wasted in the interpreter
2. sockets aren't being closed until the main thread exits.
This also fixes the real problem with unit tests
failing on OSX.