veyron2/naming: renaming MountTable to Namespace
Given the client library interface a different name to the
server MountTable to hopefully reduce confusion!!!
Change-Id: I535aebceb4287a86b1dc4cd9b8b35824079ecc68
diff --git a/examples/unresolve/test_util.go b/examples/unresolve/test_util.go
index 7e3ada1..6a470ed 100644
--- a/examples/unresolve/test_util.go
+++ b/examples/unresolve/test_util.go
@@ -110,7 +110,7 @@
}
func (*fortuneCustomUnresolve) UnresolveStep(context ipc.ServerContext) ([]string, error) {
- servers, err := rt.R().MountTable().ResolveToMountTable(rt.R().NewContext(), "I/want/to/know")
+ servers, err := rt.R().Namespace().ResolveToMountTable(rt.R().NewContext(), "I/want/to/know")
if err != nil {
return nil, err
}
@@ -128,7 +128,7 @@
oa = naming.MakeTerminal(naming.JoinAddressName(ep, "tell/me"))
// Doesn't get unmounted. Fine for a test.
oa = naming.MakeTerminal(oa)
- rt.R().MountTable().Mount(rt.R().NewContext(), "I/want/to/know", oa, 0)
+ rt.R().Namespace().Mount(rt.R().NewContext(), "I/want/to/know", oa, 0)
return oa
}
@@ -151,7 +151,7 @@
}
func (*fortuneNoIDL) UnresolveStep(ipc.ServerCall) ([]string, error) {
- servers, err := rt.R().MountTable().ResolveToMountTable(rt.R().NewContext(), "g")
+ servers, err := rt.R().Namespace().ResolveToMountTable(rt.R().NewContext(), "g")
if err != nil {
return nil, err
}
@@ -185,8 +185,8 @@
return naming.Join(results[0].Server, suffix)
}
-func resolve(t *testing.T, mt naming.MountTable, name string) string {
- results, err := mt.Resolve(rt.R().NewContext(), name)
+func resolve(t *testing.T, ns naming.Namespace, name string) string {
+ results, err := ns.Resolve(rt.R().NewContext(), name)
if err != nil {
t.Errorf("Resolve failed with %v", err)
return ""
@@ -215,8 +215,8 @@
return unres[0]
}
-func unresolve(t *testing.T, mt naming.MountTable, name string) string {
- results, err := mt.Unresolve(rt.R().NewContext(), name)
+func unresolve(t *testing.T, ns naming.Namespace, name string) string {
+ results, err := ns.Unresolve(rt.R().NewContext(), name)
if err != nil {
t.Errorf("Unresolve failed with %v", err)
return ""