mirror of
https://github.com/k3s-io/kubernetes.git
synced 2026-01-13 19:36:22 +00:00
Automatic merge from submit-queue (batch tested with PRs 34488, 39511, 39619, 38342, 39491) use fake clock in lruexpiration cache test when the system clock is extremely slow(usually see in VMs), this [check](https://github.com/kubernetes/kubernetes/blob/master/pkg/util/cache/lruexpirecache.go#L74) might still return the value. ```go if c.clock.Now().After(e.(*cacheEntry).expireTime) { go c.remove(key) return nil, false } ``` that means even we set the ttl to be 0 second, the after check might still be false(because the clock is too slow, and thus equals). the change here helps to reduce flakes.