code: func newUpstream(hosts []string, old *staticUpstream) Upstream {
  	upstream := &staticUpstream{
  		from: old.from,
  		HealthCheck: healthcheck.HealthCheck{
  			FailTimeout: 5 * time.Second,
  			MaxFails:    3,
  		},
  		ex:                old.ex,
  		IgnoredSubDomains: old.IgnoredSubDomains,
  	}
  
  	upstream.Hosts = make([]*healthcheck.UpstreamHost, len(hosts))
  	for i, host := range hosts {
  		uh := &healthcheck.UpstreamHost{
  			Name:        host,
  			Conns:       0,
  			Fails:       0,
  			FailTimeout: upstream.FailTimeout,
  			CheckDown:   checkDownFunc(upstream),
  		}
  		upstream.Hosts[i] = uh
  	}
  	return upstream
  }
docs: // newUpstream returns an upstream initialized with hosts.