- Sort Score
- Result 10 results
- Languages All
Results 1 - 7 of 7 for RateLimiter (0.19 sec)
-
guava/src/com/google/common/util/concurrent/RateLimiter.java
} @VisibleForTesting static RateLimiter create(double permitsPerSecond, SleepingStopwatch stopwatch) { RateLimiter rateLimiter = new SmoothBursty(stopwatch, 1.0 /* maxBurstSeconds */); rateLimiter.setRate(permitsPerSecond); return rateLimiter; } /** * Creates a {@code RateLimiter} with the specified stable throughput, given as "permits per
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Sat Oct 19 00:51:36 UTC 2024 - 21.6K bytes - Viewed (0) -
android/guava/src/com/google/common/util/concurrent/RateLimiter.java
} @VisibleForTesting static RateLimiter create(double permitsPerSecond, SleepingStopwatch stopwatch) { RateLimiter rateLimiter = new SmoothBursty(stopwatch, 1.0 /* maxBurstSeconds */); rateLimiter.setRate(permitsPerSecond); return rateLimiter; } /** * Creates a {@code RateLimiter} with the specified stable throughput, given as "permits per
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Sat Oct 19 00:51:36 UTC 2024 - 21.9K bytes - Viewed (0) -
android/guava-tests/test/com/google/common/util/concurrent/RateLimiterTest.java
} public void testSimpleWeights() { RateLimiter rateLimiter = RateLimiter.create(1.0, stopwatch); rateLimiter.acquire(1); // no wait rateLimiter.acquire(1); // R1.00, to repay previous rateLimiter.acquire(2); // R1.00, to repay previous rateLimiter.acquire(4); // R2.00, to repay previous rateLimiter.acquire(8); // R4.00, to repay previous rateLimiter.acquire(1); // R8.00, to repay previous
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Mon Oct 21 14:28:19 UTC 2024 - 21.8K bytes - Viewed (0) -
guava-tests/test/com/google/common/util/concurrent/RateLimiterTest.java
} public void testSimpleWeights() { RateLimiter rateLimiter = RateLimiter.create(1.0, stopwatch); rateLimiter.acquire(1); // no wait rateLimiter.acquire(1); // R1.00, to repay previous rateLimiter.acquire(2); // R1.00, to repay previous rateLimiter.acquire(4); // R2.00, to repay previous rateLimiter.acquire(8); // R4.00, to repay previous rateLimiter.acquire(1); // R8.00, to repay previous
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Mon Oct 21 14:28:19 UTC 2024 - 21.8K bytes - Viewed (0) -
guava/src/com/google/common/util/concurrent/SmoothRateLimiter.java
import java.util.concurrent.TimeUnit; @J2ktIncompatible @GwtIncompatible @ElementTypesAreNonnullByDefault abstract class SmoothRateLimiter extends RateLimiter { /* * How is the RateLimiter designed, and why? * * The primary feature of a RateLimiter is its "stable rate", the maximum rate that it should * allow in normal conditions. This is enforced by "throttling" incoming requests as needed. For
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Tue Apr 04 09:45:04 UTC 2023 - 19.3K bytes - Viewed (0) -
guava-tests/test/com/google/common/util/concurrent/MoreExecutorsTest.java
} }); assertEquals(oldName, Thread.currentThread().getName()); } public void testExecutors_nullCheck() throws Exception { new ClassSanityTester() .setDefault(RateLimiter.class, RateLimiter.create(1.0)) .forAllPublicStaticMethods(MoreExecutors.class) .thatReturn(Executor.class) .testNulls(); } private static class TestApplication extends Application {
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Fri Oct 18 22:10:29 UTC 2024 - 28.1K bytes - Viewed (0) -
android/guava-tests/test/com/google/common/util/concurrent/MoreExecutorsTest.java
} }); assertEquals(oldName, Thread.currentThread().getName()); } public void testExecutors_nullCheck() throws Exception { new ClassSanityTester() .setDefault(RateLimiter.class, RateLimiter.create(1.0)) .forAllPublicStaticMethods(MoreExecutors.class) .thatReturn(Executor.class) .testNulls(); } private static class TestApplication extends Application {
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Fri Oct 18 22:10:29 UTC 2024 - 28.1K bytes - Viewed (0)