Leave a delivery cut off by a stop for the next start (closes #527)
check / check (push) Canceled after 0s

Stopping the engine cancels the context every http and slack request is
sent with. An attempt cut off that way was recorded as failed, which for
a target with no retries, or on a last retry, ended the delivery failed
and nothing sent it again.

The shared retry core now records nothing for a failed attempt when the
engine's context is cancelled: no result, no circuit breaker outcome, no
status change, no count in the attempt metrics. The delivery stays
pending or retrying and startup recovery sends it again. A target's own
timeout is still a failed attempt. The README says what happens to an
attempt in flight at a stop and no longer claims every attempt is
recorded.

Model: opus-5-5
This commit is contained in:
2026-10-15 09:33:46 +00:00
parent f14fe02011
commit dd2828cda2
5 changed files with 230 additions and 20 deletions
+1 -1
View File
@@ -82,7 +82,7 @@ func (t *slackTarget) Deliver(
}
t.deliver(
webhookDB, d, task, sched,
ctx, webhookDB, d, task, sched,
d.Target.MaxRetries, attempt,
)
}