add comments for registration

This commit is contained in:
Asim Aslam 2017-01-07 22:51:34 +00:00
parent 4d4db84d5d
commit fd78e1d432

View File

@ -150,12 +150,14 @@ func Action(a func(*cli.Context)) Option {
} }
} }
// RegisterTTL specifies the TTL to use when registering the service
func RegisterTTL(t time.Duration) Option { func RegisterTTL(t time.Duration) Option {
return func(o *Options) { return func(o *Options) {
o.Server.Init(server.RegisterTTL(t)) o.Server.Init(server.RegisterTTL(t))
} }
} }
// RegisterInterval specifies the interval on which to re-register
func RegisterInterval(t time.Duration) Option { func RegisterInterval(t time.Duration) Option {
return func(o *Options) { return func(o *Options) {
o.RegisterInterval = t o.RegisterInterval = t