x/ref: Restructure debug,logreader,pprof,repository,stats,vtrace.

services/mgmt/debug          -> services/debug/debuglib/dispatcher.go
services/mgmt/logreader/impl -> services/logreader/logreaderlib
services/mgmt/pprof/impl     -> services/pprof/pproflib
services/mgmt/pprof/client   -> services/pprof/pproflib
services/mgmt/repository     -> services/repository
services/mgmt/stats          -> services/stats
services/mgmt/stats/impl     -> services/stats/statslib
services/mgmt/vtrace/impl    -> services/vtrace/vtracelib

Change-Id: I3dadc6ff0c07330a16d6db281bf7ed034bc9c45f
diff --git a/profiles/internal/rpc/debug_test.go b/profiles/internal/rpc/debug_test.go
index 74681ca..0e8e46e 100644
--- a/profiles/internal/rpc/debug_test.go
+++ b/profiles/internal/rpc/debug_test.go
@@ -19,7 +19,7 @@
 	"v.io/x/ref/lib/stats"
 	"v.io/x/ref/profiles/internal/rpc/stream/manager"
 	tnaming "v.io/x/ref/profiles/internal/testing/mocks/naming"
-	"v.io/x/ref/services/mgmt/debug"
+	"v.io/x/ref/services/debug/debuglib"
 	"v.io/x/ref/test/testutil"
 )
 
@@ -36,7 +36,7 @@
 	pclient.AddToRoots(bclient)                    // Client recognizes "server" as a root of blessings.
 	pclient.BlessingStore().Set(bclient, "server") // Client presents bclient to server
 
-	debugDisp := debug.NewDispatcher(vlog.Log.LogDir, nil)
+	debugDisp := debuglib.NewDispatcher(vlog.Log.LogDir, nil)
 
 	sm := manager.InternalNew(naming.FixedRoutingID(0x555555555))
 	defer sm.Shutdown()
diff --git a/profiles/internal/rt/runtime_test.go b/profiles/internal/rt/runtime_test.go
index fd07d04..dc4e23e 100644
--- a/profiles/internal/rt/runtime_test.go
+++ b/profiles/internal/rt/runtime_test.go
@@ -14,7 +14,7 @@
 
 	"v.io/x/ref/lib/flags"
 	"v.io/x/ref/profiles/internal/rt"
-	"v.io/x/ref/services/mgmt/debug"
+	"v.io/x/ref/services/debug/debuglib"
 	"v.io/x/ref/test/testutil"
 )
 
@@ -138,7 +138,7 @@
 	defer shutdown()
 
 	oldDebugDisp := r.GetReservedNameDispatcher(ctx)
-	newDebugDisp := debug.NewDispatcher(vlog.Log.LogDir, nil)
+	newDebugDisp := debuglib.NewDispatcher(vlog.Log.LogDir, nil)
 
 	nctx := r.SetReservedNameDispatcher(ctx, newDebugDisp)
 	debugDisp := r.GetReservedNameDispatcher(nctx)
diff --git a/profiles/roaming/roaminginit.go b/profiles/roaming/roaminginit.go
index b117402..9edddc6 100644
--- a/profiles/roaming/roaminginit.go
+++ b/profiles/roaming/roaminginit.go
@@ -33,7 +33,7 @@
 	_ "v.io/x/ref/profiles/internal/rpc/protocols/ws"
 	_ "v.io/x/ref/profiles/internal/rpc/protocols/wsh"
 	grt "v.io/x/ref/profiles/internal/rt"
-	"v.io/x/ref/services/mgmt/debug"
+	"v.io/x/ref/services/debug/debuglib"
 
 	// TODO(cnicolaou,ashankar): move this into flags.
 	sflag "v.io/x/ref/security/flag"
@@ -61,7 +61,7 @@
 		Addrs: rpc.ListenAddrs(lf.Addrs),
 		Proxy: lf.ListenProxy,
 	}
-	reservedDispatcher := debug.NewDispatcher(vlog.Log.LogDir, sflag.NewAuthorizerOrDie())
+	reservedDispatcher := debuglib.NewDispatcher(vlog.Log.LogDir, sflag.NewAuthorizerOrDie())
 
 	ac := appcycle.New()
 
diff --git a/profiles/static/staticinit.go b/profiles/static/staticinit.go
index fca56cd..8458777 100644
--- a/profiles/static/staticinit.go
+++ b/profiles/static/staticinit.go
@@ -21,7 +21,7 @@
 	_ "v.io/x/ref/profiles/internal/rpc/protocols/ws"
 	_ "v.io/x/ref/profiles/internal/rpc/protocols/wsh"
 	grt "v.io/x/ref/profiles/internal/rt"
-	"v.io/x/ref/services/mgmt/debug"
+	"v.io/x/ref/services/debug/debuglib"
 
 	// TODO(cnicolaou,ashankar): move this into flags.
 	sflag "v.io/x/ref/security/flag"
@@ -45,7 +45,7 @@
 		Addrs: rpc.ListenAddrs(lf.Addrs),
 		Proxy: lf.ListenProxy,
 	}
-	reservedDispatcher := debug.NewDispatcher(vlog.Log.LogDir, sflag.NewAuthorizerOrDie())
+	reservedDispatcher := debuglib.NewDispatcher(vlog.Log.LogDir, sflag.NewAuthorizerOrDie())
 
 	ac := appcycle.New()