Dan Frank 13 years ago
parent
commit
76ff90cf7e
1 changed files with 6 additions and 0 deletions
  1. 6 0
      hostpool.go

+ 6 - 0
hostpool.go

@@ -223,6 +223,12 @@ func (p *epsilonGreedyHostPool) Get() HostPoolResponse {
 }
 
 func (p *standardHostPool) getRoundRobin() string {
+	// TODO - will want to replace this with something that runs in a 
+	// goroutine and receives requests on a channel.
+	// The state being protected in that case is really just the currentIdx
+
+	// Question - should I just skip the goroutine shit and select randomly?
+	// Maybe
 	now := time.Now()
 	hostCount := len(p.hostList)
 	for i := range p.hostList {