Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Breaking change]: 6.0 servicing change to EventSource callback behavior #35313

Closed
1 of 3 tasks
davmason opened this issue May 11, 2023 · 0 comments · Fixed by #35841
Closed
1 of 3 tasks

[Breaking change]: 6.0 servicing change to EventSource callback behavior #35313

davmason opened this issue May 11, 2023 · 0 comments · Fixed by #35841
Assignees
Labels
breaking-change Indicates a .NET Core breaking change doc-idea Indicates issues that are suggestions for new topics [org][type][category] Pri1 High priority, do before Pri2 and Pri3 📌 seQUESTered Identifies that an issue has been imported into Quest.

Comments

@davmason
Copy link
Member

davmason commented May 11, 2023

Description

PR #84680 includes a breaking change in the June 6.0 servicing release

Version

Other (please put exact version in description textbox)

Previous behavior

Prior to this change, we would issue the EventSource.OnEventCommand callback for a EventCommand.Disable prior to setting m_eventSourceEnabled=false. This means that IsEnabled would return true in the OnEventCommand callback for a user EventSource, even if the command would lead to the EventSource being disabled.

The callback happens after we turn off the ability to dispatch events though, so even if an EventSource tries to fire an event it will not be written. Also, for EventCommand.Enable we issue a consistent view - IsEnabled accurately reports the state of the world, and the EventSource can write events from the OnEventCommand callback. This change makes the EventCommand.Disable behavior match the Enable behavior.

New behavior

The change makes the callbacks consistent, now we will mark the EventSource as disabled before the callback.

Type of breaking change

  • Binary incompatible: Existing binaries may encounter a breaking change in behavior, such as failure to load or execute, and if so, require recompilation.
  • Source incompatible: When recompiled using the new SDK or component or to target the new runtime, existing source code may require source changes to compile successfully.
  • Behavioral change: Existing binaries may behave differently at run time.

Reason for change

This change was necessary to support multiple EventCounters instances, which has been requested as a blocker by multiple internal and external customers

Recommended action

I can't think of a scenario where the old behavior is desired, there is no way to revert to it.

Feature area

Core .NET libraries

Affected APIs

No response


Associated WorkItem - 97022

@davmason davmason added doc-idea Indicates issues that are suggestions for new topics [org][type][category] breaking-change Indicates a .NET Core breaking change Pri1 High priority, do before Pri2 and Pri3 labels May 11, 2023
@dotnet-bot dotnet-bot added the ⌚ Not Triaged Not triaged label May 11, 2023
@gewarren gewarren removed the ⌚ Not Triaged Not triaged label May 11, 2023
@gewarren gewarren added the 🗺️ reQUEST Triggers an issue to be imported into Quest. label Jun 2, 2023
@github-actions github-actions bot added 📌 seQUESTered Identifies that an issue has been imported into Quest. and removed 🗺️ reQUEST Triggers an issue to be imported into Quest. labels Jun 3, 2023
@ghost ghost added the in-pr This issue will be closed (fixed) by an active pull request. label Jun 15, 2023
@gewarren gewarren moved this from 🔖 Ready to 👀 In review in dotnet/docs June 2023 sprint Jun 15, 2023
@github-project-automation github-project-automation bot moved this from 👀 In review to ✅ Done in dotnet/docs June 2023 sprint Jun 15, 2023
@ghost ghost removed the in-pr This issue will be closed (fixed) by an active pull request. label Jun 15, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
breaking-change Indicates a .NET Core breaking change doc-idea Indicates issues that are suggestions for new topics [org][type][category] Pri1 High priority, do before Pri2 and Pri3 📌 seQUESTered Identifies that an issue has been imported into Quest.
Projects
No open projects
Status: Done
Development

Successfully merging a pull request may close this issue.

3 participants