@classmethod
def remove(cls, pid):
    """Remove a pool, closing all connections

        :param str pid: The pool ID

        """
    with cls._lock:
        cls._ensure_pool_exists(pid)
        cls._pools[pid].close()
        del cls._pools[pid]
