[VOL-3117] Read KV store data path prefix from an environment variable

- voltha-lib-go reads the KVStoreDataPrefix from env variable, so removed the command-line flag in voltha-go
- also removed unused corepair topic flag
Change-Id: Ibe8403bf187126b587a92cd9c58aa6d923f84cd0
diff --git a/go.mod b/go.mod
index 3f0daaa..3c7631c 100644
--- a/go.mod
+++ b/go.mod
@@ -6,7 +6,7 @@
 	github.com/gogo/protobuf v1.3.0
 	github.com/golang/protobuf v1.3.2
 	github.com/google/uuid v1.1.1
-	github.com/opencord/voltha-lib-go/v3 v3.1.10
+	github.com/opencord/voltha-lib-go/v3 v3.1.12
 	github.com/opencord/voltha-protos/v3 v3.3.3
 	github.com/phayes/freeport v0.0.0-20180830031419-95f893ade6f2
 	github.com/stretchr/testify v1.4.0
diff --git a/go.sum b/go.sum
index d66b654..98a0e62 100644
--- a/go.sum
+++ b/go.sum
@@ -196,8 +196,8 @@
 github.com/onsi/ginkgo v1.6.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE=
 github.com/onsi/gomega v1.4.2 h1:3mYCb7aPxS/RU7TI1y4rkEn1oKmPRjNJLNEXgw7MH2I=
 github.com/onsi/gomega v1.4.2/go.mod h1:ex+gbHU/CVuBBDIJjb2X0qEXbFg53c61hWP/1CpauHY=
-github.com/opencord/voltha-lib-go/v3 v3.1.10 h1:Wo4dsbjp2J2iOSarFSWUM8snqruQ5UoDLnzANMJd69s=
-github.com/opencord/voltha-lib-go/v3 v3.1.10/go.mod h1:26TG6ABl+ppP754YWhhgao9wKNL3SuUf/KztQcJFqrQ=
+github.com/opencord/voltha-lib-go/v3 v3.1.12 h1:ey3mpwB0mOuoK0cnonF6O0cNJlb75ZudqGpGz/50l4k=
+github.com/opencord/voltha-lib-go/v3 v3.1.12/go.mod h1:26TG6ABl+ppP754YWhhgao9wKNL3SuUf/KztQcJFqrQ=
 github.com/opencord/voltha-protos/v3 v3.3.3 h1:OO0H+YMxjLFQifoYXwBp1JN5rpEVMQnhGGEdP6pLrY0=
 github.com/opencord/voltha-protos/v3 v3.3.3/go.mod h1:nl1ETp5Iw3avxOaKD8BJlYY5wYI4KeV95aT1pL63nto=
 github.com/pascaldekloe/goe v0.0.0-20180627143212-57f6aae5913c/go.mod h1:lzWF7FIEvWOWxwDKqyGYQf6ZUaNfKdP144TG7ZOy1lc=
diff --git a/rw_core/config/config.go b/rw_core/config/config.go
index 5eeae01..e7e5c4f 100644
--- a/rw_core/config/config.go
+++ b/rw_core/config/config.go
@@ -37,7 +37,6 @@
 	defaultKVStoreHost               = "127.0.0.1"
 	defaultKVStorePort               = 2379 // Consul = 8500; Etcd = 2379
 	defaultKVTxnKeyDelTime           = 60
-	defaultKVStoreDataPrefix         = "service/voltha"
 	defaultLogLevel                  = "WARN"
 	defaultBanner                    = false
 	defaultDisplayVersionOnly        = false
@@ -52,7 +51,6 @@
 	defaultDefaultRequestTimeout     = 1000 * time.Millisecond
 	defaultCoreTimeout               = 1000 * time.Millisecond
 	defaultCoreBindingKey            = "voltha_backend_name"
-	defaultCorePairTopic             = "rwcore_1"
 	defaultMaxConnectionRetries      = -1 // retries forever
 	defaultConnectionRetryInterval   = 2 * time.Second
 	defaultLiveProbeInterval         = 60 * time.Second
