Skip to content

feat: Add DEAD_LETTERED notification status for better failure tracking - #776

Open
Emmyranky wants to merge 1 commit into
Core-Foundry:mainfrom
Emmyranky:main
Open

feat: Add DEAD_LETTERED notification status for better failure tracking#776
Emmyranky wants to merge 1 commit into
Core-Foundry:mainfrom
Emmyranky:main

Conversation

@Emmyranky

Copy link
Copy Markdown

I have successfully implemented the requested notification dead-letter handling mechanism by introducing a new
DEAD_LETTERED status in the notification lifecycle.

Summary of Changes:

  1. Updated NotificationStatus: Added DEAD_LETTERED to the NotificationStatus enum in
    listener/src/types/scheduled-notification.ts.
  2. Updated ScheduledNotificationRepository:
    • Modified markAsFailedOrRetry to transition notifications to DEAD_LETTERED instead of FAILED when retries are
      exhausted.
    • Modified recoverStaleLocks to transition notifications to DEAD_LETTERED (and log the attempt correctly)
      instead of FAILED when a lock is recovered and retries are exhausted.
  3. Updated NotificationExecutionLog: Added DEAD_LETTERED to the status type.
  4. Updated dead-letter-queue.test.ts: Updated tests to verify that permanently failed notifications now correctly
    transition to DEAD_LETTERED status, and verified that requeuing functionality remains intact.

closes #706

@drips-wave

drips-wave Bot commented Sep 4, 2026

Copy link
Copy Markdown

@Emmyranky Great news! 🎉 Based on an automated assessment of this PR, the linked Wave issue(s) no longer count against your application limits.

You can now already apply to more issues while waiting for a review of this PR. Keep up the great work! 🚀

Learn more about application limits

@Samuel-21-eng

Copy link
Copy Markdown

please review

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add Notification Dead-Letter Handling

2 participants