mirror of
https://github.com/go-micro/go-micro.git
synced 2024-11-24 08:02:32 +02:00
run gossip updater first
This commit is contained in:
parent
fae8c5eb4c
commit
8b54a850f7
@ -579,14 +579,14 @@ func NewRegistry(opts ...registry.Option) registry.Registry {
|
||||
watchers: make(map[string]chan *registry.Result),
|
||||
}
|
||||
|
||||
// run the updater
|
||||
go gossip.run()
|
||||
|
||||
// configure the gossiper
|
||||
if err := configure(gossip, opts...); err != nil {
|
||||
log.Fatalf("Error configuring registry: %v", err)
|
||||
}
|
||||
|
||||
// run the updater
|
||||
go gossip.run()
|
||||
|
||||
// wait for setup
|
||||
<-time.After(gossip.interval * 2)
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user