Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 2 of 2 for eventFreshDuration (0.74 sec)

  1. staging/src/k8s.io/apiserver/pkg/storage/cacher/watch_cache_test.go

    			eventCount:         5,
    			cacheCapacity:      5,
    			lowerBoundCapacity: 5 / 2,
    			upperBoundCapacity: 5 * 2,
    			interval:           eventFreshDuration / 6,
    			expectCapacity:     10,
    			expectStartIndex:   0,
    		},
    		{
    			name:               "[capacity not equals 4*n] events outside eventFreshDuration without change cache capacity",
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Tue Jun 04 09:20:10 UTC 2024
    - 35.4K bytes
    - Viewed (0)
  2. staging/src/k8s.io/apiserver/pkg/storage/cacher/watch_cache.go

    // - decreases capacity by 2x when recent quarter of events occurred outside of eventFreshDuration(protect watchCache from flapping).
    func (w *watchCache) resizeCacheLocked(eventTime time.Time) {
    	if w.isCacheFullLocked() && eventTime.Sub(w.cache[w.startIndex%w.capacity].RecordTime) < eventFreshDuration {
    		capacity := min(w.capacity*2, w.upperBoundCapacity)
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Tue Jun 11 10:20:57 UTC 2024
    - 26.2K bytes
    - Viewed (0)
Back to top