Search Options

Results per page
Sort
Preferred Languages
Advance

Results 21 - 30 of 1,614 for limiter (0.17 sec)

  1. src/go/doc/testdata/examples/import_groups.golden

    -- .Play --
    package main
    
    import (
    	"fmt"
    )
    
    func main() {
    	fmt.Println("Hello, world!")
    }
    -- .Output --
    Hello, world!
    -- Limiter.Play --
    package main
    
    import (
    	"fmt"
    	"time"
    
    	"golang.org/x/time/rate"
    )
    
    func main() {
    	// Uses fmt, time and rate.
    	l := rate.NewLimiter(rate.Every(time.Second), 1)
    	fmt.Println(l)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue May 10 16:17:51 UTC 2022
    - 317 bytes
    - Viewed (0)
  2. staging/src/k8s.io/apiextensions-apiserver/pkg/client/clientset/clientset/clientset.go

    		return nil
    	}
    	return c.DiscoveryClient
    }
    
    // NewForConfig creates a new Clientset for the given config.
    // If config's RateLimiter is not set and QPS and Burst are acceptable,
    // NewForConfig will generate a rate-limiter in configShallowCopy.
    // NewForConfig is equivalent to NewForConfigAndClient(c, httpClient),
    // where httpClient was generated with rest.HTTPClientFor(c).
    func NewForConfig(c *rest.Config) (*Clientset, error) {
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Mon May 08 21:36:26 UTC 2023
    - 4.4K bytes
    - Viewed (0)
  3. staging/src/k8s.io/apiextensions-apiserver/examples/client-go/pkg/client/clientset/versioned/clientset.go

    		return nil
    	}
    	return c.DiscoveryClient
    }
    
    // NewForConfig creates a new Clientset for the given config.
    // If config's RateLimiter is not set and QPS and Burst are acceptable,
    // NewForConfig will generate a rate-limiter in configShallowCopy.
    // NewForConfig is equivalent to NewForConfigAndClient(c, httpClient),
    // where httpClient was generated with rest.HTTPClientFor(c).
    func NewForConfig(c *rest.Config) (*Clientset, error) {
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Fri Sep 23 18:26:20 UTC 2022
    - 3.6K bytes
    - Viewed (0)
  4. internal/bucket/bandwidth/monitor.go

    	m.tlock.RLock()
    	defer m.tlock.RUnlock()
    	return m.bucketsThrottle[opts]
    }
    
    // SetBandwidthLimit sets the bandwidth limit for a bucket
    func (m *Monitor) SetBandwidthLimit(bucket, arn string, limit int64) {
    	m.tlock.Lock()
    	defer m.tlock.Unlock()
    	limitBytes := limit / int64(m.NodeCount)
    	throttle, ok := m.bucketsThrottle[BucketOptions{Name: bucket, ReplicationARN: arn}]
    	if !ok {
    		throttle = &bucketThrottle{}
    Registered: Sun Jun 16 00:44:34 UTC 2024
    - Last Modified: Mon Feb 19 22:54:46 UTC 2024
    - 6K bytes
    - Viewed (0)
  5. guava/src/com/google/common/util/concurrent/TimeLimiter.java

       * target} object, enforcing the specified time limit on each call. This time-limited delegation
       * is also performed for calls to {@link Object#equals}, {@link Object#hashCode}, and {@link
       * Object#toString}.
       *
       * <p>If the target method call finishes before the limit is reached, the return value or
       * exception is propagated to the caller exactly as-is. If, on the other hand, the time limit is
    Registered: Wed Jun 12 16:38:11 UTC 2024
    - Last Modified: Fri May 12 18:32:03 UTC 2023
    - 15.3K bytes
    - Viewed (0)
  6. src/runtime/export_test.go

    	return l
    }
    
    func (l *GCCPULimiter) Fill() uint64 {
    	return l.limiter.bucket.fill
    }
    
    func (l *GCCPULimiter) Capacity() uint64 {
    	return l.limiter.bucket.capacity
    }
    
    func (l *GCCPULimiter) Overflow() uint64 {
    	return l.limiter.overflow
    }
    
    func (l *GCCPULimiter) Limiting() bool {
    	return l.limiter.limiting()
    }
    
    func (l *GCCPULimiter) NeedUpdate(now int64) bool {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 30 17:50:53 UTC 2024
    - 46.1K bytes
    - Viewed (0)
  7. pkg/controller/nodelifecycle/scheduler/rate_limited_queue_test.go

    	fakeAlways := flowcontrol.NewFakeAlwaysRateLimiter()
    	qps := evictor.limiter.QPS()
    	if qps != fakeAlways.QPS() {
    		t.Fatalf("QPS does not match create one: %v instead of %v", qps, fakeAlways.QPS())
    	}
    
    	evictor.SwapLimiter(0)
    	qps = evictor.limiter.QPS()
    	fakeNever := flowcontrol.NewFakeNeverRateLimiter()
    	if qps != fakeNever.QPS() {
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Tue Mar 07 17:40:33 UTC 2023
    - 10K bytes
    - Viewed (0)
  8. android/guava/src/com/google/common/util/concurrent/RateLimiter.java

       * spread over each second. When the incoming request rate exceeds {@code permitsPerSecond} the
       * rate limiter will release one permit every {@code (1.0 / permitsPerSecond)} seconds. When the
       * rate limiter is unused, bursts of up to {@code permitsPerSecond} permits will be allowed, with
       * subsequent requests being smoothly limited at the stable rate of {@code permitsPerSecond}.
       *
    Registered: Wed Jun 12 16:38:11 UTC 2024
    - Last Modified: Tue Apr 04 09:45:04 UTC 2023
    - 18.2K bytes
    - Viewed (0)
  9. pkg/controlplane/controller/legacytokentracking/controller_test.go

    			},
    		},
    	}
    	for _, test := range tests {
    		t.Run(test.name, func(t *testing.T) {
    			client := fake.NewSimpleClientset(test.clientObjects...)
    			limiter := rate.NewLimiter(rate.Every(throttlePeriod), 1)
    			controller := newController(client, testingclock.NewFakeClock(now), limiter)
    			if test.existingConfigMap != nil {
    				controller.configMapCache.Add(test.existingConfigMap)
    			}
    
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Fri May 19 17:33:34 UTC 2023
    - 7.6K bytes
    - Viewed (0)
  10. guava/src/com/google/common/util/concurrent/RateLimiter.java

       * spread over each second. When the incoming request rate exceeds {@code permitsPerSecond} the
       * rate limiter will release one permit every {@code (1.0 / permitsPerSecond)} seconds. When the
       * rate limiter is unused, bursts of up to {@code permitsPerSecond} permits will be allowed, with
       * subsequent requests being smoothly limited at the stable rate of {@code permitsPerSecond}.
       *
    Registered: Wed Jun 12 16:38:11 UTC 2024
    - Last Modified: Tue Apr 04 09:45:04 UTC 2023
    - 21.5K bytes
    - Viewed (0)
Back to top