def finalClose(self):
        """
        This should only be called by the shutdown trigger.
        """
        self.shutdownID = None
        self.threadpool.stop()
        self.running = False
        for conn in self.connections.values():
            self._close(conn)
        self.connections.clear()

        This should only be called by the shutdown trigger.
        
stackoverflow/venv/lib/python3.6/site-packages/twisted/enterprise/adbapi.py