From cdde760aadb6d218bda8ad51ac209e00c632a84e Mon Sep 17 00:00:00 2001 From: Daniel Morandini Date: Fri, 18 Jan 2019 17:56:03 +0100 Subject: [PATCH] Prepare for #27 removing Value function --- core/balancer.go | 3 --- core/balancer_test.go | 4 ---- source/interface.go | 4 ---- source/listener_test.go | 4 ---- store/store_test.go | 4 ---- 5 files changed, 19 deletions(-) diff --git a/core/balancer.go b/core/balancer.go index 5915e43..b8bc852 100644 --- a/core/balancer.go +++ b/core/balancer.go @@ -41,9 +41,6 @@ type Source interface { // Tells the receiver to cleanup and close all connections. Close() error - - // Value returns the value associated with key or nil if none. - Value(interface{}) interface{} } // Strategy chooses a source from a ring of sources. diff --git a/core/balancer_test.go b/core/balancer_test.go index 907eac5..d610141 100644 --- a/core/balancer_test.go +++ b/core/balancer_test.go @@ -48,10 +48,6 @@ func (s *mock) Close() error { return nil } -func (s *mock) Value(key interface{}) interface{} { - return nil -} - // Just test that Len does not panic. func TestLen(t *testing.T) { b := &core.Balancer{} diff --git a/source/interface.go b/source/interface.go index 45c0c8b..ec36505 100644 --- a/source/interface.go +++ b/source/interface.go @@ -136,10 +136,6 @@ func (i *Interface) Close() error { return nil } -func (i *Interface) Value(key interface{}) interface{} { - return nil -} - func (i *Interface) String() string { return i.Name() } diff --git a/source/listener_test.go b/source/listener_test.go index c5ed55b..ef2f7fc 100644 --- a/source/listener_test.go +++ b/source/listener_test.go @@ -48,10 +48,6 @@ func (s *mock) Close() error { return nil } -func (s *mock) Value(key interface{}) interface{} { - return nil -} - func (s *mock) String() string { return s.Name() } diff --git a/store/store_test.go b/store/store_test.go index d5588e0..34f43d4 100644 --- a/store/store_test.go +++ b/store/store_test.go @@ -45,10 +45,6 @@ func (s *mock) Close() error { return nil } -func (s *mock) Value(key interface{}) interface{} { - return nil -} - func (s *mock) String() string { return s.Name() }