veyron/services/mgmt: Get rid of the term 'invoker' (Part II)

This changes renames files and types to avoid using the term invoker for
objects that are not ipc.Invoker implementations.

There is no change in functionality.

Change-Id: Iba4223df60beb880f94e926e4a68b2b8fb8ec126
diff --git a/services/mgmt/application/impl/dispatcher.go b/services/mgmt/application/impl/dispatcher.go
index f1892e7..3fda1a4 100644
--- a/services/mgmt/application/impl/dispatcher.go
+++ b/services/mgmt/application/impl/dispatcher.go
@@ -30,5 +30,5 @@
 // DISPATCHER INTERFACE IMPLEMENTATION
 
 func (d *dispatcher) Lookup(suffix, method string) (interface{}, security.Authorizer, error) {
-	return repository.ApplicationServer(NewInvoker(d.store, d.storeRoot, suffix)), d.auth, nil
+	return repository.ApplicationServer(NewApplicationService(d.store, d.storeRoot, suffix)), d.auth, nil
 }
diff --git a/services/mgmt/application/impl/invoker.go b/services/mgmt/application/impl/service.go
similarity index 79%
rename from services/mgmt/application/impl/invoker.go
rename to services/mgmt/application/impl/service.go
index c562697..b5cdf01 100644
--- a/services/mgmt/application/impl/invoker.go
+++ b/services/mgmt/application/impl/service.go
@@ -11,16 +11,16 @@
 	"veyron.io/veyron/veyron2/vlog"
 )
 
-// invoker holds the state of an application repository invocation.
-type invoker struct {
+// appRepoService implements the Application repository interface.
+type appRepoService struct {
 	// store is the storage server used for storing application
 	// metadata.
-	// All Invokers share a single dispatcher's Memstore.
+	// All objects share the same Memstore.
 	store *fs.Memstore
-	// storeRoot is a name in the Store under which all data will be stored.
+	// storeRoot is a name in the directory under which all data will be
+	// stored.
 	storeRoot string
-	// suffix is the suffix of the current invocation that is assumed to
-	// be used as a relative object name to identify an application.
+	// suffix is the name of the application object.
 	suffix string
 }
 
@@ -30,9 +30,9 @@
 	errNotFound        = errors.New("not found")
 )
 
-// NewInvoker is the invoker factory.
-func NewInvoker(store *fs.Memstore, storeRoot, suffix string) *invoker {
-	return &invoker{store: store, storeRoot: storeRoot, suffix: suffix}
+// NewApplicationService returns a new Application service implementation.
+func NewApplicationService(store *fs.Memstore, storeRoot, suffix string) *appRepoService {
+	return &appRepoService{store: store, storeRoot: storeRoot, suffix: suffix}
 }
 
 func parse(suffix string) (string, string, error) {
@@ -47,9 +47,7 @@
 	}
 }
 
