Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 2 of 2 for mock (0.17 sec)

  1. cmd/callhome.go

    		return
    	}
    
    	go func() {
    		r := rand.New(rand.NewSource(time.Now().UnixNano()))
    		// Leader node (that successfully acquires the lock inside runCallhome)
    		// will keep performing the callhome. If the leader goes down for some reason,
    		// the lock will be released and another node will acquire it and take over
    		// because of this loop.
    		for {
    			if !globalCallhomeConfig.Enabled() {
    				return
    			}
    
    Go
    - Registered: Sun Apr 21 19:28:08 GMT 2024
    - Last Modified: Thu Apr 04 12:04:40 GMT 2024
    - 5.1K bytes
    - Viewed (1)
  2. internal/config/callhome/callhome.go

    	defer configLock.RUnlock()
    
    	if c.Frequency == 0 {
    		return callhomeCycleDefault
    	}
    
    	return c.Frequency
    }
    
    // Update updates new callhome frequency
    func (c *Config) Update(ncfg Config) {
    	configLock.Lock()
    	defer configLock.Unlock()
    
    	c.Enable = ncfg.Enable
    	c.Frequency = ncfg.Frequency
    }
    
    // LookupConfig - lookup config and override with valid environment settings if any.
    Go
    - Registered: Sun Apr 21 19:28:08 GMT 2024
    - Last Modified: Mon Sep 04 19:57:37 GMT 2023
    - 2.6K bytes
    - Viewed (0)
Back to top