浏览代码

grpcproxy: respect KeysOnly flag

Fixes #8478
Anthony Romano 8 年之前
父节点
当前提交
7f4464415a
共有 1 个文件被更改,包括 3 次插入1 次删除
  1. 3 1
      proxy/grpcproxy/kv.go

+ 3 - 1
proxy/grpcproxy/kv.go

@@ -179,7 +179,9 @@ func RangeRequestToOp(r *pb.RangeRequest) clientv3.Op {
 	if r.CountOnly {
 	if r.CountOnly {
 		opts = append(opts, clientv3.WithCountOnly())
 		opts = append(opts, clientv3.WithCountOnly())
 	}
 	}
-
+	if r.KeysOnly {
+		opts = append(opts, clientv3.WithKeysOnly())
+	}
 	if r.Serializable {
 	if r.Serializable {
 		opts = append(opts, clientv3.WithSerializable())
 		opts = append(opts, clientv3.WithSerializable())
 	}
 	}