Browse Source

Merge pull request #19986 from macrobert-com/BackgroundWorkers_Should_Be_Restartable

BackgroundWorkers should be restartable to permit changes in Timer interval
pull/20023/head
maliming 2 years ago
committed by GitHub
parent
commit
556c0ada8b
No known key found for this signature in database GPG Key ID: B5690EEEBB952194
  1. 5
      framework/src/Volo.Abp.BackgroundWorkers/Volo/Abp/BackgroundWorkers/BackgroundWorkerBase.cs

5
framework/src/Volo.Abp.BackgroundWorkers/Volo/Abp/BackgroundWorkers/BackgroundWorkerBase.cs

@ -22,8 +22,9 @@ public abstract class BackgroundWorkerBase : IBackgroundWorker
protected ILogger Logger => LazyServiceProvider.LazyGetService<ILogger>(provider => LoggerFactory?.CreateLogger(GetType().FullName!) ?? NullLogger.Instance); protected ILogger Logger => LazyServiceProvider.LazyGetService<ILogger>(provider => LoggerFactory?.CreateLogger(GetType().FullName!) ?? NullLogger.Instance);
protected CancellationTokenSource StoppingTokenSource { get; } protected CancellationTokenSource StoppingTokenSource { get; set; }
protected CancellationToken StoppingToken { get; }
protected CancellationToken StoppingToken { get; set; }
public BackgroundWorkerBase() public BackgroundWorkerBase()
{ {

Loading…
Cancel
Save