Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 3 of 3 for newVolumeStatCalculator (0.49 sec)

  1. pkg/kubelet/server/stats/volume_stat_calculator_test.go

    	eventStore := make(chan string, 1)
    	fakeEventRecorder := record.FakeRecorder{
    		Events: eventStore,
    	}
    
    	// Calculate stats for pod
    	statsCalculator := newVolumeStatCalculator(mockStats, time.Minute, fakePod, &fakeEventRecorder)
    	statsCalculator.calcAndStoreStats()
    	vs, _ := statsCalculator.GetLatest()
    
    	assert.Len(t, append(vs.EphemeralVolumes, vs.PersistentVolumes...), 4)
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Wed Apr 24 18:25:29 UTC 2024
    - 9.6K bytes
    - Viewed (0)
  2. pkg/kubelet/server/stats/volume_stat_calculator.go

    type PodVolumeStats struct {
    	EphemeralVolumes  []stats.VolumeStats
    	PersistentVolumes []stats.VolumeStats
    }
    
    // newVolumeStatCalculator creates a new VolumeStatCalculator
    func newVolumeStatCalculator(statsProvider Provider, jitterPeriod time.Duration, pod *v1.Pod, eventRecorder record.EventRecorder) *volumeStatCalculator {
    	return &volumeStatCalculator{
    		statsProvider: statsProvider,
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Fri Jul 29 00:55:10 UTC 2022
    - 7.1K bytes
    - Viewed (0)
  3. pkg/kubelet/server/stats/fs_resource_analyzer.go

    	for _, pod := range s.statsProvider.GetPods() {
    		if value, found := oldCache[pod.GetUID()]; !found {
    			newCache[pod.GetUID()] = newVolumeStatCalculator(s.statsProvider, s.calcPeriod, pod, s.eventRecorder).StartOnce()
    		} else {
    			newCache[pod.GetUID()] = value
    		}
    	}
    
    	// Stop entries for pods that have been deleted
    	for uid, entry := range oldCache {
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Tue Mar 09 16:16:37 UTC 2021
    - 3.3K bytes
    - Viewed (0)
Back to top