-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
✨ Ability to override
StartDurationThreshold
to change the duration… (
#5)
- Loading branch information
1 parent
ee5cbdf
commit 6794614
Showing
6 changed files
with
86 additions
and
30 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
using System; | ||
|
||
/// <summary> | ||
/// Rate limiter configuration | ||
/// </summary> | ||
public sealed class RateLimiterConfiguration | ||
{ | ||
/// <summary> | ||
/// The duration after which the configured rate Limit is reset. | ||
/// </summary> | ||
public TimeSpan Duration { get; set; } | ||
/// <summary> | ||
/// The maximum number of message to process within the configured Duration. | ||
/// </summary> | ||
public int Limit { get; set; } | ||
/// <summary> | ||
/// The duration warning threshold after which a Informational log entry if logged to raise awareness of an imbalance between configured rate limit and concurrency. Set to -1 milliseconds to disable. | ||
/// </summary> | ||
public TimeSpan StartDurationThreshold { get; set; } = TimeSpan.FromSeconds(5); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters