fix memory leak when can't connect to cluster node