From 73af9e9737665a7fe7ac3a5e594a490531718c72 Mon Sep 17 00:00:00 2001 From: "Chris S. Kim" Date: Thu, 2 Jun 2022 12:26:18 -0400 Subject: [PATCH] Fix KVSGet method to handle QueryOptions properly (#13344) --- .changelog/13344.txt | 3 +++ agent/kvs_endpoint.go | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) create mode 100644 .changelog/13344.txt diff --git a/.changelog/13344.txt b/.changelog/13344.txt new file mode 100644 index 0000000000..18569b40fb --- /dev/null +++ b/.changelog/13344.txt @@ -0,0 +1,3 @@ +```release-note:bug +kvs: Fixed a bug where query options were not being applied to KVS.Get RPC operations. +``` \ No newline at end of file diff --git a/agent/kvs_endpoint.go b/agent/kvs_endpoint.go index bcb8745880..1aed8178ad 100644 --- a/agent/kvs_endpoint.go +++ b/agent/kvs_endpoint.go @@ -69,7 +69,7 @@ func (s *HTTPHandlers) KVSGet(resp http.ResponseWriter, req *http.Request, args // Make the RPC var out structs.IndexedDirEntries - if err := s.agent.RPC(method, &args, &out); err != nil { + if err := s.agent.RPC(method, args, &out); err != nil { return nil, err } setMeta(resp, &out.QueryMeta)