|
|
|
@ -3,6 +3,7 @@ using System; |
|
|
|
using System.Collections.Generic; |
|
|
|
using System.Threading; |
|
|
|
using System.Threading.Tasks; |
|
|
|
using Volo.Abp.Data; |
|
|
|
using Volo.Abp.DependencyInjection; |
|
|
|
using Volo.Abp.MultiTenancy; |
|
|
|
using Volo.Abp.ObjectMapping; |
|
|
|
@ -65,6 +66,20 @@ public class BackgroundJobStore : IJobStore, ITransientDependency |
|
|
|
backgroundJobInfo.TryCount = jobInfo.TryCount; |
|
|
|
backgroundJobInfo.IsAbandoned = jobInfo.IsAbandoned; |
|
|
|
|
|
|
|
foreach (var arg in jobInfo.Args) |
|
|
|
{ |
|
|
|
if (!backgroundJobInfo.Args.ContainsKey(arg.Key)) |
|
|
|
{ |
|
|
|
backgroundJobInfo.Args[arg.Key] = arg.Value; |
|
|
|
continue; |
|
|
|
} |
|
|
|
if (backgroundJobInfo.Args.TryGetValue(arg.Key, out var value) && |
|
|
|
!Equals(value, arg.Value)) |
|
|
|
{ |
|
|
|
backgroundJobInfo.Args[arg.Key] = arg.Value; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
await JobInfoRepository.UpdateAsync(backgroundJobInfo); |
|
|
|
} |
|
|
|
else |
|
|
|
|