mirror of
https://github.com/slackhq/nebula.git
synced 2025-12-06 02:30:57 -08:00
store lighthouses as a slice (#1473)
* store lighthouses as a slice. If you have fewer than 16 lighthouses (and fewer than 16 vpnaddrs on a host, I guess), it's faster
This commit is contained in:
parent
65cc253c19
commit
8196c22b5a
2 changed files with 31 additions and 25 deletions
|
|
@ -22,7 +22,7 @@ func newTestLighthouse() *LightHouse {
|
|||
addrMap: map[netip.Addr]*RemoteList{},
|
||||
queryChan: make(chan netip.Addr, 10),
|
||||
}
|
||||
lighthouses := map[netip.Addr]struct{}{}
|
||||
lighthouses := []netip.Addr{}
|
||||
staticList := map[netip.Addr]struct{}{}
|
||||
|
||||
lh.lighthouses.Store(&lighthouses)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue