Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 4 of 4 for SetRecordPluginMetrics (0.17 sec)

  1. pkg/scheduler/framework/cycle_state.go

    func (c *CycleState) ShouldRecordPluginMetrics() bool {
    	if c == nil {
    		return false
    	}
    	return c.recordPluginMetrics
    }
    
    // SetRecordPluginMetrics sets recordPluginMetrics to the given value.
    func (c *CycleState) SetRecordPluginMetrics(flag bool) {
    	if c == nil {
    		return
    	}
    	c.recordPluginMetrics = flag
    }
    
    // Clone creates a copy of CycleState and returns its pointer. Clone returns
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Tue Jul 18 06:48:20 UTC 2023
    - 4K bytes
    - Viewed (0)
  2. pkg/scheduler/framework/cycle_state_test.go

    // The given data is used in stored fakeData.
    func createCycleStateWithFakeData(data string, recordPluginMetrics bool) *CycleState {
    	c := NewCycleState()
    	c.Write(key, &fakeData{
    		data: data,
    	})
    	c.SetRecordPluginMetrics(recordPluginMetrics)
    	return c
    }
    
    // isCycleStateEqual returns whether two CycleState, which has fakeData in storage, is equal or not.
    // And if they are not equal, returns message which shows why not equal.
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Thu Apr 14 15:26:20 UTC 2022
    - 3.9K bytes
    - Viewed (0)
  3. pkg/scheduler/schedule_one.go

    		return
    	}
    
    	logger.V(3).Info("Attempting to schedule pod", "pod", klog.KObj(pod))
    
    	// Synchronously attempt to find a fit for the pod.
    	start := time.Now()
    	state := framework.NewCycleState()
    	state.SetRecordPluginMetrics(rand.Intn(100) < pluginMetricsSamplePercent)
    
    	// Initialize an empty podsToActivate struct, which will be filled up by plugins or stay empty.
    	podsToActivate := framework.NewPodsToActivate()
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Thu Jun 06 13:28:08 UTC 2024
    - 43.4K bytes
    - Viewed (0)
  4. pkg/scheduler/framework/runtime/framework_test.go

    	return func(o *frameworkOptions) {
    		o.metricsRecorder = recorder
    	}
    }
    
    func TestRecordingMetrics(t *testing.T) {
    	state := &framework.CycleState{}
    	state.SetRecordPluginMetrics(true)
    
    	tests := []struct {
    		name               string
    		action             func(f framework.Framework)
    		inject             injectedResult
    		wantExtensionPoint string
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Fri May 17 09:07:27 UTC 2024
    - 103K bytes
    - Viewed (0)
Back to top