@@ -76,7 +74,6 @@
 	KVStoreHost               string
 	KVStorePort               int
 	KVTxnKeyDelTime           int
-	KVStoreDataPrefix         string
 	CoreTopic                 string
 	LogLevel                  string
 	Banner                    bool
@@ -90,7 +87,6 @@
 	DefaultRequestTimeout     time.Duration
 	DefaultCoreTimeout        time.Duration
 	CoreBindingKey            string
-	CorePairTopic             string
 	MaxConnectionRetries      int
 	ConnectionRetryInterval   time.Duration
 	LiveProbeInterval         time.Duration
@@ -113,7 +109,6 @@
 		KVStoreTimeout:            defaultKVStoreTimeout,
 		KVStoreHost:               defaultKVStoreHost,
 		KVStorePort:               defaultKVStorePort,
-		KVStoreDataPrefix:         defaultKVStoreDataPrefix,
 		KVTxnKeyDelTime:           defaultKVTxnKeyDelTime,
 		CoreTopic:                 defaultCoreTopic,
 		LogLevel:                  defaultLogLevel,
@@ -128,7 +123,6 @@
 		LongRunningRequestTimeout: defaultLongRunningRequestTimeout,
 		DefaultCoreTimeout:        defaultCoreTimeout,
 		CoreBindingKey:            defaultCoreBindingKey,
-		CorePairTopic:             defaultCorePairTopic,
 		MaxConnectionRetries:      defaultMaxConnectionRetries,
 		ConnectionRetryInterval:   defaultConnectionRetryInterval,
 		LiveProbeInterval:         defaultLiveProbeInterval,
@@ -187,9 +181,6 @@
 	help = fmt.Sprintf("The time to wait before deleting a completed transaction key")
 	flag.IntVar(&(cf.KVTxnKeyDelTime), "kv_txn_delete_time", defaultKVTxnKeyDelTime, help)
 
-	help = fmt.Sprintf("KV store data prefix")
-	flag.StringVar(&(cf.KVStoreDataPrefix), "kv_store_data_prefix", defaultKVStoreDataPrefix, help)
-
 	help = fmt.Sprintf("Log level")
 	flag.StringVar(&(cf.LogLevel), "log_level", defaultLogLevel, help)
 
@@ -211,9 +202,6 @@
 	help = fmt.Sprintf("The name of the meta-key whose value is the rw-core group to which the ofagent is bound")
 	flag.StringVar(&(cf.CoreBindingKey), "core_binding_key", defaultCoreBindingKey, help)
 
-	help = fmt.Sprintf("Core pairing group topic")
-	flag.StringVar(&cf.CorePairTopic, "core_pair_topic", defaultCorePairTopic, help)
-
 	help = fmt.Sprintf("The number of retries to connect to a dependent component")
 	flag.IntVar(&(cf.MaxConnectionRetries), "max_connection_retries", defaultMaxConnectionRetries, help)
 
diff --git a/rw_core/core/api/grpc_nbi_handler_test.go b/rw_core/core/api/grpc_nbi_handler_test.go
index 543a19d..0fe877e 100755
--- a/rw_core/core/api/grpc_nbi_handler_test.go
+++ b/rw_core/core/api/grpc_nbi_handler_test.go
@@ -90,7 +90,7 @@
 	ctx, cancel := context.WithTimeout(context.Background(), 1*time.Second)
 	defer cancel()
 	cfg := config.NewRWCoreFlags()
-	cfg.CorePairTopic = "rw_core"
+	cfg.CoreTopic = "rw_core"
 	cfg.DefaultRequestTimeout = nb.defaultTimeout
 	cfg.DefaultCoreTimeout = nb.defaultTimeout
 	cfg.KVStorePort = nb.kvClientPort
@@ -109,8 +109,7 @@
 		Host:                    cfg.KVStoreHost,
 		Port:                    cfg.KVStorePort,
 		Timeout:                 cfg.KVStoreTimeout,
