2 writes to _currentSegmentIndex
System.Threading.RateLimiting (2)
System\Threading\RateLimiting\SlidingWindowRateLimiter.cs (2)
93_currentSegmentIndex = 0; 368_currentSegmentIndex = (_currentSegmentIndex + 1) % _options.SegmentsPerWindow;
7 references to _currentSegmentIndex
System.Threading.RateLimiting (7)
System\Threading\RateLimiting\SlidingWindowRateLimiter.cs (7)
262int segmentIndex = (_currentSegmentIndex + i) % _options.SegmentsPerWindow; 304_requestsPerSegment[_currentSegmentIndex] += permitCount; 368_currentSegmentIndex = (_currentSegmentIndex + 1) % _options.SegmentsPerWindow; 369int oldSegmentPermitCount = _requestsPerSegment[_currentSegmentIndex]; 370_requestsPerSegment[_currentSegmentIndex] = 0; 409_requestsPerSegment[_currentSegmentIndex] += nextPendingRequest.Count; 416_requestsPerSegment[_currentSegmentIndex] -= nextPendingRequest.Count;