feat: [BE-05] BullMQ Async Job Queue + Scheduled Cron Jobs#1029
Open
SharifIbrahimDev wants to merge 6 commits into
Open
feat: [BE-05] BullMQ Async Job Queue + Scheduled Cron Jobs#1029SharifIbrahimDev wants to merge 6 commits into
SharifIbrahimDev wants to merge 6 commits into
Conversation
|
@rhoggs-bot-test-account is attempting to deploy a commit to the Mftee's projects Team on Vercel. A member of the Team first needs to authorize it. |
added 5 commits
June 19, 2026 15:49
# Conflicts: # backend/src/auth/two-factor.service.ts
… authenticator export
…d imports/components
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #962
Overview
This pull request implements the requested BullMQ asynchronous background queues and scheduled cron jobs for the backend. These changes ensure that operations like Stellar smart contract calls, email delivery, and PDF generation no longer block HTTP responses. Additionally, automated scheduled tasks for expired bids, stuck shipments, and unused file cleanup have been added.
Technical Details
1. BullMQ Setup
@nestjs/bullin theAppModuleusingConfigServiceto connect to Redis (REDIS_HOST&REDIS_PORT).QueueModuledefining three named queues:stellar-anchor,email-send, andpdf-generate.2. Queue Processors
stellar-anchor,email-send, andpdf-generate.job.updateProgress()at four intervals (25%, 50%, 75%, 100%).stellar-anchor) updates the relatedShipmentStatustoFAILED.3. Cron Jobs
@nestjs/scheduleto handle the following automated background tasks:0 * * * *) that checksBidentities and transitions them toEXPIREDifexpiresAt < NOW(). (AddedexpiresAtcolumn to theBidentity).0 2 * * *) that triggers a prominent Logger alert forIN_TRANSITshipments lacking updates for >30 days.0 3 * * *) that scans the./uploadsdirectory to delete files older than 7 days with no matchingDocumentDB record.4. API Endpoints
GET /admin/queue/statsendpoint to theAdminController.RolesGuard(ADMIN only).Verification
All 105 automated backend tests pass cleanly. The application successfully connects to the configured Redis instance, schedules cron tasks, and can enqueue/process jobs seamlessly.