def getconn(self, key=None):
    "Get a free connection and assign it to 'key' if not None."
    self._lock.acquire()
    try:
        return self._getconn(key)
    finally:
        self._lock.release()
Get a free connection and assign it to 'key' if not None.
def getconn(self, key=None):
    
    self._lock.acquire()
    try:
        return self._getconn(key)
    finally:
        self._lock.release()