From 3c422a162976dadc7f834b8bfa151b3d85980ee5 Mon Sep 17 00:00:00 2001 From: Changxin Miao Date: Mon, 6 Apr 2020 13:43:37 +0800 Subject: [PATCH] etcdserver: watch stream got closed once one request is not permitted (#11708) --- etcdserver/api/v3rpc/watch.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/etcdserver/api/v3rpc/watch.go b/etcdserver/api/v3rpc/watch.go index 88eb334f9e22..394dfc6c3995 100644 --- a/etcdserver/api/v3rpc/watch.go +++ b/etcdserver/api/v3rpc/watch.go @@ -255,9 +255,10 @@ func (sws *serverWatchStream) recvLoop() error { select { case sws.ctrlStream <- wr: + continue case <-sws.closec: + return nil } - return nil } filters := FiltersFromRequest(creq)