Table of Contents

Class ScheduledMessage

Namespace
Excalibur.Dispatch.Delivery
Assembly
Excalibur.Dispatch.Abstractions.dll

Default implementation of IScheduledMessage with timezone support.

public sealed class ScheduledMessage : IScheduledMessage, IScheduledMessageIdentity, IScheduleSpec, IScheduledMessageMetadata
Inheritance
ScheduledMessage
Implements
Inherited Members
Extension Methods

Properties

CorrelationId

Gets or sets the correlation identifier for linking related messages and operations.

public string? CorrelationId { get; set; }

Property Value

string

A correlation ID that can be used to group related messages across distributed operations.

CronExpression

Gets or sets the cron expression that defines the recurring execution schedule.

public string CronExpression { get; set; }

Property Value

string

A valid cron expression string defining when the message should be executed.

CronRecurrenceProfileId

Gets or sets the explicit persisted cron transition profile identifier.

public string? CronRecurrenceProfileId { get; set; }

Property Value

string

Remarks

Pair with CronRecurrenceProfileVersion. The supported pair is CronosCompatible. A missing declaration is permitted only for non-cron or provably transition-free installed zones. Unknown, partial or mismatched declarations never fall back silently. Existing captured UTC occurrences retain their admitted authority; future admissions require valid configuration.

CronRecurrenceProfileVersion

Gets or sets the semantic version paired with CronRecurrenceProfileId.

public int? CronRecurrenceProfileVersion { get; set; }

Property Value

int?

Enabled

Gets or sets a value indicating whether this scheduled message is active and should be executed.

public bool Enabled { get; set; }

Property Value

bool

True if the schedule is active; false to pause execution without deleting the schedule.

Id

Gets or sets the unique identifier for this scheduled message instance.

public Guid Id { get; set; }

Property Value

Guid

A globally unique identifier that distinguishes this scheduled message from all other scheduled messages in the system.

Interval

Gets or sets the fixed interval for simple recurring schedule patterns.

public TimeSpan? Interval { get; set; }

Property Value

TimeSpan?

A TimeSpan representing the interval between executions. Null indicates this is not an interval-based schedule.

LastExecutionUtc

Gets or sets the timestamp of the most recent execution attempt in UTC.

public DateTimeOffset? LastExecutionUtc { get; set; }

Property Value

DateTimeOffset?

The UTC timestamp when this schedule was last executed, or null if it has never been executed.

MessageBody

Gets or sets the serialized message payload that will be dispatched when the schedule executes.

public string MessageBody { get; set; }

Property Value

string

A string containing the serialized message data in the format expected by the configured message serializer (JSON, MessagePack, etc.).

MessageName

Gets or sets the fully qualified type name of the message for deserialization.

public string MessageName { get; set; }

Property Value

string

The complete type name including namespace that can be used to deserialize the MessageBody back into the appropriate message type instance.

MissedExecutionBehavior

Gets or sets the policy for handling executions that were missed due to system downtime or delays.

public MissedExecutionBehavior? MissedExecutionBehavior { get; set; }

Property Value

MissedExecutionBehavior?

The missed execution behavior policy, or null to use system defaults.

NextExecutionUtc

Gets or sets the next scheduled execution time in UTC for efficient querying and execution planning.

public DateTimeOffset? NextExecutionUtc { get; set; }

Property Value

DateTimeOffset?

The UTC timestamp when this message should next be executed, or null if the schedule is complete.

TenantId

Gets or sets the tenant identifier for multi-tenant scheduling isolation.

public string? TenantId { get; set; }

Property Value

string

The tenant ID that owns this scheduled message, or null for system-wide schedules.

TimeZoneId

Gets or sets the timezone identifier for evaluating cron expressions in local time.

public string? TimeZoneId { get; set; }

Property Value

string

A standard timezone identifier (e.g., "America/New_York", "Europe/London"). Null indicates UTC.

TraceParent

Gets or sets the distributed tracing parent identifier for observability integration.

public string? TraceParent { get; set; }

Property Value

string

The trace parent ID following W3C Trace Context specification.

UserId

Gets or sets the identifier of the user or service that created this schedule.

public string? UserId { get; set; }

Property Value

string

The user ID, service account, or system identifier responsible for creating this scheduled message.