From df8ad76b5ca5316ae2a9ca88c5aa6af5f2dc9b4e Mon Sep 17 00:00:00 2001 From: FUJITA Tomonori Date: Mon, 29 Oct 2018 18:59:09 +0900 Subject: server: unexported Watcher stuff Replace it with the new API using api/. Signed-off-by: FUJITA Tomonori --- pkg/server/zclient.go | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'pkg/server/zclient.go') diff --git a/pkg/server/zclient.go b/pkg/server/zclient.go index c4abd12b..33190591 100644 --- a/pkg/server/zclient.go +++ b/pkg/server/zclient.go @@ -331,9 +331,9 @@ func (z *zebraClient) updatePathByNexthopCache(paths []*table.Path) { } func (z *zebraClient) loop() { - w := z.server.Watch([]WatchOption{ - WatchBestPath(true), - WatchPostUpdate(true), + w := z.server.watch([]watchOption{ + watchBestPath(true), + watchPostUpdate(true), }...) defer w.Stop() @@ -368,7 +368,7 @@ func (z *zebraClient) loop() { } case ev := <-w.Event(): switch msg := ev.(type) { - case *WatchEventBestPath: + case *watchEventBestPath: if table.UseMultiplePaths.Enabled { for _, paths := range msg.MultiPathList { z.updatePathByNexthopCache(paths) @@ -398,7 +398,7 @@ func (z *zebraClient) loop() { } } } - case *WatchEventUpdate: + case *watchEventUpdate: if body := newNexthopRegisterBody(msg.PathList, z.nexthopCache); body != nil { vrfID := uint32(0) for _, vrf := range z.server.listVrf() { -- cgit v1.2.3