3 writes to ReplenishmentPeriod
RateLimitingSample (1)
Program.cs (1)
31
options.
ReplenishmentPeriod
= TimeSpan.FromSeconds(10);
System.Threading.RateLimiting (2)
System\Threading\RateLimiting\RateLimitPartition.cs (1)
79
ReplenishmentPeriod
= options.ReplenishmentPeriod,
System\Threading\RateLimiting\TokenBucketRateLimiter.cs (1)
78
ReplenishmentPeriod
= options.ReplenishmentPeriod,
9 references to ReplenishmentPeriod
System.Threading.RateLimiting (9)
System\Threading\RateLimiting\RateLimitPartition.cs (1)
79
ReplenishmentPeriod = options.
ReplenishmentPeriod
,
System\Threading\RateLimiting\TokenBucketRateLimiter.cs (8)
44
public override TimeSpan ReplenishmentPeriod => _options.
ReplenishmentPeriod
;
68
if (options.
ReplenishmentPeriod
<= TimeSpan.Zero)
70
throw new ArgumentException(SR.Format(SR.ShouldBeGreaterThanTimeSpan0, nameof(options.
ReplenishmentPeriod
)), nameof(options));
78
ReplenishmentPeriod = options.
ReplenishmentPeriod
,
84
_fillRate = (double)options.TokensPerPeriod / options.
ReplenishmentPeriod
.Ticks;
90
_renewTimer = new Timer(Replenish, this, _options.
ReplenishmentPeriod
, _options.
ReplenishmentPeriod
);
226
return new TokenBucketLease(false, TimeSpan.FromTicks(_options.
ReplenishmentPeriod
.Ticks * replenishPeriods));