Class KeyedThrottleDefinition
Scope-opener definition for the keyed (per-key) Throttle EIP.
Limits the rate at which each unique key can enter the downstream pipeline.
Inherits the leaf DSL from .
Close with .
public class KeyedThrottleDefinition : RouteDefinitionBase<KeyedThrottleDefinition>, IRouteDefinition, IProcessorDefinition, IRouteScope
Inheritance
Implements
Inherited Members
Properties
MaxPerPeriodFactory
Limit per key evaluated on each message (key and limit come from the message:
public Func<IExchange, int> MaxPerPeriodFactory { get; }
Period
Gets the time period for the rate limit (null = 1 second default).
public TimeSpan? Period { get; }
Methods
CreateProcessor(IRouteContext)
Compile this node into a runtime processor.
public override IProcessor CreateProcessor(IRouteContext context)
EndKeyedThrottle()
Closes the KeyedThrottle scope and returns the parent route definition.
public IRouteDefinition EndKeyedThrottle()
RejectOnOverflow(bool)
Opt into RFC 6585 §4 rejection semantics: overflow exchanges are short-circuited with
public KeyedThrottleDefinition RejectOnOverflow(bool reject = true)