Class RateLimiter.SimpleRateLimiter
Simple class to rate limit IO.
Assembly: DistributedLucene.Net.dll
Syntax
public class SimpleRateLimiter : RateLimiter
Constructors
Name | Description |
---|---|
SimpleRateLimiter(Double) |
|
Properties
Name | Description |
---|---|
MbPerSec | The current mb per second rate limit. |
Methods
Name | Description |
---|---|
Pause(Int64) | Pauses, if necessary, to keep the instantaneous IO rate at or below the target. NOTE: multiple threads may safely use this, however the implementation is not perfectly thread safe but likely in practice this is harmless (just means in some rare cases the rate might exceed the target). It's best to call this with a biggish count, not one byte at a time. |
SetMbPerSec(Double) | Sets an updated mb per second rate limit. |