From b0b0338128dde6a658f5bdb6e07febb6473d5225 Mon Sep 17 00:00:00 2001 From: Asim Aslam Date: Wed, 20 Dec 2017 21:43:24 +0000 Subject: [PATCH] add option to set selector --- options.go | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/options.go b/options.go index 483356ce..988fc5c5 100644 --- a/options.go +++ b/options.go @@ -104,6 +104,13 @@ func Registry(r registry.Registry) Option { } } +// Selector sets the selector for the service client +func Selector(s selector.Selector) Option { + return func(o *Options) { + o.Client.Init(client.Selector(s)) + } +} + // Transport sets the transport for the service // and the underlying components func Transport(t transport.Transport) Option {