Skip to content

Commit

Permalink
Exit more eagerly on cancellation during sleep
Browse files Browse the repository at this point in the history
  • Loading branch information
peppy committed Oct 30, 2024
1 parent c44266c commit 8e2ded8
Showing 1 changed file with 3 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,9 @@ protected override async Task<int> ExecuteAsync(CancellationToken cancellationTo
{
using (var connection = DatabaseAccess.GetConnection())
await SlaveLatencyChecker.CheckSlaveLatency(connection, cancellationToken);

if (cancellationToken.IsCancellationRequested)
break;
}

sw.Restart();
Expand Down

0 comments on commit 8e2ded8

Please sign in to comment.