func dnsLb() (c clb.LoadBalancer) { dnsHost := os.Getenv("DNS_HOST") if dnsHost != "" { dnsPort := os.Getenv("DNS_PORT") if dnsPort == "" { dnsPort = "53" } c = clb.NewClb(dnsHost, dnsPort, clb.RoundRobin) } else { c = clb.NewDefaultClb(clb.RoundRobin) } return c }
// Client Factory func NewTodoClient() *TodoClient { return &TodoClient{ Lb: clb.NewDefaultClb(clb.RoundRobin), Address: ServiceAddress, } }