diff --git a/VERSION b/VERSION
index 0d03cd4..005119b 100644
--- a/VERSION
+++ b/VERSION
@@ -1 +1 @@
-2.4.1-dev0
+2.4.1
diff --git a/go.mod b/go.mod
index c49c6d2..9fe8b7a 100755
--- 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.7
+	github.com/opencord/voltha-lib-go/v3 v3.1.9
 	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 930abf8..9c59be9 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.7 h1:hPaXrYkH/gaTW5CN7F8pyeCWXAay5SHXG78uMorcyPg=
-github.com/opencord/voltha-lib-go/v3 v3.1.7/go.mod h1:26TG6ABl+ppP754YWhhgao9wKNL3SuUf/KztQcJFqrQ=
+github.com/opencord/voltha-lib-go/v3 v3.1.9 h1:8Py2yDYDg956Tcv7r/oRdZGMaT1myvnL1en9HoptPRU=
+github.com/opencord/voltha-lib-go/v3 v3.1.9/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 39ba9ba..5eeae01 100644
--- a/rw_core/config/config.go
+++ b/rw_core/config/config.go
@@ -33,7 +33,7 @@
 	defaultKafkaClusterHost          = "127.0.0.1"
 	defaultKafkaClusterPort          = 9094
 	defaultKVStoreType               = EtcdStoreName
-	defaultKVStoreTimeout            = 5 //in seconds
+	defaultKVStoreTimeout            = 5 * time.Second
 	defaultKVStoreHost               = "127.0.0.1"
 	defaultKVStorePort               = 2379 // Consul = 8500; Etcd = 2379
 	defaultKVTxnKeyDelTime           = 60
@@ -72,7 +72,7 @@
 	KafkaClusterHost          string
 	KafkaClusterPort          int
 	KVStoreType               string
-	KVStoreTimeout            int // in seconds
+	KVStoreTimeout            time.Duration
 	KVStoreHost               string
 	KVStorePort               int
 	KVTxnKeyDelTime           int
@@ -176,7 +176,7 @@
 	flag.StringVar(&(cf.KVStoreType), "kv_store_type", defaultKVStoreType, help)
 
 	help = fmt.Sprintf("The default timeout when making a kv store request")
-	flag.IntVar(&(cf.KVStoreTimeout), "kv_store_request_timeout", defaultKVStoreTimeout, help)
+	flag.DurationVar(&(cf.KVStoreTimeout), "kv_store_request_timeout", defaultKVStoreTimeout, help)
 
 	help = fmt.Sprintf("KV store host")
 	flag.StringVar(&(cf.KVStoreHost), "kv_store_host", defaultKVStoreHost, help)
@@ -194,18 +194,13 @@
 	flag.StringVar(&(cf.LogLevel), "log_level", defaultLogLevel, help)
 
 	help = fmt.Sprintf("Timeout for long running request")
-	// TODO:  Change this code once all the params and helm charts have been changed to use the different type
-	var temp int64
-	flag.Int64Var(&temp, "timeout_long_request", defaultLongRunningRequestTimeout.Milliseconds(), help)
-	cf.LongRunningRequestTimeout = time.Duration(temp) * time.Millisecond
+	flag.DurationVar(&(cf.LongRunningRequestTimeout), "timeout_long_request", defaultLongRunningRequestTimeout, help)
 
 	help = fmt.Sprintf("Default timeout for regular request")
-	flag.Int64Var(&temp, "timeout_request", defaultDefaultRequestTimeout.Milliseconds(), help)
-	cf.DefaultRequestTimeout = time.Duration(temp) * time.Millisecond
+	flag.DurationVar(&(cf.DefaultRequestTimeout), "timeout_request", defaultDefaultRequestTimeout, help)
 
 	help = fmt.Sprintf("Default Core timeout")
-	flag.Int64Var(&temp, "core_timeout", defaultCoreTimeout.Milliseconds(), help)
-	cf.DefaultCoreTimeout = time.Duration(temp) * time.Millisecond
+	flag.DurationVar(&(cf.DefaultCoreTimeout), "core_timeout", defaultCoreTimeout, help)
 
 	help = fmt.Sprintf("Show startup banner log lines")
 	flag.BoolVar(&cf.Banner, "banner", defaultBanner, help)
diff --git a/rw_core/core/kv.go b/rw_core/core/kv.go
index 48b99e9..53db264 100644
--- a/rw_core/core/kv.go
+++ b/rw_core/core/kv.go
@@ -29,7 +29,7 @@
 	"google.golang.org/grpc/status"
 )
 
