Table of Contents

Struct RetryAdvice

Namespace
Trellis
Assembly
Trellis.Core.dll

Transport-neutral retry hint attached to Error.RateLimited and Error.Unavailable. Boundary layers translate to their own wire format (e.g. a header on a synchronous response, an envelope field on a queued message, or a structured field on a CLI exit envelope). Producers in the domain layer describe when the caller may retry; how that is conveyed is the boundary's concern.

public readonly record struct RetryAdvice : IEquatable<RetryAdvice>
Implements
Inherited Members

Remarks

At most one of After and At is typically populated; producers may set either, neither (an empty hint that still distinguishes "advice given" from "no advice"), or both. When both are present they describe the same instant from different viewpoints — boundaries are free to prefer whichever form maps most naturally to their wire representation, and consumers should treat them as equivalent rather than composing them.

Constructors

RetryAdvice(TimeSpan?, DateTimeOffset?)

Transport-neutral retry hint attached to Error.RateLimited and Error.Unavailable. Boundary layers translate to their own wire format (e.g. a header on a synchronous response, an envelope field on a queued message, or a structured field on a CLI exit envelope). Producers in the domain layer describe when the caller may retry; how that is conveyed is the boundary's concern.

public RetryAdvice(TimeSpan? After = null, DateTimeOffset? At = null)

Parameters

After TimeSpan?

Relative duration to wait before retrying.

At DateTimeOffset?

Absolute instant when the caller may retry.

Remarks

At most one of After and At is typically populated; producers may set either, neither (an empty hint that still distinguishes "advice given" from "no advice"), or both. When both are present they describe the same instant from different viewpoints — boundaries are free to prefer whichever form maps most naturally to their wire representation, and consumers should treat them as equivalent rather than composing them.

Properties

After

Relative duration to wait before retrying.

public TimeSpan? After { get; init; }

Property Value

TimeSpan?

At

Absolute instant when the caller may retry.

public DateTimeOffset? At { get; init; }

Property Value

DateTimeOffset?