-		LivenessChannelInterval: cfg.LiveProbeInterval / 2,
-		PathPrefix:              cfg.KVStoreDataPrefix}
+		LivenessChannelInterval: cfg.LiveProbeInterval / 2}
 	nb.kmp = kafka.NewInterContainerProxy(
 		kafka.InterContainerHost(cfg.KafkaAdapterHost),
 		kafka.InterContainerPort(cfg.KafkaAdapterPort),
@@ -121,7 +120,7 @@
 	endpointMgr := kafka.NewEndpointManager(backend)
 	proxy := model.NewDBPath(backend)
 	nb.adapterMgr = adapter.NewAdapterManager(proxy, nb.coreInstanceID, nb.kClient)
-	nb.deviceMgr, nb.logicalDeviceMgr = device.NewManagers(proxy, nb.adapterMgr, nb.kmp, endpointMgr, cfg.CorePairTopic, nb.coreInstanceID, cfg.DefaultCoreTimeout)
+	nb.deviceMgr, nb.logicalDeviceMgr = device.NewManagers(proxy, nb.adapterMgr, nb.kmp, endpointMgr, cfg.CoreTopic, nb.coreInstanceID, cfg.DefaultCoreTimeout)
 	nb.adapterMgr.Start(ctx)
 
 	if err := nb.kmp.Start(); err != nil {
@@ -131,9 +130,6 @@
 	if err := nb.kmp.SubscribeWithRequestHandlerInterface(kafka.Topic{Name: cfg.CoreTopic}, requestProxy); err != nil {
 		logger.Fatalf("Cannot add request handler: %s", err)
 	}
-	if err := nb.kmp.SubscribeWithDefaultRequestHandler(kafka.Topic{Name: cfg.CorePairTopic}, kafka.OffsetNewest); err != nil {
-		logger.Fatalf("Cannot add default request handler: %s", err)
-	}
 }
 
 func (nb *NBTest) stopAll() {
diff --git a/rw_core/core/core.go b/rw_core/core/core.go
index 524b52c..0a76ca2 100644
--- a/rw_core/core/core.go
+++ b/rw_core/core/core.go
@@ -27,7 +27,6 @@
 	"github.com/opencord/voltha-go/rw_core/core/api"
 	"github.com/opencord/voltha-go/rw_core/core/device"
 	conf "github.com/opencord/voltha-lib-go/v3/pkg/config"
-	"github.com/opencord/voltha-lib-go/v3/pkg/db"
 	grpcserver "github.com/opencord/voltha-lib-go/v3/pkg/grpc"
 	"github.com/opencord/voltha-lib-go/v3/pkg/kafka"
 	"github.com/opencord/voltha-lib-go/v3/pkg/log"
@@ -84,17 +83,8 @@
 	cm := conf.NewConfigManager(kvClient, cf.KVStoreType, cf.KVStoreHost, cf.KVStorePort, cf.KVStoreTimeout)
 	go conf.StartLogLevelConfigProcessing(cm, ctx)
 
-	backend := &db.Backend{
-		Client:    kvClient,
-		StoreType: cf.KVStoreType,
-		Host:      cf.KVStoreHost,
-		Port:      cf.KVStorePort,
-		Timeout:   cf.KVStoreTimeout,
-		// Configure backend to push Liveness Status at least every (cf.LiveProbeInterval / 2) seconds
-		// so as to avoid trigger of Liveness check (due to Liveness timeout) when backend is alive
-		LivenessChannelInterval: cf.LiveProbeInterval / 2,
-		PathPrefix:              cf.KVStoreDataPrefix,
-	}
+	backend := cm.Backend
+	backend.LivenessChannelInterval = cf.LiveProbeInterval / 2
 
 	// wait until connection to KV Store is up
 	if err := waitUntilKVStoreReachableOrMaxTries(ctx, kvClient, cf.MaxConnectionRetries, cf.ConnectionRetryInterval); err != nil {
@@ -139,10 +129,10 @@
 
 	// create the core of the system, the device managers
 	endpointMgr := kafka.NewEndpointManager(backend)
-	deviceMgr, logicalDeviceMgr := device.NewManagers(dbPath, adapterMgr, kmp, endpointMgr, cf.CorePairTopic, id, cf.DefaultCoreTimeout)
+	deviceMgr, logicalDeviceMgr := device.NewManagers(dbPath, adapterMgr, kmp, endpointMgr, cf.CoreTopic, id, cf.DefaultCoreTimeout)
 
 	// register kafka RPC handler
-	registerAdapterRequestHandlers(kmp, deviceMgr, adapterMgr, cf.CoreTopic, cf.CorePairTopic)
+	registerAdapterRequestHandlers(kmp, deviceMgr, adapterMgr, cf.CoreTopic)
 
 	// start gRPC handler
 	grpcServer := grpcserver.NewGrpcServer(cf.GrpcHost, cf.GrpcPort, nil, false, probe.GetProbeFromContext(ctx))
diff --git a/rw_core/core/device/agent_test.go b/rw_core/core/device/agent_test.go
index 29d8062..cd49681 100755
--- a/rw_core/core/device/agent_test.go
+++ b/rw_core/core/device/agent_test.go
@@ -112,7 +112,7 @@
 
 func (dat *DATest) startCore(inCompeteMode bool) {
 	cfg := config.NewRWCoreFlags()
-	cfg.CorePairTopic = "rw_core"
+	cfg.CoreTopic = "rw_core"
 	cfg.DefaultRequestTimeout = dat.defaultTimeout
 	cfg.KVStorePort = dat.kvClientPort
 	cfg.InCompetingMode = inCompeteMode
@@ -129,8 +129,7 @@
 		Host:                    cfg.KVStoreHost,
 		Port:                    cfg.KVStorePort,
 		Timeout:                 cfg.KVStoreTimeout,
-		LivenessChannelInterval: cfg.LiveProbeInterval / 2,
-		PathPrefix:              cfg.KVStoreDataPrefix}
+		LivenessChannelInterval: cfg.LiveProbeInterval / 2}
 	dat.kmp = kafka.NewInterContainerProxy(
 		kafka.InterContainerHost(cfg.KafkaAdapterHost),
 		kafka.InterContainerPort(cfg.KafkaAdapterPort),
@@ -142,13 +141,13 @@
 	proxy := model.NewDBPath(backend)
 	dat.adapterMgr = adapter.NewAdapterManager(proxy, dat.coreInstanceID, dat.kClient)
 
-	dat.deviceMgr, dat.logicalDeviceMgr = NewManagers(proxy, dat.adapterMgr, dat.kmp, endpointMgr, cfg.CorePairTopic, dat.coreInstanceID, cfg.DefaultCoreTimeout)
+	dat.deviceMgr, dat.logicalDeviceMgr = NewManagers(proxy, dat.adapterMgr, dat.kmp, endpointMgr, cfg.CoreTopic, dat.coreInstanceID, cfg.DefaultCoreTimeout)
 	dat.adapterMgr.Start(context.Background())
 	if err = dat.kmp.Start(); err != nil {
 		logger.Fatal("Cannot start InterContainerProxy")
 	}
 
-	if err := dat.kmp.SubscribeWithDefaultRequestHandler(kafka.Topic{Name: cfg.CorePairTopic}, kafka.OffsetNewest); err != nil {
+	if err := dat.kmp.SubscribeWithDefaultRequestHandler(kafka.Topic{Name: cfg.CoreTopic}, kafka.OffsetNewest); err != nil {
 		logger.Fatalf("Cannot add default request handler: %s", err)
 	}
 
diff --git a/rw_core/core/device/logical_agent_test.go b/rw_core/core/device/logical_agent_test.go
index 77c4b7c..2649ee4 100644
--- a/rw_core/core/device/logical_agent_test.go
+++ b/rw_core/core/device/logical_agent_test.go
@@ -454,7 +454,7 @@
 
 func (lda *LDATest) startCore(inCompeteMode bool) {
 	cfg := config.NewRWCoreFlags()
-	cfg.CorePairTopic = "rw_core"
+	cfg.CoreTopic = "rw_core"
 	cfg.DefaultRequestTimeout = lda.defaultTimeout
 	cfg.KVStorePort = lda.kvClientPort
 	cfg.InCompetingMode = inCompeteMode
@@ -471,8 +471,7 @@
 		Host:                    cfg.KVStoreHost,
 		Port:                    cfg.KVStorePort,
 		Timeout:                 cfg.KVStoreTimeout,
-		LivenessChannelInterval: cfg.LiveProbeInterval / 2,
-		PathPrefix:              cfg.KVStoreDataPrefix}
+		LivenessChannelInterval: cfg.LiveProbeInterval / 2}
 	lda.kmp = kafka.NewInterContainerProxy(
 		kafka.InterContainerHost(cfg.KafkaAdapterHost),
 		kafka.InterContainerPort(cfg.KafkaAdapterPort),
@@ -484,7 +483,7 @@
 	proxy := model.NewDBPath(backend)
 	adapterMgr := adapter.NewAdapterManager(proxy, lda.coreInstanceID, lda.kClient)
 
-	lda.deviceMgr, lda.logicalDeviceMgr = NewManagers(proxy, adapterMgr, lda.kmp, endpointMgr, cfg.CorePairTopic, lda.coreInstanceID, cfg.DefaultCoreTimeout)
+	lda.deviceMgr, lda.logicalDeviceMgr = NewManagers(proxy, adapterMgr, lda.kmp, endpointMgr, cfg.CoreTopic, lda.coreInstanceID, cfg.DefaultCoreTimeout)
 	if err = lda.kmp.Start(); err != nil {
 		logger.Fatal("Cannot start InterContainerProxy")
 	}
diff --git a/rw_core/core/device/manager.go b/rw_core/core/device/manager.go
index 17ac266..c7af54a 100755
--- a/rw_core/core/device/manager.go
+++ b/rw_core/core/device/manager.go
@@ -60,11 +60,11 @@
 }
 
 //NewManagers creates the Manager and the Logical Manager.
-func NewManagers(dbPath *model.Path, adapterMgr *adapter.Manager, kmp kafka.InterContainerProxy, endpointMgr kafka.EndpointManager, corePairTopic, coreInstanceID string, defaultCoreTimeout time.Duration) (*Manager, *LogicalManager) {
+func NewManagers(dbPath *model.Path, adapterMgr *adapter.Manager, kmp kafka.InterContainerProxy, endpointMgr kafka.EndpointManager, coreTopic, coreInstanceID string, defaultCoreTimeout time.Duration) (*Manager, *LogicalManager) {
 	deviceMgr := &Manager{
 		rootDevices:             make(map[string]bool),
 		kafkaICProxy:            kmp,
-		adapterProxy:            remote.NewAdapterProxy(kmp, corePairTopic, endpointMgr),
+		adapterProxy:            remote.NewAdapterProxy(kmp, coreTopic, endpointMgr),
 		coreInstanceID:          coreInstanceID,
 		dbPath:                  dbPath,
 		dProxy:                  dbPath.Proxy("devices"),
diff --git a/rw_core/core/device/remote/adapter_proxy.go b/rw_core/core/device/remote/adapter_proxy.go
index f4579ef..4cbb363 100755
--- a/rw_core/core/device/remote/adapter_proxy.go
+++ b/rw_core/core/device/remote/adapter_proxy.go
@@ -18,6 +18,7 @@
 
 import (
 	"context"
+
 	"github.com/opencord/voltha-lib-go/v3/pkg/kafka"
 	"github.com/opencord/voltha-lib-go/v3/pkg/log"
 	ic "github.com/opencord/voltha-protos/v3/go/inter_container"
@@ -29,22 +30,22 @@
 type AdapterProxy struct {
 	kafka.EndpointManager
 	deviceTopicRegistered bool
-	corePairTopic         string
+	coreTopic             string
 	kafkaICProxy          kafka.InterContainerProxy
 }
 
 // NewAdapterProxy will return adapter proxy instance
-func NewAdapterProxy(kafkaProxy kafka.InterContainerProxy, corePairTopic string, endpointManager kafka.EndpointManager) *AdapterProxy {
+func NewAdapterProxy(kafkaProxy kafka.InterContainerProxy, coreTopic string, endpointManager kafka.EndpointManager) *AdapterProxy {
 	return &AdapterProxy{
 		EndpointManager:       endpointManager,
 		kafkaICProxy:          kafkaProxy,
-		corePairTopic:         corePairTopic,
+		coreTopic:             coreTopic,
 		deviceTopicRegistered: false,
 	}
 }
 
 func (ap *AdapterProxy) getCoreTopic() kafka.Topic {
-	return kafka.Topic{Name: ap.corePairTopic}
+	return kafka.Topic{Name: ap.coreTopic}
 }
 
 func (ap *AdapterProxy) getAdapterTopic(deviceID string, adapterType string) (*kafka.Topic, error) {
diff --git a/rw_core/core/kafka.go b/rw_core/core/kafka.go
index fcdf340..18b9ec8 100644
--- a/rw_core/core/kafka.go
+++ b/rw_core/core/kafka.go
@@ -147,18 +147,12 @@
 	}
 }
 
-func registerAdapterRequestHandlers(kmp kafka.InterContainerProxy, dMgr *device.Manager, aMgr *adapter.Manager, coreTopic, corePairTopic string) {
+func registerAdapterRequestHandlers(kmp kafka.InterContainerProxy, dMgr *device.Manager, aMgr *adapter.Manager, coreTopic string) {
 	requestProxy := api.NewAdapterRequestHandlerProxy(dMgr, aMgr)
 
 	// Register the broadcast topic to handle any core-bound broadcast requests
 	if err := kmp.SubscribeWithRequestHandlerInterface(kafka.Topic{Name: coreTopic}, requestProxy); err != nil {
 		logger.Fatalw("Failed-registering-broadcast-handler", log.Fields{"topic": coreTopic})
 	}
-
-	// Register the core-pair topic to handle core-bound requests destined to the core pair
-	if err := kmp.SubscribeWithDefaultRequestHandler(kafka.Topic{Name: corePairTopic}, kafka.OffsetNewest); err != nil {
-		logger.Fatalw("Failed-registering-pair-handler", log.Fields{"topic": corePairTopic})
-	}
-
 	logger.Info("request-handler-registered")
 }
diff --git a/vendor/github.com/opencord/voltha-lib-go/v3/pkg/config/configmanager.go b/vendor/github.com/opencord/voltha-lib-go/v3/pkg/config/configmanager.go
index c0915af..ef71b07 100644
--- a/vendor/github.com/opencord/voltha-lib-go/v3/pkg/config/configmanager.go
+++ b/vendor/github.com/opencord/voltha-lib-go/v3/pkg/config/configmanager.go
@@ -18,17 +18,19 @@
 import (
 	"context"
 	"fmt"
+	"os"
+	"strings"
+	"time"
+
 	"github.com/opencord/voltha-lib-go/v3/pkg/db"
 	"github.com/opencord/voltha-lib-go/v3/pkg/db/kvstore"
 	"github.com/opencord/voltha-lib-go/v3/pkg/log"
-	"strings"
-	"time"
 )
 
 const (
-	defaultkvStoreConfigPath = "config"
-	kvStoreDataPathPrefix    = "service/voltha"
-	kvStorePathSeparator     = "/"
+	defaultkvStoreConfigPath     = "config"
+	defaultkvStoreDataPathPrefix = "service/voltha"
+	kvStorePathSeparator         = "/"
 )
 
 // ConfigType represents the type for which config is created inside the kvstore
@@ -68,8 +70,9 @@
 // ConfigManager is a wrapper over Backend to maintain Configuration of voltha components
 // in kvstore based persistent storage
 type ConfigManager struct {
-	Backend             *db.Backend
-	KvStoreConfigPrefix string
+	Backend               *db.Backend
+	KVStoreConfigPrefix   string
+	KVStoreDataPathPrefix string
 }
 
 // ComponentConfig represents a category of configuration for a specific VOLTHA component type
@@ -94,23 +97,31 @@
 }
 
 func NewConfigManager(kvClient kvstore.Client, kvStoreType, kvStoreHost string, kvStorePort int, kvStoreTimeout time.Duration) *ConfigManager {
-
+	var kvStorePrefix string
+	if prefix, present := os.LookupEnv("KV_STORE_DATAPATH_PREFIX"); present {
+		kvStorePrefix = prefix
+		logger.Infow("KV_STORE_DATAPATH_PREFIX env variable is set, ", log.Fields{"kvStoreDataPathPrefix": kvStorePrefix})
+	} else {
+		kvStorePrefix = defaultkvStoreDataPathPrefix
+		logger.Infow("KV_STORE_DATAPATH_PREFIX env variable is not set, using default", log.Fields{"kvStoreDataPathPrefix": defaultkvStoreDataPathPrefix})
+	}
 	return &ConfigManager{
-		KvStoreConfigPrefix: defaultkvStoreConfigPath,
+		KVStoreConfigPrefix:   defaultkvStoreConfigPath,
+		KVStoreDataPathPrefix: kvStorePrefix,
 		Backend: &db.Backend{
 			Client:     kvClient,
 			StoreType:  kvStoreType,
 			Host:       kvStoreHost,
 			Port:       kvStorePort,
 			Timeout:    kvStoreTimeout,
-			PathPrefix: kvStoreDataPathPrefix,
+			PathPrefix: kvStorePrefix,
 		},
 	}
 }
 
 // RetrieveComponentList list the component Names for which loglevel is stored in kvstore
 func (c *ConfigManager) RetrieveComponentList(ctx context.Context, configType ConfigType) ([]string, error) {
-	data, err := c.Backend.List(ctx, c.KvStoreConfigPrefix)
+	data, err := c.Backend.List(ctx, c.KVStoreConfigPrefix)
 	if err != nil {
 		return nil, err
 	}
@@ -120,7 +131,7 @@
 	// For Example, recieved key would be <Backend Prefix Path>/<Config Prefix>/<Component Name>/<Config Type>/default and value \"DEBUG\"
 	// Then in default will be stored as PackageName,componentName as <Component Name> and DEBUG will be stored as value in List struct
 	ccPathPrefix := kvStorePathSeparator + configType.String() + kvStorePathSeparator
-	pathPrefix := kvStoreDataPathPrefix + kvStorePathSeparator + c.KvStoreConfigPrefix + kvStorePathSeparator
+	pathPrefix := c.KVStoreDataPathPrefix + kvStorePathSeparator + c.KVStoreConfigPrefix + kvStorePathSeparator
 	var list []string
 	keys := make(map[string]interface{})
 	for attr := range data {
@@ -153,7 +164,7 @@
 func (c *ComponentConfig) makeConfigPath() string {
 
 	cType := c.configType.String()
-	return c.cManager.KvStoreConfigPrefix + kvStorePathSeparator +
+	return c.cManager.KVStoreConfigPrefix + kvStorePathSeparator +
 		c.componentLabel + kvStorePathSeparator + cType
 }
 
diff --git a/vendor/modules.txt b/vendor/modules.txt
index dd88523..518c70f 100644
--- a/vendor/modules.txt
+++ b/vendor/modules.txt
@@ -99,7 +99,7 @@
 github.com/modern-go/concurrent
 # github.com/modern-go/reflect2 v1.0.1
 github.com/modern-go/reflect2
-# github.com/opencord/voltha-lib-go/v3 v3.1.10
+# github.com/opencord/voltha-lib-go/v3 v3.1.12
 github.com/opencord/voltha-lib-go/v3/pkg/adapters
 github.com/opencord/voltha-lib-go/v3/pkg/adapters/adapterif
 github.com/opencord/voltha-lib-go/v3/pkg/adapters/common