def _stop_all_backends(self):

        for backend in self.backends.values():
            alive = backend.__thread.is_alive
            if not alive(): continue
            backend.stop()

            if not self._wait(lambda: not alive(), 5):
                backend.error("Worker thread did not terminate")
Notify all backends registered via Router.add_backend that they
dataset/ETHPy150Open rapidsms/rapidsms-core-dev/lib/rapidsms/router.py/Router._stop_all_backends