From c9cb92c96b8dcaff4ae9c2bc44df5c765fd1ca00 Mon Sep 17 00:00:00 2001 From: Yuce Tekol Date: Mon, 23 Oct 2017 17:34:04 +0300 Subject: [PATCH] Added Travis's note about InteraClient interface --- client.go | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/client.go b/client.go index 185b09f93..9297f4718 100644 --- a/client.go +++ b/client.go @@ -32,6 +32,7 @@ import ( "time" "crypto/tls" + "github.com/gogo/protobuf/proto" "github.com/pilosa/pilosa/internal" ) @@ -1206,6 +1207,12 @@ func nodePathToURL(node *Node, path string) url.URL { } } +// InternalClient should be implemented by any struct that enables any transport between nodes +// TODO: Refactor +// Note from Travis: Typically an interface containing more than two or three methods is an indication that +// something hasn't been architected correctly. +// While I understand that putting the entire Client behind an interface might require this many methods, +// I don't want to let it go unquestioned. type InternalClient interface { MaxSliceByIndex(ctx context.Context) (map[string]uint64, error) MaxInverseSliceByIndex(ctx context.Context) (map[string]uint64, error)