discovery: simplify client initialization
This commit is contained in:
parent
b5bfb502df
commit
76076bfb47
|
@ -25,7 +25,6 @@ func NewMarathon(conf *config.MarathonSDConfig) *marathon.Discovery {
|
|||
return &marathon.Discovery{
|
||||
Servers: conf.Servers,
|
||||
RefreshInterval: time.Duration(conf.RefreshInterval),
|
||||
Done: make(chan struct{}),
|
||||
Client: marathon.FetchApps,
|
||||
}
|
||||
}
|
||||
|
|
|
@ -30,8 +30,8 @@ func newTestDiscovery(client AppListClient) (chan []*config.TargetGroup, *Discov
|
|||
ch := make(chan []*config.TargetGroup)
|
||||
md := &Discovery{
|
||||
Servers: []string{"http://localhost:8080"},
|
||||
Client: client,
|
||||
}
|
||||
md.Client = client
|
||||
return ch, md
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue