HttpSysRequestDelegationFeature - DelegationRule.Dipose() doesn't clean up delegation flag with http.sys #27126
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
bug
This issue describes a behavior which is not expected - a bug.
severity-minor
This label is used by an internal tool
Milestone
Uh oh!
There was an error while loading. Please reload this page.
Describe the bug
When a new DelegationRule is created, SetDelegationProperty gets called to add a HttpServerDelegationProperty property flag to the RequestQueue owned/created by the process (i.e. not the RequestQueue the delegator is trying to delegate to). When a DelegationRule is disposed, this property flag is not unset. This keeps the delegator process linked to destination queue and prevents a new DelegationRule rule for the same from being created later on.
Ideally as a consumer of this feature I want to be able to dynamically add/remove rules in production via config without the need to restart the process and this bug blocks this ability.
Here is a example fix that I've validated which unsets the property when disposing the delegation rule: master...NGloreous:user/nglore/delegation/unsetdelegation
To Reproduce
Exceptions (if any)
With the above code, the first request received works fine (assuming you have the fix for #26982) but on subsequent request the below exception is throw from the call to CreateDelegationRule.
Also if you run "netsh http show servicestate" after making the first request you will see that the delegator process is still attached to the queue.
The text was updated successfully, but these errors were encountered: