Class RetryErrorPolicy
- Namespace
- Silverback.Messaging.Consuming.ErrorHandling
- Assembly
- Silverback.Integration.dll
This policy retries to process the message that previously failed to be to processed. An optional delay can be specified.
public record RetryErrorPolicy : ErrorPolicyBase, IErrorPolicy, IEquatable<ErrorPolicyBase>, IEquatable<RetryErrorPolicy>
- Inheritance
-
RetryErrorPolicy
- Implements
- Inherited Members
Constructors
RetryErrorPolicy(RetryErrorPolicy)
protected RetryErrorPolicy(RetryErrorPolicy original)
Parameters
originalRetryErrorPolicy
Properties
DelayFactor
Gets the factor to be applied to the delay to be applied at each retry.
public double DelayFactor { get; init; }
Property Value
DelayIncrement
Gets the increment to the delay to be applied at each retry.
public TimeSpan DelayIncrement { get; init; }
Property Value
EqualityContract
protected override Type EqualityContract { get; }
Property Value
InitialDelay
Gets the delay to be applied to the first retry.
public TimeSpan InitialDelay { get; init; }
Property Value
MaxDelay
Gets the maximum delay to be applied.
public TimeSpan? MaxDelay { get; init; }
Property Value
Methods
BuildCore(IServiceProvider)
Returns the actual error policy implementation, built using the provided IServiceProvider.
protected override ErrorPolicyImplementation BuildCore(IServiceProvider serviceProvider)
Parameters
serviceProviderIServiceProviderThe IServiceProvider to be used to build the error policy.
Returns
- ErrorPolicyImplementation
An instance of IErrorPolicyImplementation that can be used to handle the processing error.
Equals(ErrorPolicyBase?)
public override sealed bool Equals(ErrorPolicyBase? other)
Parameters
otherErrorPolicyBase
Returns
Equals(RetryErrorPolicy?)
public virtual bool Equals(RetryErrorPolicy? other)
Parameters
otherRetryErrorPolicy
Returns
Equals(object?)
public override bool Equals(object? obj)
Parameters
objobject
Returns
GetHashCode()
public override int GetHashCode()
Returns
PrintMembers(StringBuilder)
protected override bool PrintMembers(StringBuilder builder)
Parameters
builderStringBuilder
Returns
ToString()
public override string ToString()
Returns
Operators
operator ==(RetryErrorPolicy?, RetryErrorPolicy?)
public static bool operator ==(RetryErrorPolicy? left, RetryErrorPolicy? right)
Parameters
leftRetryErrorPolicyrightRetryErrorPolicy
Returns
operator !=(RetryErrorPolicy?, RetryErrorPolicy?)
public static bool operator !=(RetryErrorPolicy? left, RetryErrorPolicy? right)
Parameters
leftRetryErrorPolicyrightRetryErrorPolicy