Consider adding a LazyResettableCts for Kestrel #9419
Labels
affected-very-few
This issue impacts very few customers
area-networking
Includes servers, yarp, json patch, bedrock, websockets, http client factory, and http abstractions
enhancement
This issue represents an ask for new feature or an enhancement to an existing one
severity-nice-to-have
This label is used by an internal tool
Milestone
We have been bitten in the past in Kestrel by making the RequestAborted token lazy. We have now had 3 attempts to fix our disposal of the RequestAborted token (e04c79b, 0622513, and another one from a while ago that I can't find), and though we think our logic is correct now, it isn't easy to guarantee and verify.
A nice way to simplify this logic is to create a new CTS type that is both lazy and resettable. Internally, it would handle races between calling cancel and dispose and be resettable.
The text was updated successfully, but these errors were encountered: