Open Closed

BackgroundJob that execute just once #3545


User avatar
0
toptis created
  • ABP Framework version: v5.3.1
  1. How can I create BackgroundJob To execute just once (if an exception occurred) make it abandoned "true" and don't retry the job.
  2. How can I remove old abandoned jobs after 1 day.
Markdown supported.
Copy, paste, or drag & drop images and files (max 100 MB per file, 100 MB total per post)

1 Answer(s)
  • User Avatar
    0
    liangshiwei created
    Fullstack Developer

    Hi,

    How can I create BackgroundJob To execute just once (if an exception occurred) make it abandoned "true" and don't retry the job.

    See: https://docs.abp.io/en/abp/latest/Background-Jobs#configuration You can set the DefaultTimeout to 0 of AbpBackgroundJobWorkerOptions

    How can I remove old abandoned jobs after 1 day.

    You can create a background worker to remove abandoned jobs. see: https://docs.abp.io/en/abp/latest/Background-Workers

    Markdown supported.
    Copy, paste, or drag & drop images and files (max 100 MB per file, 100 MB total per post)
Boost Your Development
ABP Live Training
Packages
See Trainings
Mastering ABP Framework Book
The Official Guide
Mastering
ABP Framework
Learn More
Mastering ABP Framework Book
Made with ❤️ on ABP v10.8.0-preview. Updated on September 28, 2026, 11:44
1
ABP Assistant
🔐 You need to be logged in to use the chatbot. Please log in first.