plugin/kubernetes: Fix dns programming duration metric (#4255)
* get data reqd to record latency before calling toFuncs * refactor out unnecessary toFunc wrappers * remove latency metric unit tests per PR feedback Signed-off-by: Chris O'Haver <cohaver@infoblox.com>
This commit is contained in:
parent
56eea6e609
commit
9121e78496
9 changed files with 166 additions and 196 deletions
|
@ -22,8 +22,8 @@ import (
|
|||
"k8s.io/client-go/tools/cache"
|
||||
)
|
||||
|
||||
// ToFunc converts one empty interface to another.
|
||||
type ToFunc func(interface{}) (interface{}, error)
|
||||
// ToFunc converts one v1.Object to another v1.Object.
|
||||
type ToFunc func(v1.Object) (v1.Object, error)
|
||||
|
||||
// ProcessorBuilder returns function to process cache events.
|
||||
type ProcessorBuilder func(cache.Indexer, cache.ResourceEventHandler) cache.ProcessFunc
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue