Skip to main content

retry_mark_sent

Function retry_mark_sent 

Source
pub async fn retry_mark_sent<F, Fut, E>(
    id: i64,
    retry_delays_ms: &[u64],
    mark_sent: F,
) -> Result<bool, E>
where F: FnMut(i64, usize) -> Fut, Fut: Future<Output = Result<bool, E>>, E: Display,
Expand description

Retries a product-provided mark_sent operation after SMTP success.

This helper exists to narrow the duplicate-delivery window where SMTP has accepted a message but the database row still says Processing. The caller provides the actual persistence function so repositories, transactions, timestamps, and product errors stay in the product crate.