Example #1
0
func NewDefaultClb(lbType LoadBalancerType) LoadBalancer {
	lib := dns.NewDefaultLookupLib()

	return buildClb(lib, lbType)
}
Example #2
0
// Get new resolver with given ttl
func NewResolver(ttl int) clb.LoadBalancer {
	lib := dns.NewDefaultLookupLib()
	cache := ttlcache.NewTtlCache(lib, ttl)
	return clb.NewRoundRobinClb(cache)
}