Skip to main content

LeaseReleaseReasonDto

Namespace: Meshmakers.Octo.Communication.Contracts.DataTransferObjects

Why a pool member handed a lease back (AB#4924, concept §4 and §6).

public enum LeaseReleaseReasonDto

Inheritance ObjectValueTypeEnumLeaseReleaseReasonDto
Implements IComparable, ISpanFormattable, IFormattable, IConvertible

Remarks:

Distinguishing the reasons is what lets the controller decide between "re-use this member" and "drain and restart it". A member that completed or failed a work item cleanly has proven its own cleanliness; one that was drained mid-flight has not.

Fields

NameValueDescription
Completed0The work item finished. The member is clean and may take the next lease.
Failed1The work item failed. Still a clean release — the member unwound the lease itself, so the failure belongs to the pipeline, not to the isolation invariant.
Drained2The member is shutting down or was asked to drain while it held the lease. The controller re-queues the work (at-least-once, concept §6) and does not hand this member another lease.