-// APPLICATION INTERFACE IMPLEMENTATION
-
-func (i *invoker) Match(context ipc.ServerContext, profiles []string) (application.Envelope, error) {
+func (i *appRepoService) Match(context ipc.ServerContext, profiles []string) (application.Envelope, error) {
 	vlog.VI(0).Infof("%v.Match(%v)", i.suffix, profiles)
 	empty := application.Envelope{}
 	name, version, err := parse(i.suffix)
@@ -78,7 +76,7 @@
 	return empty, errNotFound
 }
 
-func (i *invoker) Put(context ipc.ServerContext, profiles []string, envelope application.Envelope) error {
+func (i *appRepoService) Put(context ipc.ServerContext, profiles []string, envelope application.Envelope) error {
 	vlog.VI(0).Infof("%v.Put(%v, %v)", i.suffix, profiles, envelope)
 	name, version, err := parse(i.suffix)
 	if err != nil {
@@ -110,7 +108,7 @@
 	return nil
 }
 
-func (i *invoker) Remove(context ipc.ServerContext, profile string) error {
+func (i *appRepoService) Remove(context ipc.ServerContext, profile string) error {
 	vlog.VI(0).Infof("%v.Remove(%v)", i.suffix, profile)
 	name, version, err := parse(i.suffix)
 	if err != nil {
@@ -144,7 +142,7 @@
 	return nil
 }
 
-func (i *invoker) allApplications() ([]string, error) {
+func (i *appRepoService) allApplications() ([]string, error) {
 	apps, err := i.store.BindObject("/applications").Children()
 	if err != nil {
 		return nil, err
@@ -152,7 +150,7 @@
 	return apps, nil
 }
 
-func (i *invoker) allAppVersions(appName string) ([]string, error) {
+func (i *appRepoService) allAppVersions(appName string) ([]string, error) {
 	profiles, err := i.store.BindObject(naming.Join("/applications", appName)).Children()
 	if err != nil {
 		return nil, err
@@ -176,7 +174,7 @@
 	return versions, nil
 }
 
-func (i *invoker) VGlobChildren() ([]string, error) {
+func (i *appRepoService) VGlobChildren() ([]string, error) {
 	vlog.VI(0).Infof("%v.VGlobChildren()", i.suffix)
 	i.store.Lock()
 	defer i.store.Unlock()
diff --git a/services/mgmt/binary/impl/dispatcher.go b/services/mgmt/binary/impl/dispatcher.go
index 166173a..fa3e900 100644
--- a/services/mgmt/binary/impl/dispatcher.go
+++ b/services/mgmt/binary/impl/dispatcher.go
@@ -28,5 +28,5 @@
 // DISPATCHER INTERFACE IMPLEMENTATION
 
 func (d *dispatcher) Lookup(suffix, method string) (interface{}, security.Authorizer, error) {
-	return repository.BinaryServer(newInvoker(d.state, suffix)), d.auth, nil
+	return repository.BinaryServer(newBinaryService(d.state, suffix)), d.auth, nil
 }
diff --git a/services/mgmt/binary/impl/fs_utils.go b/services/mgmt/binary/impl/fs_utils.go
index bc4c818..8cca7b6 100644
--- a/services/mgmt/binary/impl/fs_utils.go
+++ b/services/mgmt/binary/impl/fs_utils.go
@@ -43,7 +43,7 @@
 }
 
 // generatePartPath generates a path for the given binary part.
-func (i *invoker) generatePartPath(part int) string {
+func (i *binaryService) generatePartPath(part int) string {
 	return generatePartPath(i.path, part)
 }
 
diff --git a/services/mgmt/binary/impl/invoker.go b/services/mgmt/binary/impl/service.go
similarity index 90%
rename from services/mgmt/binary/impl/invoker.go
rename to services/mgmt/binary/impl/service.go
index 8b18141..039e13f 100644
--- a/services/mgmt/binary/impl/invoker.go
+++ b/services/mgmt/binary/impl/service.go
@@ -34,16 +34,15 @@
 	"veyron.io/veyron/veyron2/vlog"
 )
 
-// invoker holds the state of a binary repository invocation.
-type invoker struct {
+// binaryService implements the Binary server interface.
+type binaryService struct {
 	// path is the local filesystem path to the object identified by the
 	// object name suffix.
 	path string
 	// state holds the state shared across different binary repository
 	// invocations.
 	state *state
-	// suffix is the suffix of the current invocation that is assumed to
-	// be used as a relative object name to identify a binary.
+	// suffix is the name of the binary object.
 	suffix string
 }
 
@@ -63,20 +62,18 @@
 	Size:     binary.MissingSize,
 }
 
-// newInvoker is the invoker factory.
-func newInvoker(state *state, suffix string) *invoker {
-	return &invoker{
+// newBinaryService returns a new Binary service implementation.
+func newBinaryService(state *state, suffix string) *binaryService {
+	return &binaryService{
 		path:   state.dir(suffix),
 		state:  state,
 		suffix: suffix,
 	}
 }
 
-// BINARY INTERFACE IMPLEMENTATION
-
 const bufferLength = 4096
 
-func (i *invoker) Create(_ ipc.ServerContext, nparts int32) error {
+func (i *binaryService) Create(_ ipc.ServerContext, nparts int32) error {
 	vlog.Infof("%v.Create(%v)", i.suffix, nparts)
 	if nparts < 1 {
 		return errInvalidParts
@@ -119,7 +116,7 @@
 	return nil
 }
 
-func (i *invoker) Delete(context ipc.ServerContext) error {
+func (i *binaryService) Delete(context ipc.ServerContext) error {
 	vlog.Infof("%v.Delete()", i.suffix)
 	if _, err := os.Stat(i.path); err != nil {
 		if os.IsNotExist(err) {
@@ -157,7 +154,7 @@
 	return nil
 }
 
-func (i *invoker) Download(context repository.BinaryDownloadContext, part int32) error {
+func (i *binaryService) Download(context repository.BinaryDownloadContext, part int32) error {
 	vlog.Infof("%v.Download(%v)", i.suffix, part)
 	path := i.generatePartPath(int(part))
 	if err := checksumExists(path); err != nil {
@@ -189,13 +186,13 @@
 	return nil
 }
 
-func (i *invoker) DownloadURL(ipc.ServerContext) (string, int64, error) {
+func (i *binaryService) DownloadURL(ipc.ServerContext) (string, int64, error) {
 	vlog.Infof("%v.DownloadURL()", i.suffix)
 	// TODO(jsimsa): Implement.
 	return "", 0, nil
 }
 
-func (i *invoker) Stat(ipc.ServerContext) ([]binary.PartInfo, error) {
+func (i *binaryService) Stat(ipc.ServerContext) ([]binary.PartInfo, error) {
 	vlog.Infof("%v.Stat()", i.suffix)
 	result := make([]binary.PartInfo, 0)
 	parts, err := getParts(i.path)
@@ -228,7 +225,7 @@
 	return result, nil
 }
 
-func (i *invoker) Upload(context repository.BinaryUploadContext, part int32) error {
+func (i *binaryService) Upload(context repository.BinaryUploadContext, part int32) error {
 	vlog.Infof("%v.Upload(%v)", i.suffix, part)
 	path, suffix := i.generatePartPath(int(part)), ""
 	err := checksumExists(path)
diff --git a/services/mgmt/build/buildd/main.go b/services/mgmt/build/buildd/main.go
index 09f7070..bba50c4 100644
--- a/services/mgmt/build/buildd/main.go
+++ b/services/mgmt/build/buildd/main.go
@@ -35,7 +35,7 @@
 		vlog.Errorf("Listen(%s) failed: %v", roaming.ListenSpec, err)
 		return
 	}
-	if err := server.Serve(*name, build.BuilderServer(impl.NewInvoker(*gobin, *goroot)), vflag.NewAuthorizerOrDie()); err != nil {
+	if err := server.Serve(*name, build.BuilderServer(impl.NewBuilderService(*gobin, *goroot)), vflag.NewAuthorizerOrDie()); err != nil {
 		vlog.Errorf("Serve(%v) failed: %v", *name, err)
 		return
 	}
diff --git a/services/mgmt/build/impl/impl_test.go b/services/mgmt/build/impl/impl_test.go
index 2c07891..3878aba 100644
--- a/services/mgmt/build/impl/impl_test.go
+++ b/services/mgmt/build/impl/impl_test.go
@@ -57,7 +57,7 @@
 		t.Fatalf("Listen(%s) failed: %v", profiles.LocalListenSpec, err)
 	}
 	unpublished := ""
-	if err := server.Serve(unpublished, build.BuilderServer(NewInvoker(gobin, goroot)), nil); err != nil {
+	if err := server.Serve(unpublished, build.BuilderServer(NewBuilderService(gobin, goroot)), nil); err != nil {
 		t.Fatalf("Serve(%q) failed: %v", unpublished, err)
 	}
 	name := "/" + endpoint.String()
diff --git a/services/mgmt/build/impl/invoker.go b/services/mgmt/build/impl/service.go
similarity index 87%
rename from services/mgmt/build/impl/invoker.go
rename to services/mgmt/build/impl/service.go
index fc798ac..6d723b8 100644
--- a/services/mgmt/build/impl/invoker.go
+++ b/services/mgmt/build/impl/service.go
@@ -21,28 +21,26 @@
 	errInternalError = verror.Internalf("internal error")
 )
 
-// invoker holds the state of a build server invocation.
-type invoker struct {
+// builderService implements the Builder server interface.
+type builderService struct {
 	// Path to the binary and the value of the GOROOT environment variable.
 	gobin, goroot string
 }
 
-// NewInvoker is the invoker factory.
-func NewInvoker(gobin, goroot string) *invoker {
-	return &invoker{
+// NewBuilderService returns a new Build service implementation.
+func NewBuilderService(gobin, goroot string) *builderService {
+	return &builderService{
 		gobin:  gobin,
 		goroot: goroot,
 	}
 }
 
-// BUILD INTERFACE IMPLEMENTATION
-
 // TODO(jsimsa): Add support for building for a specific profile
 // specified as a suffix the Build().
 //
 // TODO(jsimsa): Analyze the binary files for shared library
 // dependencies and ship these back.
-func (i *invoker) Build(ctx build.BuilderBuildContext, arch build.Architecture, opsys build.OperatingSystem) ([]byte, error) {
+func (i *builderService) Build(ctx build.BuilderBuildContext, arch build.Architecture, opsys build.OperatingSystem) ([]byte, error) {
 	vlog.VI(1).Infof("Build(%v, %v) called.", arch, opsys)
 	dir, prefix := "", ""
 	dirPerm, filePerm := os.FileMode(0700), os.FileMode(0600)
@@ -120,7 +118,7 @@
 	return output.Bytes(), nil
 }
 
-func (i *invoker) Describe(_ ipc.ServerContext, name string) (binary.Description, error) {
+func (i *builderService) Describe(_ ipc.ServerContext, name string) (binary.Description, error) {
 	// TODO(jsimsa): Implement.
 	return binary.Description{}, nil
 }
diff --git a/services/mgmt/node/impl/app_invoker.go b/services/mgmt/node/impl/app_service.go
similarity index 96%
rename from services/mgmt/node/impl/app_invoker.go
rename to services/mgmt/node/impl/app_service.go
index a3e89b5..f64e908 100644
--- a/services/mgmt/node/impl/app_invoker.go
+++ b/services/mgmt/node/impl/app_service.go
@@ -185,8 +185,8 @@
 	startLock sync.Mutex
 }
 
-// appInvoker holds the state of an application-related method invocation.
-type appInvoker struct {
+// appService implements the Node manager's Application interface.
+type appService struct {
 	callback *callbackState
 	config   *iconfig.State
 	// suffix contains the name components of the current invocation name
@@ -362,7 +362,7 @@
 	return writeACLs(aclData, aclSig, aclDir, acl)
 }
 
-func (i *appInvoker) Install(call ipc.ServerContext, applicationVON string) (string, error) {
+func (i *appService) Install(call ipc.ServerContext, applicationVON string) (string, error) {
 	if len(i.suffix) > 0 {
 		return "", errInvalidSuffix
 	}
@@ -399,12 +399,12 @@
 	return naming.Join(envelope.Title, installationID), nil
 }
 
-func (*appInvoker) Refresh(ipc.ServerContext) error {
+func (*appService) Refresh(ipc.ServerContext) error {
 	// TODO(jsimsa): Implement.
 	return nil
 }
 
-func (*appInvoker) Restart(ipc.ServerContext) error {
+func (*appService) Restart(ipc.ServerContext) error {
 	// TODO(jsimsa): Implement.
 	return nil
 }
@@ -550,7 +550,7 @@
 // installation referred to by the invoker's suffix.  Returns an error if the
 // suffix does not name an installation or if the named installation does not
 // exist.
-func (i *appInvoker) installationDir() (string, error) {
+func (i *appService) installationDir() (string, error) {
 	return installationDirCore(i.suffix, i.config.Root)
 }
 
@@ -575,7 +575,7 @@
 }
 
 // newInstance sets up the directory for a new application instance.
-func (i *appInvoker) newInstance(call ipc.ServerContext) (string, string, error) {
+func (i *appService) newInstance(call ipc.ServerContext) (string, string, error) {
 	installationDir, err := i.installationDir()
 	if err != nil {
 		return "", "", err
@@ -718,7 +718,7 @@
 	return cmd, nil
 }
 
-func (i *appInvoker) startCmd(instanceDir string, cmd *exec.Cmd) error {
+func (i *appService) startCmd(instanceDir string, cmd *exec.Cmd) error {
 	info, err := loadInstanceInfo(instanceDir)
 	if err != nil {
 		return err
@@ -804,7 +804,7 @@
 	return nil
 }
 
-func (i *appInvoker) run(instanceDir, systemName string) error {
+func (i *appService) run(instanceDir, systemName string) error {
 	if err := transitionInstance(instanceDir, suspended, starting); err != nil {
 		return err
 	}
@@ -820,7 +820,7 @@
 	return transitionInstance(instanceDir, starting, started)
 }
 
-func (i *appInvoker) Start(call ipc.ServerContext) ([]string, error) {
+func (i *appService) Start(call ipc.ServerContext) ([]string, error) {
 	helper := i.config.Helper
 	instanceDir, instanceID, err := i.newInstance(call)
 
@@ -865,11 +865,11 @@
 // instanceDir returns the path to the directory containing the app instance
 // referred to by the invoker's suffix, as well as the corresponding stopped
 // instance dir.  Returns an error if the suffix does not name an instance.
-func (i *appInvoker) instanceDir() (string, error) {
+func (i *appService) instanceDir() (string, error) {
 	return instanceDir(i.config.Root, i.suffix)
 }
 
-func (i *appInvoker) Resume(call ipc.ServerContext) error {
+func (i *appService) Resume(call ipc.ServerContext) error {
 	instanceDir, err := i.instanceDir()
 	if err != nil {
 		return err
@@ -925,7 +925,7 @@
 
 // TODO(caprita): implement deadline for Stop.
 
-func (i *appInvoker) Stop(_ ipc.ServerContext, deadline uint32) error {
+func (i *appService) Stop(_ ipc.ServerContext, deadline uint32) error {
 	instanceDir, err := i.instanceDir()
 	if err != nil {
 		return err
@@ -943,7 +943,7 @@
 	return transitionInstance(instanceDir, stopping, stopped)
 }
 
-func (i *appInvoker) Suspend(ipc.ServerContext) error {
+func (i *appService) Suspend(ipc.ServerContext) error {
 	instanceDir, err := i.instanceDir()
 	if err != nil {
 		return err
@@ -958,7 +958,7 @@
 	return transitionInstance(instanceDir, suspending, suspended)
 }
 
-func (i *appInvoker) Uninstall(ipc.ServerContext) error {
+func (i *appService) Uninstall(ipc.ServerContext) error {
 	installationDir, err := i.installationDir()
 	if err != nil {
 		return err
@@ -966,7 +966,7 @@
 	return transitionInstallation(installationDir, active, uninstalled)
 }
 
-func (i *appInvoker) Update(ipc.ServerContext) error {
+func (i *appService) Update(ipc.ServerContext) error {
 	installationDir, err := i.installationDir()
 	if err != nil {
 		return err
@@ -1016,12 +1016,12 @@
 	return nil
 }
 
-func (*appInvoker) UpdateTo(_ ipc.ServerContext, von string) error {
+func (*appService) UpdateTo(_ ipc.ServerContext, von string) error {
 	// TODO(jsimsa): Implement.
 	return nil
 }
 
-func (i *appInvoker) Revert(ipc.ServerContext) error {
+func (i *appService) Revert(ipc.ServerContext) error {
 	installationDir, err := i.installationDir()
 	if err != nil {
 		return err
@@ -1086,7 +1086,7 @@
 	}
 }
 
-func (i *appInvoker) scanEnvelopes(tree *treeNode, appDir string) {
+func (i *appService) scanEnvelopes(tree *treeNode, appDir string) {
 	// Find all envelopes, extract installID.
 	envGlob := []string{i.config.Root, appDir, "installation-*", "*", "envelope"}
 	envelopes, err := filepath.Glob(filepath.Join(envGlob...))
@@ -1111,7 +1111,7 @@
 	return
 }
 
-func (i *appInvoker) scanInstances(tree *treeNode) {
+func (i *appService) scanInstances(tree *treeNode) {
 	if len(i.suffix) < 2 {
 		return
 	}
@@ -1134,7 +1134,7 @@
 	return
 }
 
-func (i *appInvoker) scanInstance(tree *treeNode, title, instanceDir string) {
+func (i *appService) scanInstance(tree *treeNode, title, instanceDir string) {
 	if _, err := loadInstanceInfo(instanceDir); err != nil {
 		return
 	}
@@ -1154,7 +1154,7 @@
 	}
 }
 
-func (i *appInvoker) VGlobChildren() ([]string, error) {
+func (i *appService) VGlobChildren() ([]string, error) {
 	tree := newTreeNode()
 	switch len(i.suffix) {
 	case 0:
@@ -1208,7 +1208,7 @@
 
 // TODO(rjkroege): Consider maintaining an in-memory ACL cache.
 // TODO(rjkroege): Excise the idea of the key. Use the dir instead.
-func (i *appInvoker) SetACL(_ ipc.ServerContext, acl security.ACL, etag string) error {
+func (i *appService) SetACL(_ ipc.ServerContext, acl security.ACL, etag string) error {
 	dir, err := dirFromSuffix(i.suffix, i.config.Root)
 	if err != nil {
 		return err
@@ -1216,7 +1216,7 @@
 	return setAppACL(i.locks, dir, dir, acl, etag)
 }
 
-func (i *appInvoker) GetACL(_ ipc.ServerContext) (acl security.ACL, etag string, err error) {
+func (i *appService) GetACL(_ ipc.ServerContext) (acl security.ACL, etag string, err error) {
 	dir, err := dirFromSuffix(i.suffix, i.config.Root)
 	if err != nil {
 		return security.ACL{}, "", err
diff --git a/services/mgmt/node/impl/config_invoker.go b/services/mgmt/node/impl/config_service.go
similarity index 95%
rename from services/mgmt/node/impl/config_invoker.go
rename to services/mgmt/node/impl/config_service.go
index 97ccc35..609e1c6 100644
--- a/services/mgmt/node/impl/config_invoker.go
+++ b/services/mgmt/node/impl/config_service.go
@@ -114,15 +114,15 @@
 	delete(c.channels, id)
 }
 
-// configInvoker holds the state of a config service invocation.
-type configInvoker struct {
+// configService implements the Node manager's Config interface.
+type configService struct {
 	callback *callbackState
 	// Suffix contains an identifier for the channel corresponding to the
 	// request.
 	suffix string
 }
 
-func (i *configInvoker) Set(_ ipc.ServerContext, key, value string) error {
+func (i *configService) Set(_ ipc.ServerContext, key, value string) error {
 	id := i.suffix
 	i.callback.Lock()
 	if _, ok := i.callback.channels[id]; !ok {
diff --git a/services/mgmt/node/impl/dispatcher.go b/services/mgmt/node/impl/dispatcher.go
index d78f6ff..be18829 100644
--- a/services/mgmt/node/impl/dispatcher.go
+++ b/services/mgmt/node/impl/dispatcher.go
@@ -357,7 +357,7 @@
 	// prefix.
 	switch components[0] {
 	case nodeSuffix:
-		receiver := node.NodeServer(&nodeInvoker{
+		receiver := node.NodeServer(&nodeService{
 			callback: d.internal.callback,
 			updating: d.internal.updating,
 			config:   d.config,
@@ -366,10 +366,10 @@
 		})
 		return receiver, d.auth, nil
 	case appsSuffix:
-		// Requests to apps/*/*/*/logs are handled locally by LogFileInvoker.
+		// Requests to apps/*/*/*/logs are handled locally by LogFileServer.
 		// Requests to apps/*/*/*/pprof are proxied to the apps' __debug/pprof object.
 		// Requests to apps/*/*/*/stats are proxied to the apps' __debug/stats object.
-		// Everything else is handled by appInvoker.
+		// Everything else is handled by the Application server.
 		if len(components) >= 5 {
 			appInstanceDir, err := instanceDir(d.config.Root, components[1:4])
 			if err != nil {
@@ -406,7 +406,7 @@
 		if err != nil {
 			return nil, nil, err
 		}
-		receiver := node.ApplicationServer(&appInvoker{
+		receiver := node.ApplicationServer(&appService{
 			callback:      d.internal.callback,
 			config:        d.config,
 			suffix:        components[1:],
@@ -424,7 +424,7 @@
 		if len(components) != 2 {
 			return nil, nil, errInvalidSuffix
 		}
-		receiver := inode.ConfigServer(&configInvoker{
+		receiver := inode.ConfigServer(&configService{
 			callback: d.internal.callback,
 			suffix:   components[1],
 		})
diff --git a/services/mgmt/node/impl/node_invoker.go b/services/mgmt/node/impl/node_service.go
similarity index 88%
rename from services/mgmt/node/impl/node_invoker.go
rename to services/mgmt/node/impl/node_service.go
index eeed7a4..1ddf4da 100644
--- a/services/mgmt/node/impl/node_invoker.go
+++ b/services/mgmt/node/impl/node_service.go
@@ -84,8 +84,8 @@
 	u.updatingMutex.Unlock()
 }
 
-// nodeInvoker holds the state of a node manager method invocation.
-type nodeInvoker struct {
+// nodeService implements the Node manager's Node interface.
+type nodeService struct {
 	updating *updatingState
 	callback *callbackState
 	config   *config.State
@@ -93,7 +93,7 @@
 	uat      BlessingSystemAssociationStore
 }
 
-func (i *nodeInvoker) Claim(call ipc.ServerContext) error {
+func (i *nodeService) Claim(call ipc.ServerContext) error {
 	// Get the blessing to be used by the claimant.
 	blessings := call.Blessings()
 	if blessings == nil {
@@ -102,7 +102,7 @@
 	return i.disp.claimNodeManager(blessings.ForContext(call), blessings)
 }
 
-func (*nodeInvoker) Describe(ipc.ServerContext) (node.Description, error) {
+func (*nodeService) Describe(ipc.ServerContext) (node.Description, error) {
 	empty := node.Description{}
 	nodeProfile, err := computeNodeProfile()
 	if err != nil {
@@ -116,7 +116,7 @@
 	return result, nil
 }
 
-func (*nodeInvoker) IsRunnable(_ ipc.ServerContext, description binary.Description) (bool, error) {
+func (*nodeService) IsRunnable(_ ipc.ServerContext, description binary.Description) (bool, error) {
 	nodeProfile, err := computeNodeProfile()
 	if err != nil {
 		return false, err
@@ -133,14 +133,14 @@
 	return len(result.Profiles) > 0, nil
 }
 
-func (*nodeInvoker) Reset(call ipc.ServerContext, deadline uint64) error {
+func (*nodeService) Reset(call ipc.ServerContext, deadline uint64) error {
 	// TODO(jsimsa): Implement.
 	return nil
 }
 
 // getCurrentFileInfo returns the os.FileInfo for both the symbolic link
 // CurrentLink, and the node script in the workspace that this link points to.
-func (i *nodeInvoker) getCurrentFileInfo() (os.FileInfo, string, error) {
+func (i *nodeService) getCurrentFileInfo() (os.FileInfo, string, error) {
 	path := i.config.CurrentLink
 	link, err := os.Lstat(path)
 	if err != nil {
@@ -155,7 +155,7 @@
 	return link, scriptPath, nil
 }
 
-func (i *nodeInvoker) revertNodeManager() error {
+func (i *nodeService) revertNodeManager() error {
 	if err := updateLink(i.config.Previous, i.config.CurrentLink); err != nil {
 		return err
 	}
@@ -163,7 +163,7 @@
 	return nil
 }
 
-func (i *nodeInvoker) newLogfile(prefix string) (*os.File, error) {
+func (i *nodeService) newLogfile(prefix string) (*os.File, error) {
 	d := filepath.Join(i.config.Root, "node_test_logs")
 	if _, err := os.Stat(d); err != nil {
 		if err := os.MkdirAll(d, 0700); err != nil {
@@ -179,7 +179,7 @@
 
 // TODO(cnicolaou): would this be better implemented using the modules
 // framework now that it exists?
-func (i *nodeInvoker) testNodeManager(ctx context.T, workspace string, envelope *application.Envelope) error {
+func (i *nodeService) testNodeManager(ctx context.T, workspace string, envelope *application.Envelope) error {
 	path := filepath.Join(workspace, "noded.sh")
 	cmd := exec.Command(path)
 
@@ -313,7 +313,7 @@
 	return nil
 }
 
-func (i *nodeInvoker) updateNodeManager(ctx context.T) error {
+func (i *nodeService) updateNodeManager(ctx context.T) error {
 	if len(i.config.Origin) == 0 {
 		return errUpdateNoOp
 	}
@@ -381,25 +381,25 @@
 	return nil
 }
 
-func (*nodeInvoker) Install(ipc.ServerContext, string) (string, error) {
+func (*nodeService) Install(ipc.ServerContext, string) (string, error) {
 	return "", errInvalidSuffix
 }
 
-func (*nodeInvoker) Refresh(ipc.ServerContext) error {
+func (*nodeService) Refresh(ipc.ServerContext) error {
 	// TODO(jsimsa): Implement.
 	return nil
 }
 
-func (*nodeInvoker) Restart(ipc.ServerContext) error {
+func (*nodeService) Restart(ipc.ServerContext) error {
 	// TODO(jsimsa): Implement.
 	return nil
 }
 
-func (*nodeInvoker) Resume(ipc.ServerContext) error {
+func (*nodeService) Resume(ipc.ServerContext) error {
 	return errInvalidSuffix
 }
 
-func (i *nodeInvoker) Revert(call ipc.ServerContext) error {
+func (i *nodeService) Revert(call ipc.ServerContext) error {
 	if i.config.Previous == "" {
 		return errUpdateNoOp
 	}
@@ -414,24 +414,24 @@
 	return err
 }
 
-func (*nodeInvoker) Start(ipc.ServerContext) ([]string, error) {
+func (*nodeService) Start(ipc.ServerContext) ([]string, error) {
 	return nil, errInvalidSuffix
 }
 
-func (*nodeInvoker) Stop(ipc.ServerContext, uint32) error {
+func (*nodeService) Stop(ipc.ServerContext, uint32) error {
 	return errInvalidSuffix
 }
 
-func (*nodeInvoker) Suspend(ipc.ServerContext) error {
+func (*nodeService) Suspend(ipc.ServerContext) error {
 	// TODO(jsimsa): Implement.
 	return nil
 }
 
-func (*nodeInvoker) Uninstall(ipc.ServerContext) error {
+func (*nodeService) Uninstall(ipc.ServerContext) error {
 	return errInvalidSuffix
 }
 
-func (i *nodeInvoker) Update(ipc.ServerContext) error {
+func (i *nodeService) Update(ipc.ServerContext) error {
 	ctx, cancel := rt.R().NewContext().WithTimeout(time.Minute)
 	defer cancel()
 
@@ -447,16 +447,16 @@
 	return err
 }
 
-func (*nodeInvoker) UpdateTo(ipc.ServerContext, string) error {
+func (*nodeService) UpdateTo(ipc.ServerContext, string) error {
 	// TODO(jsimsa): Implement.
 	return nil
 }
 
-func (i *nodeInvoker) SetACL(_ ipc.ServerContext, acl security.ACL, etag string) error {
+func (i *nodeService) SetACL(_ ipc.ServerContext, acl security.ACL, etag string) error {
 	return i.disp.setACL(acl, etag, true /* store ACL on disk */)
 }
 
-func (i *nodeInvoker) GetACL(_ ipc.ServerContext) (acl security.ACL, etag string, err error) {
+func (i *nodeService) GetACL(_ ipc.ServerContext) (acl security.ACL, etag string, err error) {
 	return i.disp.getACL()
 }
 
@@ -473,7 +473,7 @@
 
 // TODO(rjkroege): Make it possible for users on the same system to also
 // associate their accounts with their identities.
-func (i *nodeInvoker) AssociateAccount(call ipc.ServerContext, identityNames []string, accountName string) error {
+func (i *nodeService) AssociateAccount(call ipc.ServerContext, identityNames []string, accountName string) error {
 	if err := sameMachineCheck(call); err != nil {
 		return err
 	}
@@ -486,7 +486,7 @@
 	}
 }
 
-func (i *nodeInvoker) ListAssociations(call ipc.ServerContext) (associations []node.Association, err error) {
+func (i *nodeService) ListAssociations(call ipc.ServerContext) (associations []node.Association, err error) {
 	// Temporary code. Dump this.
 	vlog.VI(2).Infof("ListAssociations given blessings: %v\n", call.RemoteBlessings().ForContext(call))
 
diff --git a/services/mgmt/profile/impl/dispatcher.go b/services/mgmt/profile/impl/dispatcher.go
index ab4dcf2..6c28885 100644
--- a/services/mgmt/profile/impl/dispatcher.go
+++ b/services/mgmt/profile/impl/dispatcher.go
@@ -30,5 +30,5 @@
 // DISPATCHER INTERFACE IMPLEMENTATION
 
 func (d *dispatcher) Lookup(suffix, method string) (interface{}, security.Authorizer, error) {
-	return repository.ProfileServer(NewInvoker(d.store, d.storeRoot, suffix)), d.auth, nil
+	return repository.ProfileServer(NewProfileService(d.store, d.storeRoot, suffix)), d.auth, nil
 }
diff --git a/services/mgmt/profile/impl/invoker.go b/services/mgmt/profile/impl/service.go
similarity index 74%
rename from services/mgmt/profile/impl/invoker.go
rename to services/mgmt/profile/impl/service.go
index 2b49703..a514636 100644
--- a/services/mgmt/profile/impl/invoker.go
+++ b/services/mgmt/profile/impl/service.go
@@ -11,15 +11,13 @@
 	"veyron.io/veyron/veyron2/vlog"
 )
 
-// invoker holds the profile repository invocation.
-type invoker struct {
+// profileService implements the Profile server interface.
+type profileService struct {
 	// store is the storage server used for storing profile data.
 	store *fs.Memstore
 	// storeRoot is a name in the Store under which all data will be stored.
 	storeRoot string
-	// suffix is the suffix of the current invocation that is assumed to
-	// be used as a relative object name to identify a profile
-	// specification.
+	// suffix is the name of the profile specification.
 	suffix string
 }
 
@@ -28,14 +26,14 @@
 	errOperationFailed = errors.New("operation failed")
 )
 
-// NewInvoker is the invoker factory.
-func NewInvoker(store *fs.Memstore, storeRoot, suffix string) *invoker {
-	return &invoker{store: store, storeRoot: storeRoot, suffix: suffix}
+// NewProfileService returns a new Profile service implementation.
+func NewProfileService(store *fs.Memstore, storeRoot, suffix string) *profileService {
+	return &profileService{store: store, storeRoot: storeRoot, suffix: suffix}
 }
 
 // STORE MANAGEMENT INTERFACE IMPLEMENTATION
 
-func (i *invoker) Put(context ipc.ServerContext, profile profile.Specification) error {
+func (i *profileService) Put(context ipc.ServerContext, profile profile.Specification) error {
 	vlog.VI(0).Infof("%v.Put(%v)", i.suffix, profile)
 	// Transaction is rooted at "", so tname == tid.
 	i.store.Lock()
@@ -55,7 +53,7 @@
 	return nil
 }
 
-func (i *invoker) Remove(context ipc.ServerContext) error {
+func (i *profileService) Remove(context ipc.ServerContext) error {
 	vlog.VI(0).Infof("%v.Remove()", i.suffix)
 	i.store.Lock()
 	defer i.store.Unlock()
@@ -84,7 +82,7 @@
 
 // PROFILE INTERACE IMPLEMENTATION
 
-func (i *invoker) lookup(context ipc.ServerContext) (profile.Specification, error) {
+func (i *profileService) lookup(context ipc.ServerContext) (profile.Specification, error) {
 	empty := profile.Specification{}
 	path := naming.Join("/profiles", i.suffix)
 
@@ -102,7 +100,7 @@
 	return s, nil
 }
 
-func (i *invoker) Label(context ipc.ServerContext) (string, error) {
+func (i *profileService) Label(context ipc.ServerContext) (string, error) {
 	vlog.VI(0).Infof("%v.Label()", i.suffix)
 	s, err := i.lookup(context)
 	if err != nil {
@@ -111,7 +109,7 @@
 	return s.Label, nil
 }
 
-func (i *invoker) Description(context ipc.ServerContext) (string, error) {
+func (i *profileService) Description(context ipc.ServerContext) (string, error) {
 	vlog.VI(0).Infof("%v.Description()", i.suffix)
 	s, err := i.lookup(context)
 	if err != nil {
@@ -120,7 +118,7 @@
 	return s.Description, nil
 }
 
-func (i *invoker) Specification(context ipc.ServerContext) (profile.Specification, error) {
+func (i *profileService) Specification(context ipc.ServerContext) (profile.Specification, error) {
 	vlog.VI(0).Infof("%v.Specification()", i.suffix)
 	return i.lookup(context)
 }