Class FencingTokenExhaustedException
- Namespace
- Excalibur.Dispatch.LeaderElection.Fencing
- Assembly
- Excalibur.Dispatch.LeaderElection.Abstractions.dll
Thrown by IssueTokenAsync(string, CancellationToken) when its domain cannot generate another strictly positive monotonic token.
public sealed class FencingTokenExhaustedException : Exception, ISerializable
- Inheritance
-
FencingTokenExhaustedException
- Implements
- Inherited Members
- Extension Methods
Remarks
The token domain must never wrap or reuse a value: either would admit a stale leader. Exhaustion is permanent for the attempt, so a retrying mint caller propagates this exception and relinquishes rather than declaring a tenure with an unsafe token. A provider's bounded domain need not fill the entire Int64 range. Read-native providers do not implement the separate minting capability.
Constructors
FencingTokenExhaustedException()
Initializes a new instance of the FencingTokenExhaustedException class.
public FencingTokenExhaustedException()
FencingTokenExhaustedException(string)
Initializes a new instance of the FencingTokenExhaustedException class with a message.
public FencingTokenExhaustedException(string message)
Parameters
messagestringThe error message.
FencingTokenExhaustedException(string, Exception)
Initializes a new instance of the FencingTokenExhaustedException class with a message and an inner exception.
public FencingTokenExhaustedException(string message, Exception innerException)
Parameters
Properties
ResourceId
Gets the identifier of the protected resource whose token domain is exhausted, when known.
public string? ResourceId { get; init; }