打开 关闭

BackgroundJob that execute just once #3545


User avatar
0
toptis 创建
  • 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.

1 答案
  • User Avatar
    0
    liangshiwei 创建
    支持团队 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

Made with ❤️ on ABP v8.2.0-preview Updated on 三月 25, 2024, 15:11