Repository navigation
Propagate cancellation tokens through persistence dialects, licensing and acceptance test infrastructure - #5754
Merged
Conversation
johnsimons
force-pushed
the
john/cancel_phase6
branch
from
August 13, 2026 03:15
cf0879a to
236b8ee
Compare
johnsimons
force-pushed
the
john/cancel_p7_persistence_licensing
branch
from
August 13, 2026 03:56
9f17387 to
73d5446
Compare
… and acceptance test infrastructure Retires the cancellation analyzer debt blocks in six projects, which is Phase 7 of the propagation work. ServiceControl.Persistence.EFCore.SqlServer / .PostgreSql: the dialect implementations now match their interfaces, whose tokens are already optional. ServiceControl.RavenDB: EmbeddedDatabase.DeleteDatabase takes a token and forwards it, so deleting a database can be cancelled. Particular.LicensingComponent: IAuditQuery and IThroughputCollector and their implementations, plus BrokerThroughputCollectorHostedService's stoppingToken renamed to cancellationToken. Five catch blocks now catch OperationCanceledException filtered on the token before catching Exception, so shutdown cancellation is no longer reported as a failure to gather throughput or to reach the audit remotes. ServiceControl.AcceptanceTesting: the HTTP helpers and assertion helpers take and forward optional tokens. The scenario poll loop captured cancellation as a test failure on shutdown, so it now swallows its own cancellation and holds the linked token in a local rather than reading a disposed source. The project block is narrowed to the types that sit on NServiceBus.AcceptanceTesting extension points, which drive them without a token. ServiceControl.Audit.Persistence.RavenDB: the PS0020 carve-out on LicenseStatusCheck moves from the project editorconfig to an inline pragma. The filter is deliberate, since the try runs on a linked token that is always cancelled in the timeout case being mapped.
johnsimons
force-pushed
the
john/cancel_p7_persistence_licensing
branch
from
August 13, 2026 05:25
73d5446 to
ec0b69c
Compare
rbev
approved these changes
Aug 13, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Retires the cancellation analyzer debt blocks in six projects, which is
Phase 7 of the propagation work.
ServiceControl.Persistence.EFCore.SqlServer / .PostgreSql: the dialect
implementations now match their interfaces, whose tokens are already
optional.
ServiceControl.RavenDB: EmbeddedDatabase.DeleteDatabase takes a token and
forwards it, so deleting a database can be cancelled.
Particular.LicensingComponent: IAuditQuery and IThroughputCollector and
their implementations, plus BrokerThroughputCollectorHostedService's
stoppingToken renamed to cancellationToken. Five catch blocks now catch
OperationCanceledException filtered on the token before catching
Exception, so shutdown cancellation is no longer reported as a failure to
gather throughput or to reach the audit remotes.
ServiceControl.AcceptanceTesting: the HTTP helpers and assertion helpers
take and forward optional tokens. The scenario poll loop captured
cancellation as a test failure on shutdown, so it now swallows its own
cancellation and holds the linked token in a local rather than reading a
disposed source. The project block is narrowed to the types that sit on
NServiceBus.AcceptanceTesting extension points, which drive them without
a token.
ServiceControl.Audit.Persistence.RavenDB: the PS0020 carve-out on
LicenseStatusCheck moves from the project editorconfig to an inline
pragma. The filter is deliberate, since the try runs on a linked token
that is always cancelled in the timeout case being mapped.