diff --git a/internal/querycoord/mock_querynode_server_test.go b/internal/querycoord/mock_querynode_server_test.go index c54fbd2c80..4dcdae5e13 100644 --- a/internal/querycoord/mock_querynode_server_test.go +++ b/internal/querycoord/mock_querynode_server_test.go @@ -22,6 +22,7 @@ import ( "net" "strconv" "sync" + "time" "go.uber.org/zap" "google.golang.org/grpc" @@ -172,6 +173,9 @@ func (qs *queryNodeServerMock) start() error { func (qs *queryNodeServerMock) stop() error { qs.cancel() + if qs.session != nil { + qs.session.Revoke(time.Second) + } if qs.grpcServer != nil { qs.grpcServer.GracefulStop() }