Class EndpointRoutingRule
Represents a configured endpoint routing rule.
public sealed record EndpointRoutingRule : IEquatable<EndpointRoutingRule>
- Inheritance
-
EndpointRoutingRule
- Implements
- Inherited Members
- Extension Methods
Constructors
EndpointRoutingRule(Type, IReadOnlyList<string>, Func<IDispatchMessage, IMessageContext, bool>?, int, bool)
Represents a configured endpoint routing rule.
public EndpointRoutingRule(Type MessageType, IReadOnlyList<string> Endpoints, Func<IDispatchMessage, IMessageContext, bool>? Predicate = null, int Priority = 0, bool StopOnMatch = false)
Parameters
MessageTypeTypeThe message type this rule applies to.
EndpointsIReadOnlyList<string>The target endpoint names.
PredicateFunc<IDispatchMessage, IMessageContext, bool>Optional predicate for conditional routing.
PriorityintRule priority (lower = higher precedence).
StopOnMatchboolWhether to stop evaluating further rules on match.
Properties
Endpoints
The target endpoint names.
public IReadOnlyList<string> Endpoints { get; init; }
Property Value
MessageType
The message type this rule applies to.
public Type MessageType { get; init; }
Property Value
Predicate
Optional predicate for conditional routing.
public Func<IDispatchMessage, IMessageContext, bool>? Predicate { get; init; }
Property Value
Priority
Rule priority (lower = higher precedence).
public int Priority { get; init; }
Property Value
StopOnMatch
Whether to stop evaluating further rules on match.
public bool StopOnMatch { get; init; }