/** * The time-driven recovery transition for the application delivery outbox * (WFT-85): what happens to a lease nobody renewed. * * The state the lease expired in decides everything. A `claimed` lease never * called the transport, so the delivery is safe to reschedule (or dead-letter * when its attempt budget is spent). An `attempting` or cancellation-requested * lease may have sent, so its outcome is unknown and the delivery's own * unknown-outcome policy decides — never a blind retry. * * @module core/outbox-transitions-recovery */ import { type OutboxTransition, type RetryPolicy } from './outbox-transition-helpers.ts'; import type { ApplicationDeliveryRecord, ApplicationDeliveryRetryScheduled, ApplicationDeliveryTerminalRecord } from './outbox-types.ts'; /** * Whether a leased record's lease has lapsed: its visibility expired or its * attempt deadline passed, whichever came first. */ export declare function isDeliveryLeaseExpired(record: ApplicationDeliveryRecord, now: number): boolean; /** * Recover a delivery whose lease lapsed. * * `cleanupPending: true` and `abandonedAttemptToken` are written whenever the * lease is abandoned rather than settled by its holder, in every disposition: * the outbox stopped waiting for that attempt, which is not a claim that the * attempt stopped. */ export declare function recoverExpiredDelivery(record: ApplicationDeliveryRecord, options: { readonly now: number; } & RetryPolicy): OutboxTransition;