mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-11-27 19:16:16 +00:00
Revert "GCE: Allow nodes to exceed target pool maximums"
This reverts commit faf0c44429.
This commit is contained in:
@@ -81,19 +81,3 @@ func String(length int) string {
|
||||
}
|
||||
return string(b)
|
||||
}
|
||||
|
||||
// A type that satisfies the rand.Shufflable interface can be shuffled
|
||||
// by Shuffle. Any sort.Interface will satisfy this interface.
|
||||
type Shufflable interface {
|
||||
Len() int
|
||||
Swap(i, j int)
|
||||
}
|
||||
|
||||
func Shuffle(data Shufflable) {
|
||||
rng.Lock()
|
||||
defer rng.Unlock()
|
||||
for i := 0; i < data.Len(); i++ {
|
||||
j := rng.rand.Intn(i + 1)
|
||||
data.Swap(i, j)
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user