etcd: Pass through the namespace

This is a bit tricky, and we should nuke and redo some of this API. The
sneaky bit has to do with whether we've already added the namespace
magic into our etcd client or not.
This commit is contained in:
James Shubin
2025-08-19 18:52:48 -04:00
parent 0031acbcbc
commit bed7e6be79
3 changed files with 16 additions and 2 deletions

View File

@@ -1464,7 +1464,7 @@ func (obj *EmbdEtcd) MakeClient() (interfaces.Client, error) {
func (obj *EmbdEtcd) MakeClientFromNamespace(ns string) (interfaces.Client, error) {
kv := namespace.NewKV(obj.etcd.KV, ns)
w := namespace.NewWatcher(obj.etcd.Watcher, ns)
c := client.NewClientFromNamespace(obj.etcd, kv, w)
c := client.NewClientFromNamespace(obj.etcd, kv, w, ns)
if err := c.Init(); err != nil {
return nil, err
}