Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion src/Immediate.Jobs.Shared/Internals/JobSchedulingService.cs
Original file line number Diff line number Diff line change
Expand Up @@ -152,10 +152,12 @@ ILogger<JobSchedulingService> logger
/// <inheritdoc />
protected override async Task ExecuteAsync(CancellationToken stoppingToken)
{
// initialization needs to be done no matter what, so that storage is initialized
await InitializeAsync(stoppingToken);

if (!_options.IsJobSchedulingServiceEnabled)
return;

await InitializeAsync(stoppingToken);
MarkStarted(_timeProvider.GetUtcNow());

// Workers observe _workerCancellation rather than stoppingToken: shutdown completes the channel so
Expand Down
Loading