-func newKVClient(storeType string, address string, timeout int) (kvstore.Client, error) {
+func newKVClient(storeType string, address string, timeout time.Duration) (kvstore.Client, error) {
 	logger.Infow("kv-store-type", log.Fields{"store": storeType})
 	switch storeType {
 	case "consul":
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 0dafc7a..c0915af 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
@@ -22,6 +22,7 @@
 	"github.com/opencord/voltha-lib-go/v3/pkg/db/kvstore"
 	"github.com/opencord/voltha-lib-go/v3/pkg/log"
 	"strings"
+	"time"
 )
 
 const (
@@ -92,7 +93,7 @@
 	kvStoreEventChan chan *kvstore.Event
 }
 
-func NewConfigManager(kvClient kvstore.Client, kvStoreType, kvStoreHost string, kvStorePort, kvStoreTimeout int) *ConfigManager {
+func NewConfigManager(kvClient kvstore.Client, kvStoreType, kvStoreHost string, kvStorePort int, kvStoreTimeout time.Duration) *ConfigManager {
 
 	return &ConfigManager{
 		KvStoreConfigPrefix: defaultkvStoreConfigPath,
diff --git a/vendor/github.com/opencord/voltha-lib-go/v3/pkg/db/backend.go b/vendor/github.com/opencord/voltha-lib-go/v3/pkg/db/backend.go
index 55fda64..20bacad 100644
--- a/vendor/github.com/opencord/voltha-lib-go/v3/pkg/db/backend.go
+++ b/vendor/github.com/opencord/voltha-lib-go/v3/pkg/db/backend.go
@@ -21,7 +21,6 @@
 	"errors"
 	"fmt"
 	"strconv"
-	"sync"
 	"time"
 
 	"github.com/opencord/voltha-lib-go/v3/pkg/db/kvstore"
@@ -37,12 +36,11 @@
 
 // Backend structure holds details for accessing the kv store
 type Backend struct {
-	sync.RWMutex
 	Client                  kvstore.Client
 	StoreType               string
 	Host                    string
 	Port                    int
-	Timeout                 int
+	Timeout                 time.Duration
 	PathPrefix              string
 	alive                   bool          // Is this backend connection alive?
 	liveness                chan bool     // channel to post alive state
@@ -51,7 +49,7 @@
 }
 
 // NewBackend creates a new instance of a Backend structure
-func NewBackend(storeType string, host string, port int, timeout int, pathPrefix string) *Backend {
+func NewBackend(storeType string, host string, port int, timeout time.Duration, pathPrefix string) *Backend {
 	var err error
 
 	b := &Backend{
@@ -77,7 +75,7 @@
 	return b
 }
 
-func (b *Backend) newClient(address string, timeout int) (kvstore.Client, error) {
+func (b *Backend) newClient(address string, timeout time.Duration) (kvstore.Client, error) {
 	switch b.StoreType {
 	case "consul":
 		return kvstore.NewConsulClient(address, timeout)
@@ -188,9 +186,6 @@
 
 // List retrieves one or more items that match the specified key
 func (b *Backend) List(ctx context.Context, key string) (map[string]*kvstore.KVPair, error) {
-	b.Lock()
-	defer b.Unlock()
-
 	formattedPath := b.makePath(key)
 	logger.Debugw("listing-key", log.Fields{"key": key, "path": formattedPath})
 
@@ -203,9 +198,6 @@
 
 // Get retrieves an item that matches the specified key
 func (b *Backend) Get(ctx context.Context, key string) (*kvstore.KVPair, error) {
-	b.Lock()
-	defer b.Unlock()
-
 	formattedPath := b.makePath(key)
 	logger.Debugw("getting-key", log.Fields{"key": key, "path": formattedPath})
 
@@ -218,9 +210,6 @@
 
 // Put stores an item value under the specifed key
 func (b *Backend) Put(ctx context.Context, key string, value interface{}) error {
-	b.Lock()
-	defer b.Unlock()
-
 	formattedPath := b.makePath(key)
 	logger.Debugw("putting-key", log.Fields{"key": key, "path": formattedPath})
 
@@ -233,9 +222,6 @@
 
 // Delete removes an item under the specified key
 func (b *Backend) Delete(ctx context.Context, key string) error {
-	b.Lock()
-	defer b.Unlock()
-
 	formattedPath := b.makePath(key)
 	logger.Debugw("deleting-key", log.Fields{"key": key, "path": formattedPath})
 
@@ -248,9 +234,6 @@
 
 // CreateWatch starts watching events for the specified key
 func (b *Backend) CreateWatch(ctx context.Context, key string, withPrefix bool) chan *kvstore.Event {
-	b.Lock()
-	defer b.Unlock()
-
 	formattedPath := b.makePath(key)
 	logger.Debugw("creating-key-watch", log.Fields{"key": key, "path": formattedPath})
 
@@ -259,9 +242,6 @@
 
 // DeleteWatch stops watching events for the specified key
 func (b *Backend) DeleteWatch(key string, ch chan *kvstore.Event) {
-	b.Lock()
-	defer b.Unlock()
-
 	formattedPath := b.makePath(key)
 	logger.Debugw("deleting-key-watch", log.Fields{"key": key, "path": formattedPath})
 
diff --git a/vendor/github.com/opencord/voltha-lib-go/v3/pkg/db/kvstore/client.go b/vendor/github.com/opencord/voltha-lib-go/v3/pkg/db/kvstore/client.go
index b9cb1ee..158e626 100644
--- a/vendor/github.com/opencord/voltha-lib-go/v3/pkg/db/kvstore/client.go
+++ b/vendor/github.com/opencord/voltha-lib-go/v3/pkg/db/kvstore/client.go
@@ -15,11 +15,14 @@
  */
 package kvstore
 
-import "context"
+import (
+	"context"
+	"time"
+)
 
 const (
 	// Default timeout in seconds when making a kvstore request
-	defaultKVGetTimeout = 5
+	defaultKVGetTimeout = 5 * time.Second
 	// Maximum channel buffer between publisher/subscriber goroutines
 	maxClientChannelBufferSize = 10
 )
@@ -77,12 +80,12 @@
 	Get(ctx context.Context, key string) (*KVPair, error)
 	Put(ctx context.Context, key string, value interface{}) error
 	Delete(ctx context.Context, key string) error
-	Reserve(ctx context.Context, key string, value interface{}, ttl int64) (interface{}, error)
+	Reserve(ctx context.Context, key string, value interface{}, ttl time.Duration) (interface{}, error)
 	ReleaseReservation(ctx context.Context, key string) error
 	ReleaseAllReservations(ctx context.Context) error
 	RenewReservation(ctx context.Context, key string) error
 	Watch(ctx context.Context, key string, withPrefix bool) chan *Event
-	AcquireLock(ctx context.Context, lockName string, timeout int) error
+	AcquireLock(ctx context.Context, lockName string, timeout time.Duration) error
 	ReleaseLock(lockName string) error
 	IsConnectionUp(ctx context.Context) bool // timeout in second
 	CloseWatch(key string, ch chan *Event)
diff --git a/vendor/github.com/opencord/voltha-lib-go/v3/pkg/db/kvstore/consulclient.go b/vendor/github.com/opencord/voltha-lib-go/v3/pkg/db/kvstore/consulclient.go
index bdf2d10..d2544dd 100644
--- a/vendor/github.com/opencord/voltha-lib-go/v3/pkg/db/kvstore/consulclient.go
+++ b/vendor/github.com/opencord/voltha-lib-go/v3/pkg/db/kvstore/consulclient.go
@@ -44,13 +44,11 @@
 }
 
 // NewConsulClient returns a new client for the Consul KV store
-func NewConsulClient(addr string, timeout int) (*ConsulClient, error) {
-
-	duration := GetDuration(timeout)
+func NewConsulClient(addr string, timeout time.Duration) (*ConsulClient, error) {
 
 	config := consulapi.DefaultConfig()
 	config.Address = addr
-	config.WaitTime = duration
+	config.WaitTime = timeout
 	consul, err := consulapi.NewClient(config)
 	if err != nil {
 		logger.Error(err)
@@ -76,7 +74,9 @@
 	deadline, _ := ctx.Deadline()
 	kv := c.consul.KV()
 	var queryOptions consulapi.QueryOptions
-	queryOptions.WaitTime = GetDuration(deadline.Second())
+	// Substract current time from deadline to get the waitTime duration
+	queryOptions.WaitTime = time.Until(deadline)
+
 	// For now we ignore meta data
 	kvps, _, err := kv.List(key, &queryOptions)
 	if err != nil {
@@ -97,7 +97,9 @@
 	deadline, _ := ctx.Deadline()
 	kv := c.consul.KV()
 	var queryOptions consulapi.QueryOptions
-	queryOptions.WaitTime = GetDuration(deadline.Second())
+	// Substract current time from deadline to get the waitTime duration
+	queryOptions.WaitTime = time.Until(deadline)
+
 	// For now we ignore meta data
 	kvp, _, err := kv.Get(key, &queryOptions)
 	if err != nil {
@@ -166,11 +168,11 @@
 	c.session = nil
 }
 
-func (c *ConsulClient) createSession(ttl int64, retries int) (*consulapi.Session, string, error) {
+func (c *ConsulClient) createSession(ttl time.Duration, retries int) (*consulapi.Session, string, error) {
 	session := c.consul.Session()
 	entry := &consulapi.SessionEntry{
 		Behavior: consulapi.SessionBehaviorDelete,
-		TTL:      "10s", // strconv.FormatInt(ttl, 10) + "s", // disable ttl
+		TTL:      ttl.String(),
 	}
 
 	for {
@@ -218,7 +220,7 @@
 // defines how long that reservation is valid.  When TTL expires the key is unreserved by the KV store itself.
 // If the key is acquired then the value returned will be the value passed in.  If the key is already acquired
 // then the value assigned to that key will be returned.
-func (c *ConsulClient) Reserve(ctx context.Context, key string, value interface{}, ttl int64) (interface{}, error) {
+func (c *ConsulClient) Reserve(ctx context.Context, key string, value interface{}, ttl time.Duration) (interface{}, error) {
 
 	// Validate that we can create a byte array from the value as consul API expects a byte array
 	var val []byte
@@ -432,10 +434,9 @@
 	logger.Debugw("start-watching-channel", log.Fields{"key": key, "channel": ch})
 
 	defer c.CloseWatch(key, ch)
-	duration := GetDuration(defaultKVGetTimeout)
 	kv := c.consul.KV()
 	var queryOptions consulapi.QueryOptions
-	queryOptions.WaitTime = duration
+	queryOptions.WaitTime = defaultKVGetTimeout
 
 	// Get the existing value, if any
 	previousKVPair, meta, err := kv.Get(key, &queryOptions)
@@ -503,7 +504,7 @@
 	}
 }
 
-func (c *ConsulClient) AcquireLock(ctx context.Context, lockName string, timeout int) error {
+func (c *ConsulClient) AcquireLock(ctx context.Context, lockName string, timeout time.Duration) error {
 	return nil
 }
 
diff --git a/vendor/github.com/opencord/voltha-lib-go/v3/pkg/db/kvstore/etcdclient.go b/vendor/github.com/opencord/voltha-lib-go/v3/pkg/db/kvstore/etcdclient.go
index 90158bc..8d4a462 100644
--- a/vendor/github.com/opencord/voltha-lib-go/v3/pkg/db/kvstore/etcdclient.go
+++ b/vendor/github.com/opencord/voltha-lib-go/v3/pkg/db/kvstore/etcdclient.go
@@ -20,6 +20,7 @@
 	"errors"
 	"fmt"
 	"sync"
+	"time"
 
 	"github.com/opencord/voltha-lib-go/v3/pkg/log"
 	v3Client "go.etcd.io/etcd/clientv3"
@@ -39,13 +40,12 @@
 }
 
 // NewEtcdClient returns a new client for the Etcd KV store
-func NewEtcdClient(addr string, timeout int, level log.LogLevel) (*EtcdClient, error) {
-	duration := GetDuration(timeout)
+func NewEtcdClient(addr string, timeout time.Duration, level log.LogLevel) (*EtcdClient, error) {
 	logconfig := log.ConstructZapConfig(log.JSON, level, log.Fields{})
 
 	c, err := v3Client.New(v3Client.Config{
 		Endpoints:   []string{addr},
-		DialTimeout: duration,
+		DialTimeout: timeout,
 		LogConfig:   &logconfig,
 	})
 	if err != nil {
@@ -162,7 +162,7 @@
 // defines how long that reservation is valid.  When TTL expires the key is unreserved by the KV store itself.
 // If the key is acquired then the value returned will be the value passed in.  If the key is already acquired
 // then the value assigned to that key will be returned.
-func (c *EtcdClient) Reserve(ctx context.Context, key string, value interface{}, ttl int64) (interface{}, error) {
+func (c *EtcdClient) Reserve(ctx context.Context, key string, value interface{}, ttl time.Duration) (interface{}, error) {
 	// Validate that we can convert value to a string as etcd API expects a string
 	var val string
 	var er error
@@ -170,7 +170,7 @@
 		return nil, fmt.Errorf("unexpected-type%T", value)
 	}
 
-	resp, err := c.ectdAPI.Grant(ctx, ttl)
+	resp, err := c.ectdAPI.Grant(ctx, int64(ttl.Seconds()))
 	if err != nil {
 		logger.Error(err)
 		return nil, err
@@ -457,7 +457,7 @@
 	return lock, session
 }
 
-func (c *EtcdClient) AcquireLock(ctx context.Context, lockName string, timeout int) error {
+func (c *EtcdClient) AcquireLock(ctx context.Context, lockName string, timeout time.Duration) error {
 	session, _ := v3Concurrency.NewSession(c.ectdAPI, v3Concurrency.WithContext(ctx))
 	mu := v3Concurrency.NewMutex(session, "/devicelock_"+lockName)
 	if err := mu.Lock(context.Background()); err != nil {
diff --git a/vendor/github.com/opencord/voltha-lib-go/v3/pkg/db/kvstore/kvutils.go b/vendor/github.com/opencord/voltha-lib-go/v3/pkg/db/kvstore/kvutils.go
index cf9a95c..64e7d30 100644
--- a/vendor/github.com/opencord/voltha-lib-go/v3/pkg/db/kvstore/kvutils.go
+++ b/vendor/github.com/opencord/voltha-lib-go/v3/pkg/db/kvstore/kvutils.go
@@ -15,19 +15,7 @@
  */
 package kvstore
 
-import (
-	"fmt"
-	"time"
-)
-
-// GetDuration converts a timeout value from int to duration.  If the timeout value is
-// either not set of -ve then we default KV timeout (configurable) is used.
-func GetDuration(timeout int) time.Duration {
-	if timeout <= 0 {
-		return defaultKVGetTimeout * time.Second
-	}
-	return time.Duration(timeout) * time.Second
-}
+import "fmt"
 
 // ToString converts an interface value to a string.  The interface should either be of
 // a string type or []byte.  Otherwise, an error is returned.
diff --git a/vendor/github.com/opencord/voltha-lib-go/v3/pkg/log/log.go b/vendor/github.com/opencord/voltha-lib-go/v3/pkg/log/log.go
index 6b7087f..9e0a0b5 100644
--- a/vendor/github.com/opencord/voltha-lib-go/v3/pkg/log/log.go
+++ b/vendor/github.com/opencord/voltha-lib-go/v3/pkg/log/log.go
@@ -552,7 +552,9 @@
 // Debugw logs a message with some additional context. The variadic key-value
 // pairs are treated as they are in With.
 func (l logger) Debugw(msg string, keysAndValues Fields) {
-	l.log.Debugw(msg, serializeMap(keysAndValues)...)
+	if l.V(DebugLevel) {
+		l.log.Debugw(msg, serializeMap(keysAndValues)...)
+	}
 }
 
 // Info logs a message at level Info on the standard logger.
@@ -575,7 +577,9 @@
 // Infow logs a message with some additional context. The variadic key-value
 // pairs are treated as they are in With.
 func (l logger) Infow(msg string, keysAndValues Fields) {
-	l.log.Infow(msg, serializeMap(keysAndValues)...)
+	if l.V(InfoLevel) {
+		l.log.Infow(msg, serializeMap(keysAndValues)...)
+	}
 }
 
 // Warn logs a message at level Warn on the standard logger.
@@ -596,7 +600,9 @@
 // Warnw logs a message with some additional context. The variadic key-value
 // pairs are treated as they are in With.
 func (l logger) Warnw(msg string, keysAndValues Fields) {
-	l.log.Warnw(msg, serializeMap(keysAndValues)...)
+	if l.V(WarnLevel) {
+		l.log.Warnw(msg, serializeMap(keysAndValues)...)
+	}
 }
 
 // Error logs a message at level Error on the standard logger.
@@ -617,7 +623,9 @@
 // Errorw logs a message with some additional context. The variadic key-value
 // pairs are treated as they are in With.
 func (l logger) Errorw(msg string, keysAndValues Fields) {
-	l.log.Errorw(msg, serializeMap(keysAndValues)...)
+	if l.V(ErrorLevel) {
+		l.log.Errorw(msg, serializeMap(keysAndValues)...)
+	}
 }
 
 // Fatal logs a message at level Fatal on the standard logger.
@@ -638,7 +646,9 @@
 // Fatalw logs a message with some additional context. The variadic key-value
 // pairs are treated as they are in With.
 func (l logger) Fatalw(msg string, keysAndValues Fields) {
-	l.log.Fatalw(msg, serializeMap(keysAndValues)...)
+	if l.V(FatalLevel) {
+		l.log.Fatalw(msg, serializeMap(keysAndValues)...)
+	}
 }
 
 // Warning logs a message at level Warn on the standard logger.
diff --git a/vendor/modules.txt b/vendor/modules.txt
index dc46454..d704862 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.7
+# github.com/opencord/voltha-lib-go/v3 v3.1.9
 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
