def close(self):
        """closes down the connection and releases all cyclic dependecies"""
        if not self._closed:
            self.box.close()
            self.channel.close()
            self._closed = True
            self._local_namespace = None
            self.channel = None
            self.box = None
            self.async_replies = None
            self.sync_replies = None
            self.module_cache = None
            self.modules = None
            self.remote_conn = None
            self.namespace = None