Confirmation email sent within 60 seconds of confirmed status; delivery failures retried
Why it matters
When a customer books an appointment, the confirmation email is the first trust signal they receive. A silent failure — a network hiccup that drops the send, an SMTP timeout that never retries — leaves the customer uncertain whether the booking went through. That uncertainty generates support tickets, duplicate bookings, and chargebacks. CWE-391 (failure to handle exceptional conditions) and ISO 25010 reliability.fault-tolerance both flag exactly this gap: a delivery path with no retry is not a delivery path, it's a hope. Without at least 3 retry attempts on exponential backoff, any transient email provider outage silently voids confirmation for everyone who booked during that window.
Severity rationale
Critical because a single transient provider error silently drops the confirmation, leaving customers with no record of their booking and businesses exposed to disputes and no-shows.
Remediation
Add the email queue job inside the same function that writes the confirmed status, not in a separate polling job. Set at minimum 5 retry attempts with exponential backoff in src/jobs/email-worker.ts:
// src/lib/bookings.ts
async function confirmBooking(bookingId: string) {
const booking = await db.bookings.update(bookingId, { status: 'confirmed' })
await emailQueue.add(
'send-confirmation',
{ bookingId, customerEmail: booking.customer_email },
{ attempts: 5, backoff: { type: 'exponential', delay: 2000 } }
)
}
The queue addition must be in the same function as the status write so there is no window where status is confirmed but email is not yet scheduled.
DetectionPro
The detection method for this pattern is part of AuditBuffet Pro.
The full method (what to look for, pass and fail conditions, and how results get reported) ships inside the Booking Notifications & Reminders Audit. The pattern definition, severity rationale, and remediation remain openly licensed under CC-BY-4.0.
External references
- cwe · CWE-391 — Unchecked Error Condition
- iso-25010:2011 · reliability.fault-tolerance
Taxons
History
- 2026-04-18·v1.0.0·Initial import from booking-notifications-reminders·automated